Diff for /loncom/interface/statistics/lonsurveyreports.pm between versions 1.18 and 1.21

version 1.18, 2008/10/23 09:07:51 version 1.21, 2008/12/11 14:55:27
Line 133  sub BuildSurveyReportsPage { Line 133  sub BuildSurveyReportsPage {
             $r->print('<h1>'.$resource->compTitle.'</h1>');              $r->print('<h1>'.$resource->compTitle.'</h1>');
             $r->print('<h3>'.$resource->src.'</h3>');              $r->print('<h3>'.$resource->src.'</h3>');
             if ($env{'form.renderprob'} eq 'true') {              if ($env{'form.renderprob'} eq 'true') {
                 $r->print(&Apache::lonstathelpers::render_resource($resource));                  $r->print('<hr />'
                            .&Apache::lonstathelpers::render_resource($resource)
                            .'<hr />'
                   );
             }              }
             $r->rflush();              $r->rflush();
             my %Data = &Apache::lonstathelpers::get_problem_data              my %Data = &Apache::lonstathelpers::get_problem_data
Line 201  sub SurveyProblemSelector { Line 204  sub SurveyProblemSelector {
               resptype=>undef});                resptype=>undef});
         my $checked = '';          my $checked = '';
         if ($env{'form.problemchoice'} eq $value) {          if ($env{'form.problemchoice'} eq $value) {
             $checked = 'checked ';              $checked = 'checked="checked" ';
         }          }
         my $link = $problem->{'res'}->link.          my $link = $problem->{'res'}->link.
             '?symb='.&escape($problem->{'res'}->shown_symb);              '?symb='.&escape($problem->{'res'}->shown_symb);
         $Str .= '<tr><td>'.          $Str .= '<tr><td>'.
             '<input type="radio" name="problemchoice" id="'.$id.'" '.              '<input type="radio" name="problemchoice" id="'.$id.'" '.
                    'value="'.$value.'" '.$checked.'/>'.'</td>'.                     'value="'.$value.'" '.$checked.'/>'.'</td>'.
             '<td><nobr>'.              '<td><span class="LC_nobreak">'.
             '<label for="'.$id.'">'.$problem->{'res'}->compTitle.' ('.$problem->{'seq'}->compTitle.')'.'</label>'.              '<label for="'.$id.'">'.$problem->{'res'}->compTitle.' ('.$problem->{'seq'}->compTitle.')'.'</label>'.
             ('&nbsp;'x2).              ('&nbsp;'x2).
             '<a target="preview" href="'.$link.'">'.&mt('View survey').'</a>'.'</td></tr>'.$/;              '<a target="preview" href="'.$link.'">'.&mt('View survey').'</a>'.'</span></td></tr>'.$/;
     }      }
     $Str .= '</table>';      $Str .= '</table>';
     return $Str;      return $Str;
Line 566  sub make_HTML_report { Line 569  sub make_HTML_report {
                             sprintf("%.2f",$count/$total*100).'%</td>'.                              sprintf("%.2f",$count/$total*100).'%</td>'.
                         &Apache::loncommon::end_data_table_row().$/;                          &Apache::loncommon::end_data_table_row().$/;
                 }                  }
                 $Str .= &Apache::loncommon::start_data_table_row().                  $Str.='<tr>'
                     '<th>'.&mt('Foil Name').'</th>'.                       .'<td colspan="3">'
                     '<th>'.&mt('Text').'</th>'.                       .&Apache::loncommon::start_data_table()
                     '<th>'.&mt('Freq').'</th>'.                       .&Apache::loncommon::start_data_table_header_row()
                     '<th>'.&mt('Percent').'</th>'.                       .'<th>'.&mt('Foil Name').'</th>'
                     &Apache::loncommon::end_data_table_row().$/.                       .'<th>'.&mt('Text').'</th>'
                     $tmp;                       .'<th>'.&mt('Frequency').'</th>'
                        .'<th>'.&mt('Percent').'</th>'
                        .&Apache::loncommon::end_data_table_header_row().$/
                        .$tmp
                        .&Apache::loncommon::end_data_table()
                        .'</td></tr>';
             }              }
             $Str.= &Apache::loncommon::end_data_table().'<hr />';              $Str.= '</table>';
             $r->print($Str);              $r->print($Str);
             $r->rflush();              $r->rflush();
         }          }
Line 613  sub CreateInterface { Line 621  sub CreateInterface {
                                 ) {                                  ) {
         $output_selector.='<option value="'.$output_format->{'name'}.'"';          $output_selector.='<option value="'.$output_format->{'name'}.'"';
         if ($env{'form.output'} eq $output_format->{'name'}) {          if ($env{'form.output'} eq $output_format->{'name'}) {
             $output_selector.=' selected';              $output_selector.=' selected="selected"';
         }          }
         $output_selector.= '>'.$output_format->{'text'}.'</option>'.$/;          $output_selector.= '>'.$output_format->{'text'}.'</option>'.$/;
     }      }
     $output_selector .= '</select>'.$/;      $output_selector .= '</select>'.$/;
     $Str .= &Apache::lonhtmlcommon::breadcrumbs('Student Submission Reports');      $Str .= &Apache::lonhtmlcommon::breadcrumbs('Student Submission Reports');
     $Str .= '<p>';      $Str .= '<p>';
     $Str .= '<table cellspacing="5">'."\n";      $Str .= &Apache::loncommon::start_data_table();
     $Str .= '<tr>';      $Str .= &Apache::loncommon::start_data_table_header_row();
     $Str .= '<th>'.&mt('Sections').'</th>';      $Str .= '<th>'.&mt('Sections').'</th>';
     $Str .= '<th>'.&mt('Groups').'</th>';      $Str .= '<th>'.&mt('Groups').'</th>';
     $Str .= '<th>'.&mt('Access Status').'</th>';      $Str .= '<th>'.&mt('Access Status').'</th>';
     $Str .= '<th>'.&mt('Output Format').'</th>';      $Str .= '<th>'.&mt('Output Format').'</th>';
     $Str .= '<th>'.'&nbsp;'.'</th>';      $Str .= '<th>'.&mt('Options').'</th>';
     $Str .= '</tr>'."\n";      $Str .= &Apache::loncommon::end_data_table_header_row();
     #      #
     $Str .= '<tr><td align="center">'."\n";      $Str .= &Apache::loncommon::start_data_table_row();
       $Str .= '<td align="center">'."\n";
     $Str .= &Apache::lonstatistics::SectionSelect('Section','multiple',5);      $Str .= &Apache::lonstatistics::SectionSelect('Section','multiple',5);
     $Str .= '</td>';      $Str .= '</td>';
     #      #
Line 646  sub CreateInterface { Line 655  sub CreateInterface {
     # Render problem checkbox      # Render problem checkbox
     my $prob_checkbox = '<input type="checkbox" name="renderprob" ';      my $prob_checkbox = '<input type="checkbox" name="renderprob" ';
     if (exists($env{'form.renderprob'}) && $env{'form.renderprob'} eq 'true') {      if (exists($env{'form.renderprob'}) && $env{'form.renderprob'} eq 'true') {
         $prob_checkbox .= 'checked ';          $prob_checkbox .= 'checked="checked" ';
     }      }
     $prob_checkbox .= 'value="true" />';      $prob_checkbox .= 'value="true" />';
     $Str .= '<td align="right" valign="top">'.      $Str .= '<td align="right" valign="top">'.
Line 655  sub CreateInterface { Line 664  sub CreateInterface {
         '<label><b>'.          '<label><b>'.
         '</td>';          '</td>';
     #      #
     $Str .= '</tr>'."\n";      $Str .= &Apache::loncommon::end_data_table_row();
     $Str .= '</table>'."\n";      $Str .= &Apache::loncommon::end_data_table();
     #      #
     $Str .= '<p><span class="LC_nobreak">'      $Str .= '<p><span class="LC_nobreak">'
            .&mt('Status: [_1]',             .&mt('Status: [_1]',

Removed from v.1.18  
changed lines
  Added in v.1.21


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>