--- loncom/interface/Attic/lonspreadsheet.pm 2003/01/30 16:20:08 1.165 +++ loncom/interface/Attic/lonspreadsheet.pm 2003/01/30 18:37:49 1.166 @@ -1,5 +1,5 @@ # -# $Id: lonspreadsheet.pm,v 1.165 2003/01/30 16:20:08 matthew Exp $ +# $Id: lonspreadsheet.pm,v 1.166 2003/01/30 18:37:49 matthew Exp $ # # Copyright Michigan State University Board of Trustees # @@ -1588,7 +1588,6 @@ sub sett { foreach my $col ($self->template_cells()) { next if ($col=~/^$pattern/); foreach my $trow ($self->rows()) { - next if ($trow eq '0'); # Get the name of this cell my $lb=$col.$trow; # Grab the template declaration @@ -1904,7 +1903,7 @@ sub rebuild_stats { $self->{'rows'}=[]; $self->{'template_cells'}=[]; foreach my $cell($self->formulas_keys()) { - push(@{$self->{'rows'}},$1) if ($cell =~ /^A(\d+)/); + push(@{$self->{'rows'}},$1) if ($cell =~ /^A(\d+)/ && $1 != 0); push(@{$self->{'template_cells'}},$1) if ($cell =~ /^template_(\w+)/); } return; @@ -2948,8 +2947,7 @@ sub updateclasssheet { $self->{'maxrow'}= $rownum; } $existing{$f{$cell}}=1; - unless ((defined($currentlist{$f{$cell}})) || ($rownum ne '0') || - ($f{$cell}=~/^(~~~|---)/)) { + if (! defined($currentlist{$f{$cell}}) && ($f{$cell}=~/^(~~~|---)/)) { $f{$cell}='!!! Obsolete'; $changed=1; } @@ -3099,7 +3097,6 @@ sub updatestudentassesssheet { foreach my $rownum ($self->rows()) { my $cell = 'A'.$rownum; my $formula = $f{$cell}; - next if ($rownum eq '0'); $self->{'maxrow'} = $rownum if ($rownum > $self->{'maxrow'}); my ($usy,$ufn)=split(/__&&&\__/,$formula); $existing{$usy}=1; @@ -3147,7 +3144,7 @@ sub loadstudent{ if(defined($c) && ($c->aborted())) { last; } - next if (($value =~ /^[!~-]/) || ($row==0)); + next if ($value =~ /^[!~-]/); my ($usy,$ufn)=split(/__&&&\__/,$value); @assessdata=$self->exportsheet($self->{'uname'}, $self->{'udom'}, @@ -3204,7 +3201,7 @@ ENDPOP last; } my $cell = 'A'.$row; - next if (($formulas{$cell}=~/^[\!\~\-]/) || ($row==0)); + next if ($formulas{$cell}=~/^[\!\~\-]/); my ($sname,$sdom) = split(':',$formulas{$cell}); my $started = time; my @studentdata=$self->exportsheet($sname,$sdom,'studentcalc',