--- loncom/homework/grades.pm 2001/08/20 19:28:37 1.14
+++ loncom/homework/grades.pm 2001/10/05 21:51:14 1.16
@@ -18,11 +18,16 @@ sub moreinfo {
$request->print("Unable to process request: $reason");
if ( $Apache::grades::viewgrades eq 'F' ) {
$request->print('
');
}
return '';
@@ -41,18 +46,23 @@ sub listStudents {
my $reply=&Apache::lonnet::reply('get:'.$sdom.':'.$sname.
':environment:lastname&generation&firstname&middlename',
&Apache::lonnet::homeserver($sname,$sdom));
- print "reply=$reply
";
+ #print "reply=$reply
";
my (@nameparts) = split /&/,$reply;
# my $sfullname = $Apache::lonnet::unescape($nameparts[0]);
if ( $Apache::grades::viewgrades eq 'F' ) {
$request->print('');
}
}
@@ -91,10 +101,10 @@ sub getclasslist {
my ($end,$start)=split(/:/,$value);
# still a student?
if (($hideexpired) && ($end) && ($end < $now)) {
- print "Skipping:$name:$end:$now
\n";
+ #print "Skipping:$name:$end:$now
\n";
next;
}
- print "record=$record
";
+ #print "record=$record
";
push( @{ $classlist{'allids'} }, $name);
}
return (%classlist);
@@ -211,7 +221,12 @@ sub submission {
# if ($ENV{'form.student'} eq '') { &listStudents($request); return ''; }
my ($uname,$udom) = &finduser($ENV{'form.student'});
if ($uname eq '') { &moreinfo($request,"Unable to find student"); return ''; }
- my $symb=&Apache::lonnet::symbread($url);
+ my $symb;
+ if ($ENV{'form.symb'}) {
+ $symb=$ENV{'form.symb'};
+ } else {
+ $symb=&Apache::lonnet::symbread($url);
+ }
if ($symb eq '') { $request->print("Unable to handle ambiguous references:$url:."); return ''; }
my $answer=&Apache::loncommon::get_previous_attempt($symb,$uname,$udom,
$ENV{'request.course.id'});
@@ -245,8 +260,8 @@ sub viewgrades {
#start the form
$result = '