--- loncom/homework/grades.pm 2005/08/12 21:33:41 1.278 +++ loncom/homework/grades.pm 2005/08/29 10:06:07 1.280 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # The LON-CAPA Grading handler # -# $Id: grades.pm,v 1.278 2005/08/12 21:33:41 albertel Exp $ +# $Id: grades.pm,v 1.280 2005/08/29 10:06:07 foxr Exp $ # # Copyright Michigan State University Board of Trustees # @@ -4869,9 +4869,16 @@ sub scantron_get_closely_matching_CODEs } sub get_codes { - my $old_name=$env{'form.scantron_CODElist'}; - my $cdom =$env{'course.'.$env{'request.course.id'}.'.domain'}; - my $cnum =$env{'course.'.$env{'request.course.id'}.'.num'}; + my ($old_name, $cdom, $cnum) = @_; + if (!$old_name) { + $old_name=$env{'form.scantron_CODElist'}; + } + if (!$cdom) { + $cdom =$env{'course.'.$env{'request.course.id'}.'.domain'}; + } + if (!$cnum) { + $cnum =$env{'course.'.$env{'request.course.id'}.'.num'}; + } my %result=&Apache::lonnet::get('CODEs',[$old_name,"type\0$old_name"], $cdom,$cnum); my %allcodes; @@ -5412,6 +5419,9 @@ GRADINGMENUJS $result.=''. ' access times.'."\n"; + $result.=''. + ' saved CODEs.'."\n"; $result.=''."\n". ''."\n".