--- loncom/homework/grades.pm 2007/09/07 00:07:30 1.439 +++ loncom/homework/grades.pm 2007/10/01 19:41:51 1.442 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # The LON-CAPA Grading handler # -# $Id: grades.pm,v 1.439 2007/09/07 00:07:30 albertel Exp $ +# $Id: grades.pm,v 1.442 2007/10/01 19:41:51 banghart Exp $ # # Copyright Michigan State University Board of Trustees # @@ -349,7 +349,10 @@ sub cleanRecord { $result.=''; return $result; } - + } elsif ( $response =~ m/(?:numerical|formula)/) { + $answer = + &Apache::loncommon::format_previous_attempt_value('submission', + $answer); } return $answer; } @@ -395,6 +398,7 @@ COMMONJSFUNCTIONS sub getclasslist { my ($getsec,$filterlist) = @_; my @getsec; + my $stu_status = join(':',&Apache::loncommon::get_env_multiple('form.Status')); if (!ref($getsec)) { if ($getsec ne '' && $getsec ne 'all') { @getsec=($getsec); @@ -424,8 +428,8 @@ sub getclasslist { my $status = $classlist->{$student}->[&Apache::loncoursedata::CL_STATUS()]; # filter students according to status selected - if ($filterlist && $env{'form.Status'} ne 'Any') { - if ($env{'form.Status'} ne $status) { + if ($filterlist && (!($stu_status =~ /Any/))) { + if (!($stu_status =~ $status)) { delete ($classlist->{$student}); next; } @@ -507,6 +511,7 @@ sub student_gradeStatus { # Shows a student's view of problem and submission sub jscriptNform { my ($symb) = @_; + my $stu_status = join(':',&Apache::loncommon::get_env_multiple('form.Status')); my $jscript='