--- loncom/homework/grades.pm 2004/11/23 02:37:58 1.230 +++ loncom/homework/grades.pm 2004/11/23 14:19:32 1.231 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # The LON-CAPA Grading handler # -# $Id: grades.pm,v 1.230 2004/11/23 02:37:58 banghart Exp $ +# $Id: grades.pm,v 1.231 2004/11/23 14:19:32 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -1663,7 +1663,6 @@ KEYWORDS } } my $order=&get_order($partid,$respid,$symb,$uname,$udom); - my $portfolio_path; if ($ENV{'form.lastSub'} eq 'lastonly' || ($ENV{'form.lastSub'} eq 'hdgrade' && $$handgrade{$part} eq 'yes')) { @@ -1671,20 +1670,17 @@ KEYWORDS $lastsubonly.='Part: '. $display_part.' ( ID '.$respid. ' )   '; + my $file_url; if ($record{"resource.$partid.$respid.portfiles"}) { - $portfolio_path = '/uploaded/'.$udom.'/'.$uname.'/portfolio'; + $file_url = '/uploaded/'.$udom.'/'.$uname.'/portfolio'.$record{"resource.$partid.$respid.portfiles"}; &Apache::lonnet::logthis("found a portfolio file".$record{"resource.$partid.$respid.portfiles"}); &Apache::lonnet::logthis("uploaded URL file".$record{"resource.$partid.$respid.uploadedurl"}); } else { - $portfolio_path = ''; + $file_url=$record{"resource.$partid.$respid.uploadedurl"}; } - if ($record{"resource.$partid.$respid.uploadedurl"}) { - &Apache::lonnet::allowuploaded('/adm/grades', - $record{"resource.$partid.$respid.uploadedurl"}); - $lastsubonly.=' File uploaded by student Like all files provided by users, this file may contain virusses
'; - } - if ($record{"resource.$partid.$respid.portfiles"}) { - $lastsubonly.=' File uploaded by student Like all files provided by users, this file may contain virusses
'; + if ($file_url) { + &Apache::lonnet::allowuploaded('/adm/grades',$file_url); + $lastsubonly.=' File uploaded by student Like all files provided by users, this file may contain virusses
'; } $lastsubonly.='Submitted Answer: '. &cleanRecord($subval,$responsetype,$symb,$partid,