version 1.53, 2002/07/02 22:06:53
|
version 1.54, 2002/07/03 14:11:14
|
Line 258 sub CreateTableHeadings {
|
Line 258 sub CreateTableHeadings {
|
$Str .= '</pre></td>'; |
$Str .= '</pre></td>'; |
} |
} |
|
|
$Str .= '<td>Total Solved/Total Problems</td>'; |
$Str .= '<td><pre>Total Solved/Total Problems</pre></td>'; |
$Str .= '</tr></tbody></table>'; |
$Str .= '</tr></tbody></table>'; |
|
|
return $Str; |
return $Str; |
Line 307 sub CreateColumnSelectors {
|
Line 307 sub CreateColumnSelectors {
|
|
|
my $found=0; |
my $found=0; |
my ($name, $length, $position); |
my ($name, $length, $position); |
my $present='<table border="0" cellpadding="0" cellspacing="0">'; |
|
$present .= '</tbody><tr>'; |
my $present='<pre><b>Note: Uncheck the boxes above a column to '; |
|
$present .= 'remove that column from the display.</b></pre>'."\n"; |
|
|
|
$present .= '<table border="0" cellpadding="0" cellspacing="0">'; |
|
$present .= '<tbody><tr>'; |
for(my $index=0; $index<(scalar @$headings); $index++) { |
for(my $index=0; $index<(scalar @$headings); $index++) { |
if(!&ShouldShowColumn($CacheData, 'heading'.$index)) { |
if(!&ShouldShowColumn($CacheData, 'heading'.$index)) { |
next; |
next; |
} |
} |
$present .= '<td align="center">'; |
$present .= '<td align="left">'; |
$name = $headings->[$index]; |
|
$present .= '<input type="checkbox" checked="on" '; |
$present .= '<input type="checkbox" checked="on" '; |
$present .= 'name="heading'.$index.'">'; |
$present .= 'name="heading'.$index.'" />'; |
$present .= '</td>'; |
$present .= '</td>'; |
$found++; |
$found++; |
} |
} |
Line 325 sub CreateColumnSelectors {
|
Line 328 sub CreateColumnSelectors {
|
if(!&ShouldShowColumn($CacheData, 'sequence'.$sequence)) { |
if(!&ShouldShowColumn($CacheData, 'sequence'.$sequence)) { |
next; |
next; |
} |
} |
$present .= '<td align="center">'; |
$present .= '<td align="left">'; |
$name = $CacheData->{$sequence.':title'}; |
|
$present .= '<input type="checkbox" checked="on" '; |
$present .= '<input type="checkbox" checked="on" '; |
$present .= 'name="sequence'.$sequence.'">'; |
$present .= 'name="sequence'.$sequence.'" />'; |
$present .= '</td>'; |
$present .= '</td>'; |
$found++; |
$found++; |
} |
} |
|
|
if($found) { |
if(!$found) { |
$present = $present; |
$present = ''; |
} else { |
|
$present = '<td></td>'; |
|
} |
} |
|
|
return $present.'</tr></form>'."\n";; |
return $present.'<td></td></tr></form>'."\n";; |
} |
} |
|
|
sub CreateForm { |
sub CreateForm { |
Line 407 sub StartDocument {
|
Line 407 sub StartDocument {
|
$Str .= '<script>window.focus();</script>'; |
$Str .= '<script>window.focus();</script>'; |
$Str .= '<img align=right src=/adm/lonIcons/lonlogos.gif>'; |
$Str .= '<img align=right src=/adm/lonIcons/lonlogos.gif>'; |
$Str .= '<h1>Assessment Chart</h1>'; |
$Str .= '<h1>Assessment Chart</h1>'; |
$Str .= '<h3>'.localtime().'</h3>'; |
|
$Str .= '<h1>'.$ENV{'course.'.$ENV{'request.course.id'}.'.description'}; |
$Str .= '<h1>'.$ENV{'course.'.$ENV{'request.course.id'}.'.description'}; |
$Str .= '</h1>'; |
$Str .= '</h1>'; |
|
|
Line 769 sub ProcessClassList {
|
Line 768 sub ProcessClassList {
|
$name,$courseID,$c); |
$name,$courseID,$c); |
} |
} |
|
|
|
# Time of download |
|
$CacheData{'time'}=localtime(); |
untie(%CacheData); |
untie(%CacheData); |
} |
} |
|
|
Line 1104 sub BuildChart {
|
Line 1105 sub BuildChart {
|
# Sort students and print out table desciptive data |
# Sort students and print out table desciptive data |
if(tie(%CacheData,'GDBM_File',$ChartDB,&GDBM_READER,0640)) { |
if(tie(%CacheData,'GDBM_File',$ChartDB,&GDBM_READER,0640)) { |
if(!$c->aborted()) { @students=&SortStudents(\@students,\%CacheData); } |
if(!$c->aborted()) { @students=&SortStudents(\@students,\%CacheData); } |
|
my $downloadTime=0; |
|
if(defined($CacheData{'time'})) { $downloadTime=$CacheData{'time'}; } |
|
else { $downloadTime=localtime(); } |
|
if(!$c->aborted()) { $r->print('<h3>'.$downloadTime.'</h3>'); } |
if(!$c->aborted()) { $r->print('<h1>'.(scalar @students). |
if(!$c->aborted()) { $r->print('<h1>'.(scalar @students). |
' students</h1>'); } |
' students</h1>'); } |
if(!$c->aborted()) { $r->rflush(); } |
if(!$c->aborted()) { $r->rflush(); } |