From: Mike G. v. a. <we...@ma...> - 2005-07-20 18:29:12
|
Log Message: ----------- Added a modification of the grades that shows where the state_summary_msg can be added. This message is printed at the bottom of each problem page. The current default is a blank message, which means that the default message defined in Problem.pm is printed. There is currently no way to turn the message off entirely. Perhaps on the next revision. Modified Files: -------------- pg/macros: PGanswermacros.pl Revision Data ------------- Index: PGanswermacros.pl =================================================================== RCS file: /webwork/cvs/system/pg/macros/PGanswermacros.pl,v retrieving revision 1.33 retrieving revision 1.34 diff -Lmacros/PGanswermacros.pl -Lmacros/PGanswermacros.pl -u -r1.33 -r1.34 --- macros/PGanswermacros.pl +++ macros/PGanswermacros.pl @@ -4312,6 +4312,9 @@ $problem_state{num_of_correct_ans}++ if $allAnswersCorrectQ == 1; $problem_state{num_of_incorrect_ans}++ if $allAnswersCorrectQ == 0; + + $problem_state{state_summary_msg} = ''; # an HTML formatted message printed at the bottom of the problem page + (\%problem_result, \%problem_state); } @@ -4411,6 +4414,8 @@ if ($record_problem_attempt == 1) { $problem_state{num_of_correct_ans}++ if $allAnswersCorrectQ == 1; $problem_state{num_of_incorrect_ans}++ if $allAnswersCorrectQ == 0; + $problem_state{state_summary_msg} = ''; # an HTML formatted message printed at the bottom of the problem page + } else { $problem_result{show_partial_correct_answers} = 0 ; # prevent partial correct answers from being shown for syntax errors. @@ -4484,6 +4489,9 @@ $problem_state{num_of_correct_ans}++ if $total == $count; $problem_state{num_of_incorrect_ans}++ if $total < $count ; + + $problem_state{state_summary_msg} = ''; # an HTML formatted message printed at the bottom of the problem page + warn "Error in grading this problem the total $total is larger than $count" if $total > $count; (\%problem_result, \%problem_state); } |