--- loncom/interface/statistics/lonproblemstatistics.pm 2004/03/29 15:58:33 1.74 +++ loncom/interface/statistics/lonproblemstatistics.pm 2004/03/29 18:22:28 1.75 @@ -1,6 +1,6 @@ # The LearningOnline Network with CAPA # -# $Id: lonproblemstatistics.pm,v 1.74 2004/03/29 15:58:33 matthew Exp $ +# $Id: lonproblemstatistics.pm,v 1.75 2004/03/29 18:22:28 matthew Exp $ # # Copyright Michigan State University Board of Trustees # @@ -310,18 +310,34 @@ sub BuildProblemStatisticsPage { # This probably does not need to be done each time we are called, but # it does not slow things down noticably. &Apache::loncoursedata::populate_weight_table(); + # if (exists($ENV{'form.Excel'})) { &Excel_output($r); } else { + my $count = 0; + foreach my $seq (&Apache::lonstatistics::Sequences_with_Assess()) { + $count += $seq->{'num_assess'}; + } + if ($count > 10) { + $r->print('

'. + &mt('Compiling statistics for [_1] problems',$count). + '

'); + if ($count > 30) { + $r->print('

'.&mt('This will take some time.').'

'); + } + $r->rflush(); + } + # my $sortby = $ENV{'form.sortby'}; $sortby = 'container' if (! defined($sortby) || $sortby =~ /^\s*$/); my $plot = $ENV{'form.plot'}; - &Apache::lonnet::logthis('form.plot = '.$plot); + if ($plot eq '' || $plot eq 'none') { + undef($plot); + } if ($sortby eq 'container' && ! defined($plot)) { &output_html_by_sequence($r); } else { if (defined($plot)) { - &Apache::lonnet::logthis('calling plot routine'); &make_plot($r,$plot); } &output_html_stats($r); @@ -385,7 +401,6 @@ sub output_html_stats { return; } - sub html_preamble { my $Str=''; $Str .= "

".