version 1.726, 2014/11/08 18:26:01
|
version 1.727, 2014/11/21 17:59:11
|
Line 3019 sub saveHandGrade {
|
Line 3019 sub saveHandGrade {
|
my %aggregate = (); |
my %aggregate = (); |
my $aggregateflag = 0; |
my $aggregateflag = 0; |
if ($env{'form.HIDE'.$newflg}) { |
if ($env{'form.HIDE'.$newflg}) { |
my $numchgs = &makehidden($newflg,\%record,$symb,$domain,$stuname); |
my ($version,$parts) = split(/:/,$env{'form.HIDE'.$newflg},2); |
|
my $numchgs = &makehidden($version,$parts,\%record,$symb,$domain,$stuname); |
$totchg += $numchgs; |
$totchg += $numchgs; |
} |
} |
my @parts = split(/:/,$env{'form.partlist'.$newflg}); |
my @parts = split(/:/,$env{'form.partlist'.$newflg}); |
Line 3128 sub saveHandGrade {
|
Line 3129 sub saveHandGrade {
|
} |
} |
|
|
sub makehidden { |
sub makehidden { |
my ($newflg,$record,$symb,$domain,$stuname) = @_; |
my ($version,$parts,$record,$symb,$domain,$stuname) = @_; |
return unless (ref($record) eq 'HASH'); |
return unless (ref($record) eq 'HASH'); |
my %modified; |
my %modified; |
my $numchanged = 0; |
my $numchanged = 0; |
my ($version,$parts) = split(/:/,$env{'form.HIDE'.$newflg},2); |
|
if (exists($record->{$version.':keys'})) { |
if (exists($record->{$version.':keys'})) { |
my $partsregexp = $parts; |
my $partsregexp = $parts; |
$partsregexp =~ s/,/|/g; |
$partsregexp =~ s/,/|/g; |
Line 5063 sub updateGradeByPage {
|
Line 5063 sub updateGradeByPage {
|
my $aggregateflag = 0; |
my $aggregateflag = 0; |
if ($env{'form.HIDE'.$prob}) { |
if ($env{'form.HIDE'.$prob}) { |
my %record = &Apache::lonnet::restore($symbx,$env{'request.course.id'},$udom,$uname); |
my %record = &Apache::lonnet::restore($symbx,$env{'request.course.id'},$udom,$uname); |
my $numchgs = &makehidden($prob,\%record,$symbx,$udom,$uname); |
my ($version,$parts) = split(/:/,$env{'form.HIDE'.$prob},2); |
|
my $numchgs = &makehidden($version,$parts,\%record,$symbx,$udom,$uname); |
$hideflag += $numchgs; |
$hideflag += $numchgs; |
} |
} |
foreach my $partid (@{$parts}) { |
foreach my $partid (@{$parts}) { |