--- loncom/interface/statistics/lonsurveyreports.pm 2005/03/14 20:28:22 1.5 +++ loncom/interface/statistics/lonsurveyreports.pm 2005/03/17 19:02:45 1.6 @@ -1,6 +1,6 @@ # The LearningOnline Network with CAPA # -# $Id: lonsurveyreports.pm,v 1.5 2005/03/14 20:28:22 matthew Exp $ +# $Id: lonsurveyreports.pm,v 1.6 2005/03/17 19:02:45 matthew Exp $ # # Copyright Michigan State University Board of Trustees # @@ -125,10 +125,13 @@ sub BuildSurveyReportsPage { my $resource = $current_problem->{'resource'}; $r->print('

'.$resource->compTitle.'

'); $r->print('

'.$resource->src.'

'); - $r->print(&Apache::lonstathelpers::render_resource($resource)); + if ($ENV{'form.renderprob'} eq 'true') { + $r->print(&Apache::lonstathelpers::render_resource($resource)); + } $r->rflush(); my %Data = &Apache::lonstathelpers::get_problem_data ($resource->src); + &Compile_Student_Answers($current_problem,\%Data,\@Students); if ($ENV{'form.output'} eq 'HTML' || ! defined($ENV{'form.output'})) { &make_HTML_report($r,$current_problem,\%Data,\@Students); @@ -268,7 +271,6 @@ sub Compile_Student_Answers { ######################################################### sub make_Excel_report { my ($r,$problem,$problem_data,$students) = @_; - &Compile_Student_Answers($problem,$problem_data,$students); my ($workbook,$filename,$format) = &Apache::loncommon::create_workbook($r); if (! defined($workbook)) { return '';} $r->print('