--- loncom/interface/statistics/lonsurveyreports.pm 2008/12/11 14:55:27 1.21 +++ loncom/interface/statistics/lonsurveyreports.pm 2012/05/12 03:59:53 1.26.4.1 @@ -1,6 +1,6 @@ # The LearningOnline Network with CAPA # -# $Id: lonsurveyreports.pm,v 1.21 2008/12/11 14:55:27 bisitz Exp $ +# $Id: lonsurveyreports.pm,v 1.26.4.1 2012/05/12 03:59:53 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -63,10 +63,12 @@ sub BuildSurveyReportsPage { ); &Apache::loncommon::store_course_settings('survey_reports', \%Saveable_Parameters); - &Apache::loncommon::restore_course_settings('survey_resports', + &Apache::loncommon::restore_course_settings('survey_reports', \%Saveable_Parameters); # &Apache::lonstatistics::PrepareClasslist(); + $r->print(&Apache::lonhtmlcommon::breadcrumbs('Student Submission Reports')); + # $r->print(&CreateInterface()); # @@ -98,7 +100,7 @@ sub BuildSurveyReportsPage { # $r->print('
'); $r->print('

'. - &Apache::lonlocal::locallocaltime(time).','. + &Apache::lonlocal::locallocaltime(time).', '. &Apache::lonstatistics::section_and_enrollment_description(). '

'); $r->rflush(); @@ -177,7 +179,7 @@ sub SurveyProblemSelector { my @resources = &Apache::lonstathelpers::get_resources($navmap,$seq); foreach my $res (@resources) { foreach my $part (@{$res->parts}) { - if ($res->is_survey($part)) { + if (($res->is_survey($part)) || ($res->is_anonsurvey($part))) { push(@SurveyProblems,{res=>$res,seq=>$seq,part=>$part}); last; } @@ -214,7 +216,7 @@ sub SurveyProblemSelector { ''. ''. (' 'x2). - ''.&mt('View survey').''.''.$/; + ''.&mt('View survey').''.$/; } $Str .= ''; return $Str; @@ -230,10 +232,7 @@ sub SurveyProblemSelector { sub compile_student_answers { my ($r,$problem,$ProblemData,$Students) = @_; my $resource = $problem->{'resource'}; - my %prog_state=&Apache::lonhtmlcommon::Create_PrgWin - ($r,'Processing Student Submissions', - 'Processing Student Submissions', - scalar(@$Students),'inline',undef,'Statistics','stats_status'); + my %prog_state=&Apache::lonhtmlcommon::Create_PrgWin($r,scalar(@$Students)); foreach my $student (@$Students) { foreach my $partid (@{$resource->parts}) { my @response_ids = $resource->responseIds($partid); @@ -275,8 +274,7 @@ sub compile_student_answers { } } } - &Apache::lonhtmlcommon::Increment_PrgWin($r,\%prog_state, - 'last student'); + &Apache::lonhtmlcommon::Increment_PrgWin($r,\%prog_state,'last student'); } &Apache::lonhtmlcommon::Close_PrgWin($r,\%prog_state); return; @@ -339,7 +337,7 @@ sub make_text_report { } else { $r->print('

' .&mt('There is no essay or string response data to output for this survey.') - .''); + .'

'); } $r->rflush(); return; @@ -626,7 +624,6 @@ sub CreateInterface { $output_selector.= '>'.$output_format->{'text'}.''.$/; } $output_selector .= ''.$/; - $Str .= &Apache::lonhtmlcommon::breadcrumbs('Student Submission Reports'); $Str .= '

'; $Str .= &Apache::loncommon::start_data_table(); $Str .= &Apache::loncommon::start_data_table_header_row(); @@ -658,20 +655,16 @@ sub CreateInterface { $prob_checkbox .= 'checked="checked" '; } $prob_checkbox .= 'value="true" />'; - $Str .= ''. - '
'. - '

' - .&mt('Status: [_1]', - '') - .'

'; $Str .= '

'; ## return $Str;