version 1.197, 2006/11/09 17:50:51
|
version 1.199, 2006/11/09 20:42:43
|
Line 1009 sub end_Task {
|
Line 1009 sub end_Task {
|
if (!$previous && $status ne 'SHOW_ANSWER' && |
if (!$previous && $status ne 'SHOW_ANSWER' && |
&show_task($status,$previous)) { |
&show_task($status,$previous)) { |
$result.=&Apache::inputtags::gradestatus('0'); |
$result.=&Apache::inputtags::gradestatus('0'); |
$result.='</form>'; |
} |
|
|
|
$result.='</form>'; |
|
|
|
if (!$previous && $status ne 'SHOW_ANSWER' && |
|
&show_task($status,$previous)) { |
my $action = &Apache::lonenc::check_encrypt($env{'request.uri'}); |
my $action = &Apache::lonenc::check_encrypt($env{'request.uri'}); |
$result.=<<DONEBUTTON; |
$result.=<<DONEBUTTON; |
<form name="done" method="post" action="$action"> |
<form name="done" method="post" action="$action"> |
Line 1055 DONEBUTTON
|
Line 1060 DONEBUTTON
|
my %counts = &get_counts($dim,undef,$parstack, |
my %counts = &get_counts($dim,undef,$parstack, |
$safeeval); |
$safeeval); |
$status.="\n<div class='LC_$bt_status LC_criteria LC_task_overall_status'><p>". |
$status.="\n<div class='LC_$bt_status LC_criteria LC_task_overall_status'><p>". |
&mt('You needed to pass all of the [_1] mandatory components and [_2] of the [_3] optional components, of which you passed [_4].', |
&question_status_message(\%counts,-1). |
$counts{'man'},$counts{'opt_req'}, |
"</p></div>\n"; |
$counts{'opt'},$counts{'opt_passed'}). |
|
"</p></div>\n"; |
|
|
|
|
|
foreach my $id (@{$dimension{$dim}{'criterias'}}) { |
foreach my $id (@{$dimension{$dim}{'criterias'}}) { |
Line 2351 sub end_Dimension {
|
Line 2354 sub end_Dimension {
|
return $result; |
return $result; |
} |
} |
|
|
sub status_message { |
sub question_status_message { |
my ($counts,$depth) = @_; |
my ($counts,$depth) = @_; |
my %req = ('man' => 'mandatory', |
my %req = ('man' => 'mandatory', |
'opt' => 'optional',); |
'opt' => 'optional',); |