version 1.747, 2017/12/21 23:20:48
|
version 1.748, 2017/12/31 13:29:53
|
Line 4090 sub editgrades {
|
Line 4090 sub editgrades {
|
$ctr++; |
$ctr++; |
} |
} |
my (undef,undef,$url) = &Apache::lonnet::decode_symb($symb); |
my (undef,undef,$url) = &Apache::lonnet::decode_symb($symb); |
|
my $totcolspan = 0; |
foreach my $partid (@partid) { |
foreach my $partid (@partid) { |
$header .= '<th align="center">'.&mt('Old Score').'</th>'. |
$header .= '<th align="center">'.&mt('Old Score').'</th>'. |
'<th align="center">'.&mt('New Score').'</th>'; |
'<th align="center">'.&mt('New Score').'</th>'; |
Line 4106 sub editgrades {
|
Line 4107 sub editgrades {
|
'<th align="center">'.&mt('New').' '.$display.'</th>'; |
'<th align="center">'.&mt('New').' '.$display.'</th>'; |
$columns{$partid}+=2; |
$columns{$partid}+=2; |
} |
} |
|
$totcolspan += $columns{$partid}; |
} |
} |
foreach my $partid (@partid) { |
foreach my $partid (@partid) { |
my $display_part=&get_display_part($partid,$symb); |
my $display_part=&get_display_part($partid,$symb); |
Line 4121 sub editgrades {
|
Line 4123 sub editgrades {
|
my @noupdate; |
my @noupdate; |
my ($updateCtr,$noupdateCtr) = (1,1); |
my ($updateCtr,$noupdateCtr) = (1,1); |
for ($i=0; $i<$env{'form.total'}; $i++) { |
for ($i=0; $i<$env{'form.total'}; $i++) { |
my $line; |
|
my $user = $env{'form.ctr'.$i}; |
my $user = $env{'form.ctr'.$i}; |
my ($uname,$udom)=split(/:/,$user); |
my ($uname,$udom)=split(/:/,$user); |
my %newrecord; |
my %newrecord; |
my $updateflag = 0; |
my $updateflag = 0; |
$line .= '<td>'.&nameUserString(undef,$$fullname{$user},$uname,$udom).'</td>'; |
|
my $usec=$classlist->{"$uname:$udom"}[5]; |
my $usec=$classlist->{"$uname:$udom"}[5]; |
if (!&canmodify($usec)) { |
my $canmodify = &canmodify($usec); |
my $numcols=scalar(@partid)*4+2; |
my $line = '<td'.($canmodify?'':' colspan="2"').'>'. |
|
&nameUserString(undef,$$fullname{$user},$uname,$udom).'</td>'; |
|
if (!$canmodify) { |
push(@noupdate, |
push(@noupdate, |
$line."<td colspan=\"$numcols\"><span class=\"LC_warning\">". |
$line."<td colspan=\"$totcolspan\"><span class=\"LC_warning\">". |
&mt('Not allowed to modify student')."</span></td></tr>"); |
&mt('Not allowed to modify student')."</span></td>"); |
next; |
next; |
} |
} |
my %aggregate = (); |
my %aggregate = (); |
Line 4249 sub editgrades {
|
Line 4251 sub editgrades {
|
} |
} |
} |
} |
if (@noupdate) { |
if (@noupdate) { |
# my $numcols=(scalar(@partid)*(scalar(@parts)-1)*2)+3; |
my $numcols=$totcolspan+2; |
my $numcols=scalar(@partid)*4+2; |
|
$result .= &Apache::loncommon::start_data_table_row('LC_empty_row'). |
$result .= &Apache::loncommon::start_data_table_row('LC_empty_row'). |
'<td align="center" colspan="'.$numcols.'">'. |
'<td align="center" colspan="'.$numcols.'">'. |
&mt('No Changes Occurred For the Students Below'). |
&mt('No Changes Occurred For the Students Below'). |