version 1.479, 2007/11/05 10:19:03
|
version 1.480, 2007/11/05 11:46:08
|
Line 5179 sub scantron_fixup_scanline {
|
Line 5179 sub scantron_fixup_scanline {
|
} else { |
} else { |
substr($answer,$args->{'response'},1)=$on; |
substr($answer,$args->{'response'},1)=$on; |
} |
} |
my $before = Dumper($scan_data); |
|
&scan_data($scan_data, |
&scan_data($scan_data, |
"$whichline.no_bubble.".$args->{'question'},undef,'1'); |
"$whichline.no_bubble.".$args->{'question'},undef,'1'); |
my $after = Dumper($scan_data); |
|
for (my $l = 0; $l < $bubble_count; $l++) { |
for (my $l = 0; $l < $bubble_count; $l++) { |
if ($l eq $bubble_line) { |
if ($l eq $bubble_line) { |
$final_answer .= $answer; |
$final_answer .= $answer; |
Line 6520 ENDSCRIPT
|
Line 6518 ENDSCRIPT
|
foreach my $question (@{$arg}) { |
foreach my $question (@{$arg}) { |
my $selected = &get_response_bubbles($scan_record, $question); |
my $selected = &get_response_bubbles($scan_record, $question); |
my @select_array = split(/:/,$selected); |
my @select_array = split(/:/,$selected); |
&Apache::lonnet::logthis("Questnum: $question, bubbles: $selected scanline $i"); |
|
&scantron_bubble_selector($r,$scan_config,$question, |
&scantron_bubble_selector($r,$scan_config,$question, |
@select_array); |
@select_array); |
} |
} |
Line 6800 sub scantron_validate_doublebubble {
|
Line 6797 sub scantron_validate_doublebubble {
|
my ($scanlines,$scan_data)=&scantron_getfile(); |
my ($scanlines,$scan_data)=&scantron_getfile(); |
|
|
&scantron_get_maxbubble(); # parse needs the bubble line array. |
&scantron_get_maxbubble(); # parse needs the bubble line array. |
&Apache::lonnet::logthis("validate_double_bubble"); |
|
|
|
for (my $i=0;$i<=$scanlines->{'count'};$i++) { |
for (my $i=0;$i<=$scanlines->{'count'};$i++) { |
my $line=&scantron_get_line($scanlines,$scan_data,$i); |
my $line=&scantron_get_line($scanlines,$scan_data,$i); |
Line 6808 sub scantron_validate_doublebubble {
|
Line 6804 sub scantron_validate_doublebubble {
|
my $scan_record=&scantron_parse_scanline($line,$i,\%scantron_config, |
my $scan_record=&scantron_parse_scanline($line,$i,\%scantron_config, |
$scan_data); |
$scan_data); |
if (!defined($$scan_record{'scantron.doubleerror'})) { next; } |
if (!defined($$scan_record{'scantron.doubleerror'})) { next; } |
&Apache::lonnet::logthis("Double found for line $i : $line"); |
|
&scantron_get_correction($r,$i,$scan_record,\%scantron_config,$line, |
&scantron_get_correction($r,$i,$scan_record,\%scantron_config,$line, |
'doublebubble', |
'doublebubble', |
$$scan_record{'scantron.doubleerror'}); |
$$scan_record{'scantron.doubleerror'}); |