version 1.172, 2003/02/17 16:29:51
|
version 1.173, 2003/03/03 22:00:03
|
Line 3198 sub loadcourse {
|
Line 3198 sub loadcourse {
|
foreach ($self->rows()) { |
foreach ($self->rows()) { |
$total++ if ($formulas{'A'.$_} !~ /^[!~-]/); |
$total++ if ($formulas{'A'.$_} !~ /^[!~-]/); |
} |
} |
my $now=0; |
|
my $since=time; |
my %prog_state=&Apache::lonhtmlcommon::Create_PrgWin($r, |
$r->print(<<ENDPOP); |
'Spreadsheet Status','Spreadsheet Calculation Progress', $total); |
<script> |
&Apache::lonhtmlcommon::Update_PrgWin($r,\%prog_state, |
popwin=open('','popwin','width=400,height=100'); |
'Processing Course Assessment Data'); |
popwin.document.writeln('<html><body bgcolor="#FFFFFF">'+ |
|
'<h3>Spreadsheet Calculation Progress</h3>'+ |
|
'<form name=popremain>'+ |
|
'<input type=text size=45 name=remaining value="Processing Course Assessment Data"></form>'+ |
|
'</body></html>'); |
|
popwin.document.close(); |
|
</script> |
|
ENDPOP |
|
$r->rflush(); |
|
# It would be nice to load in the classlist and assessment info at this |
# It would be nice to load in the classlist and assessment info at this |
# point, before attacking the student spreadsheets. |
# point, before attacking the student spreadsheets. |
foreach my $row ($self->rows()) { |
foreach my $row ($self->rows()) { |
Line 3225 ENDPOP
|
Line 3217 ENDPOP
|
my @studentdata=$self->exportsheet($sname,$sdom,'studentcalc', |
my @studentdata=$self->exportsheet($sname,$sdom,'studentcalc', |
undef,undef,$r); |
undef,undef,$r); |
undef %userrdatas; |
undef %userrdatas; |
$now++; |
&Apache::lonhtmlcommon::Increment_PrgWin($r,\%prog_state, |
$r->print('<script>popwin.document.popremain.remaining.value="'. |
'last student'); |
$now.'/'.$total.': '.int((time-$since)/$now*($total-$now)). |
|
' secs remaining '.(time-$started).' last student";'. |
|
'</script>'); |
|
$r->rflush(); |
|
# |
|
my $index=0; |
my $index=0; |
foreach ('A','B','C','D','E','F','G','H','I','J','K','L','M', |
foreach ('A','B','C','D','E','F','G','H','I','J','K','L','M', |
'N','O','P','Q','R','S','T','U','V','W','X','Y','Z') { |
'N','O','P','Q','R','S','T','U','V','W','X','Y','Z') { |
Line 3251 ENDPOP
|
Line 3238 ENDPOP
|
} |
} |
$self->formulas(\%formulas); |
$self->formulas(\%formulas); |
$self->constants(\%constants); |
$self->constants(\%constants); |
$r->print('<script>popwin.close()</script>'); |
&Apache::lonhtmlcommon::Close_PrgWin($r,\%prog_state); |
$r->rflush(); |
|
} |
} |
|
|
# ------------------------------------------------ Load data for one assessment |
# ------------------------------------------------ Load data for one assessment |