version 1.21, 2001/11/28 18:29:53
|
version 1.24, 2001/12/18 20:06:05
|
Line 16
|
Line 16
|
# 9/8 Gerd Kortemeyer |
# 9/8 Gerd Kortemeyer |
# 10/18/01, 10/19/01 Behrouz Minaei |
# 10/18/01, 10/19/01 Behrouz Minaei |
# 11/17/01, 11/22/01, 11/24/01, 11/28/01 Behrouz Minaei |
# 11/17/01, 11/22/01, 11/24/01, 11/28/01 Behrouz Minaei |
|
# 12/18/01 Behrouz Minaei |
|
|
package Apache::lonchart; |
package Apache::lonchart; |
|
|
Line 30 my %hash;
|
Line 31 my %hash;
|
my @cols; |
my @cols; |
my @rowlabels; |
my @rowlabels; |
my @students; |
my @students; |
my $r; |
|
|
|
# ------------------------------------------------------------- Find out status |
# ------------------------------------------------------------- Find out status |
|
|
Line 48 sub ExtractStudentData {
|
Line 48 sub ExtractStudentData {
|
my $Version; |
my $Version; |
my $ProbNo; |
my $ProbNo; |
my $PrTotal; |
my $PrTotal; |
my $LatestVersion; |
my $LatestVersion; |
|
|
my $test = $ENV{'request.course.fn'}; |
|
my $comp = '/home/httpd/perl/tmp/minaeibi_msu_12679c3ed543a25msul1'; |
|
|
|
my $Str=substr($students[$index]. |
my $Str=substr($students[$index]. |
' ',0,14).' ! '. |
' ',0,14).' ! '. |
substr($rowlabels[$index]. |
substr($rowlabels[$index]. |
Line 113 sub ExtractStudentData {
|
Line 109 sub ExtractStudentData {
|
elsif ($Val eq 'incorrect_attempted'){$Code = '.';} |
elsif ($Val eq 'incorrect_attempted'){$Code = '.';} |
elsif ($Val eq 'incorrect_by_override'){$Code = '-';} |
elsif ($Val eq 'incorrect_by_override'){$Code = '-';} |
elsif ($Val eq 'excused'){$Code = 'x';} |
elsif ($Val eq 'excused'){$Code = 'x';} |
|
elsif ($Val eq 'ungraded_attempted'){$Code = '#';} |
else {$Code = ' ';} |
else {$Code = ' ';} |
$TempHash{"$Part.Code"} = $Code; |
$TempHash{"$Part.Code"} = $Code; |
# if ($test=~/*minaeibi*/) { |
|
# $r->print($Key." PartNo =$PartNo "." Tries=$Tries!<br>$Version:$Prob:resource.$Part.tries".' = '.$result{"$Version:$Prob:resource.$Part.tries"}." $Val "."($Code)".'<br>'); |
|
# } |
|
} |
} |
} |
} |
} |
} |
Line 131 sub ExtractStudentData {
|
Line 125 sub ExtractStudentData {
|
} |
} |
} |
} |
$Str .= $TempHash{"$part.Code"}; |
$Str .= $TempHash{"$part.Code"}; |
# $r->print($n.") Part=".$part." code=$TempHash{$part.'.Code'}<br>"); |
|
} |
} |
} |
} |
else {for(my $n=0; $n<$PartNo; $n++) {$Str.=' ';}} |
else {for(my $n=0; $n<$PartNo; $n++) {$Str.=' ';}} |
Line 190 sub tracetable {
|
Line 183 sub tracetable {
|
# ================================================================ Main Handler |
# ================================================================ Main Handler |
|
|
sub handler { |
sub handler { |
$r=shift; |
|
|
undef %hash; |
|
undef @students; |
|
undef @cols; |
|
undef @rowlabels; |
|
|
|
my $r=shift; |
|
|
if (&Apache::lonnet::allowed('vgr',$ENV{'request.course.id'})) { |
if (&Apache::lonnet::allowed('vgr',$ENV{'request.course.id'})) { |
# ------------------------------------------- Set document type for header only |
# ------------------------------------------- Set document type for header only |
Line 237 sub handler {
|
Line 236 sub handler {
|
" +: correct by override\n". |
" +: correct by override\n". |
" -: incorrect by override\n". |
" -: incorrect by override\n". |
" .: incorrect attempted\n". |
" .: incorrect attempted\n". |
|
" #: ungraded attempted\n". |
" : not attempted\n". |
" : not attempted\n". |
" x: excused</pre><p>"); |
" x: excused</pre><p>"); |
|
|
Line 258 sub handler {
|
Line 258 sub handler {
|
|
|
# ---------------------------------------------- Read class list and row labels |
# ---------------------------------------------- Read class list and row labels |
|
|
undef @rowlabels; |
|
undef @students; |
|
|
|
my $classlst=&Apache::lonnet::reply |
my $classlst=&Apache::lonnet::reply |
('dump:'.$cdom.':'.$cnum.':classlist',$chome); |
('dump:'.$cdom.':'.$cnum.':classlist',$chome); |
my $now=time; |
my $now=time; |