Diff for /loncom/homework/grades.pm between versions 1.186 and 1.187

version 1.186, 2004/04/20 06:11:49 version 1.187, 2004/04/22 22:57:53
Line 3487  sub scantron_selectphase { Line 3487  sub scantron_selectphase {
     <table width="100%" border="0">      <table width="100%" border="0">
     <tr>      <tr>
       <td bgcolor="#777777">        <td bgcolor="#777777">
        <form method="post" enctype="multipart/form-data" action="/adm/grades" name="scantro_process">         <form method="post" enctype="multipart/form-data" action="/adm/grades" name="scantron_process">
        <input type="hidden" name="command" value="scantron_validate" />         <input type="hidden" name="command" value="scantron_validate" />
         $default_form_data          $default_form_data
         <table width="100%" border="0">          <table width="100%" border="0">
Line 3519  sub scantron_selectphase { Line 3519  sub scantron_selectphase {
     </td>      </td>
           </tr>            </tr>
           <tr bgcolor="#ffffe6">            <tr bgcolor="#ffffe6">
       <td> Options: </td>
               <td>
                   <input type="checkbox" name="scantron_options" value="redo_skipped"/> Redo skipped records <br />
                   <input type="checkbox" name="scantron_options" value="ignore_corrections"/> Ignore Original Corrections
       </td>
             </tr>
             <tr bgcolor="#ffffe6">
             <td colspan="2">              <td colspan="2">
               <input type="submit" value="Validate Scantron Records" />                <input type="submit" value="Validate Scantron Records" />
             </td>              </td>
Line 3579  UPLOAD Line 3586  UPLOAD
     </tr>      </tr>
 SCANTRONFORM  SCANTRONFORM
     }      }
       $r->print(<<SCANTRONFORM);
       <tr>
         <td bgcolor="#777777">
           <form action='/adm/grades' name='scantron_download'>
             <input type="hidden" name="command" value="scantron_download" />
             <table width="100%" border="0">
               <tr bgcolor="#e6ffff">
                 <td colspan="2">
                   &nbsp;<b>Download a scoring office file</b>
                 </td>
               </tr>
               <tr bgcolor="#ffffe6">
                 <td> Filename of scoring office file: </td><td> $file_selector </td>
               </tr>
               <tr bgcolor="#ffffe6">
         <td>
                   Records to download
                 </td>
                 <td>
                     <input type="radio" name="scantron_options" value="download_skipped"/> Skipped Records <br />
                     <input type="radio" name="scantron_options" value="download_corrected"/> Corrected Records <br />
                     <input checked="on" type="radio" name="scantron_options" value="dowload_orig"/> Original Records
                 </td>
               </tr>
               <tr bgcolor="#ffffe6">
                 <td colspan="2">
                   <input type="submit" value="Validate Scantron Records" />
                 </td>
               </tr>
             </table>
           </form>
         </td>
       </tr>
   SCANTRONFORM
   
     $r->print(<<SCANTRONFORM);      $r->print(<<SCANTRONFORM);
   </table>    </table>
Line 3690  sub scan_data { Line 3731  sub scan_data {
 }  }
   
 sub scantron_parse_scanline {  sub scantron_parse_scanline {
     my ($line,$whichline,$scantron_config,$scan_data)=@_;      my ($line,$whichline,$scantron_config,$scan_data,$justCODE)=@_;
     my %record;      my %record;
     my $questions=substr($line,$$scantron_config{'Qstart'}-1);      my $questions=substr($line,$$scantron_config{'Qstart'}-1);
     my $data=substr($line,0,$$scantron_config{'Qstart'}-1);      my $data=substr($line,0,$$scantron_config{'Qstart'}-1);
Line 3702  sub scantron_parse_scanline { Line 3743  sub scantron_parse_scanline {
     #FIXME interpret first N questions      #FIXME interpret first N questions
  }   }
     }      }
       if ($justCODE) { return \%record; }
     $record{'scantron.ID'}=substr($data,$$scantron_config{'IDstart'}-1,      $record{'scantron.ID'}=substr($data,$$scantron_config{'IDstart'}-1,
   $$scantron_config{'IDlength'});    $$scantron_config{'IDlength'});
     $record{'scantron.PaperID'}=      $record{'scantron.PaperID'}=
Line 4061  sub scantron_get_correction { Line 4103  sub scantron_get_correction {
  $r->print('</li>');   $r->print('</li>');
     } elsif ($error =~ /CODE$/) {      } elsif ($error =~ /CODE$/) {
  if ($error eq 'incorrectCODE') {   if ($error eq 'incorrectCODE') {
     $r->print("The encoded CODE is not in the list of possible CODEs</p>\n");      $r->print("</p><p>The encoded CODE is not in the list of possible CODEs</p>\n");
  } elsif ($error eq 'duplicateCODE') {   } elsif ($error eq 'duplicateCODE') {
     $r->print("The encoded CODE has also been used by a previous paper $arg, and CODEs were supposed to be unique</p>\n");      $r->print("</p><p>The encoded CODE has also been used by a previous paper $arg, and CODEs were supposed to be unique</p>\n");
  }   }
    $r->print("<p>The CODE on the form is  <tt>".
     $$scan_record{'scantron.CODE'}."</tt><br />\n");
  $r->print("<p>The ID on the form is  <tt>".   $r->print("<p>The ID on the form is  <tt>".
   $$scan_record{'scantron.ID'}."</tt><br />\n");    $$scan_record{'scantron.ID'}."</tt><br />\n");
  $r->print("The name on the paper is ".   $r->print("The name on the paper is ".
   $$scan_record{'scantron.LastName'}.",".    $$scan_record{'scantron.LastName'}.",".
   $$scan_record{'scantron.FirstName'}."</p>");    $$scan_record{'scantron.FirstName'}."</p>");
  $r->print("<p>How should I handle this? <br /> \n");   $r->print("<p>How should I handle this? <br /> \n");
  $r->print("\n<ul><li> ");   $r->print("\n<br /> ");
  $r->print('</li>');   $r->print("<input type='radio' name='scan_CODE_resolution' value='use_unfound' checked='on' /> Use the CODE <b><tt>".$$scan_record{'scantron.CODE'}."</tt></b> that is was on the paper, ignoring the error.");
    $r->print("\n<br />");
    my $href="/adm/pickcode?".
      "form=".&Apache::lonnet::escape("scantronupload").
      "&scantron_format=".&Apache::lonnet::escape($ENV{'form.scantron_format'}).
      "&scantron_CODElist=".&Apache::lonnet::escape($ENV{'form.scantron_CODElist'}).
      "&curCODE=".&Apache::lonnet::escape($$scan_record{'scantron.CODE'}).
      "&scantron_selectfile=".&Apache::lonnet::escape($ENV{'form.scantron_selectfile'});
    $r->print("<input type='radio' name='scan_CODE_resolution' value='use_found' /> <a target='_blank' href='$href'>Select</a> a CODE from the list of all CODEs and use it. Selected CODE is <input type='text' size='8' name='scan_CODE_selectedvalue' />");
    $r->print("\n<br />");
    $r->print("<input type='radio' name='scan_CODE_resolution' value='use_typed' /> Use <input type='text' size='8' name='scan_CODE_newvalue' /> as the CODE.");
    $r->print("\n<br /><br />");
     } elsif ($error eq 'doublebubble') {      } elsif ($error eq 'doublebubble') {
 #FIXME Need to print out who this is along with the paper info  #FIXME Need to print out who this is along with the paper info
  $r->print("<p>There have been multiple bubbles scanned for a some question(s)</p>\n");   $r->print("<p>There have been multiple bubbles scanned for a some question(s)</p>\n");

Removed from v.1.186  
changed lines
  Added in v.1.187


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