version 1.585, 2009/12/16 16:09:24
|
version 1.586, 2009/12/27 01:25:26
|
Line 7620 sub scantron_process_students {
|
Line 7620 sub scantron_process_students {
|
my (%grader_partids_by_symb,%grader_randomlists_by_symb); |
my (%grader_partids_by_symb,%grader_randomlists_by_symb); |
&graders_resources_pass(\@resources,\%grader_partids_by_symb, |
&graders_resources_pass(\@resources,\%grader_partids_by_symb, |
\%grader_randomlists_by_symb); |
\%grader_randomlists_by_symb); |
|
my $resource_error; |
foreach my $resource (@resources) { |
foreach my $resource (@resources) { |
my $ressymb = $resource->symb(); |
my $ressymb; |
|
if (ref($resource)) { |
|
$ressymb = $resource->symb(); |
|
} else { |
|
$resource_error = 1; |
|
last; |
|
} |
my ($analysis,$parts) = |
my ($analysis,$parts) = |
&scantron_partids_tograde($resource,$env{'request.course.id'}, |
&scantron_partids_tograde($resource,$env{'request.course.id'}, |
$env{'user.name'},$env{'user.domain'},1); |
$env{'user.name'},$env{'user.domain'},1); |
Line 7633 sub scantron_process_students {
|
Line 7640 sub scantron_process_students {
|
} |
} |
} |
} |
} |
} |
|
if ($resource_error) { |
|
$r->print(&navmap_errormsg()); |
|
return ''; |
|
} |
|
|
my ($uname,$udom); |
my ($uname,$udom); |
my $result= <<SCANTRONFORM; |
my $result= <<SCANTRONFORM; |
Line 7703 SCANTRONFORM
|
Line 7714 SCANTRONFORM
|
} |
} |
($uname,$udom)=split(/:/,$uname); |
($uname,$udom)=split(/:/,$uname); |
|
|
my %partids_by_symb; |
my (%partids_by_symb,$res_error); |
foreach my $resource (@resources) { |
foreach my $resource (@resources) { |
my $ressymb = $resource->symb(); |
my $ressymb; |
|
if (ref($resource)) { |
|
$ressymb = $resource->symb(); |
|
} else { |
|
$res_error = 1; |
|
last; |
|
} |
if ((exists($grader_randomlists_by_symb{$ressymb})) || |
if ((exists($grader_randomlists_by_symb{$ressymb})) || |
(ref($grader_partids_by_symb{$ressymb}) ne 'ARRAY')) { |
(ref($grader_partids_by_symb{$ressymb}) ne 'ARRAY')) { |
my ($analysis,$parts) = |
my ($analysis,$parts) = |
Line 7716 SCANTRONFORM
|
Line 7733 SCANTRONFORM
|
} |
} |
} |
} |
|
|
|
if ($res_error) { |
|
&scantron_add_delay(\@delayqueue,$line, |
|
'An error occurred while grading student '.$uname,2); |
|
next; |
|
} |
|
|
&Apache::lonxml::clear_problem_counter(); |
&Apache::lonxml::clear_problem_counter(); |
&Apache::lonnet::appenv($scan_record); |
&Apache::lonnet::appenv($scan_record); |
|
|