Diff for /loncom/homework/bridgetask.pm between versions 1.128.2.7 and 1.129

version 1.128.2.7, 2006/04/10 07:21:14 version 1.129, 2006/03/29 14:03:08
Line 970  DONEBUTTON Line 970  DONEBUTTON
     &Apache::structuretags::finalize_storage();      &Apache::structuretags::finalize_storage();
  }   }
     } elsif ($target eq 'webgrade') {      } elsif ($target eq 'webgrade') {
  $result.="</div>";   $result.="</div>\n<hr />";
  #$result.='<input type="submit" name="next" value="'.   #$result.='<input type="submit" name="next" value="'.
  #    &mt('Save &amp; Next').'" /> ';   #    &mt('Save &amp; Next').'" /> ';
  #$result.='<input type="submit" name="end" value="'.   #$result.='<input type="submit" name="end" value="'.
Line 1315  sub pick_from_queue_data { Line 1315  sub pick_from_queue_data {
     if (@possible) {      if (@possible) {
         # sort entries in order by slot end time          # sort entries in order by slot end time
  @possible = sort { $a->[1] <=> $b->[1] } @possible;   @possible = sort { $a->[1] <=> $b->[1] } @possible;
  # pick one of the entries in the top 10% in small queues and one   # pick one of the first ten entries
  # of the first ten entries in large queues   my $max=($#possible < 10) ? $#possible : 10;
  my $ten_percent = int($#possible * 0.1);  
  if ($ten_percent < 1 ) { $ten_percent = 1;  }  
  if ($ten_percent > 10) { $ten_percent = 10; }  
  my $max=($#possible < $ten_percent) ? $#possible : $ten_percent;  
   
  return $possible[int(rand($max))][0];   return $possible[int(rand($max))][0];
     }      }
     return undef;      return undef;
Line 1765  sub get_instance { Line 1760  sub get_instance {
  my $link=&link($instance,$id);   my $link=&link($instance,$id);
  my $status=$Apache::lonhomework::history{"resource.$version.0.$dim.$instance.$id.status"};   my $status=$Apache::lonhomework::history{"resource.$version.0.$dim.$instance.$id.status"};
  $result.='<div class="LC_GRADING_criteria" id="'.$link.'">'."\n".   $result.='<div class="LC_GRADING_criteria" id="'.$link.'">'."\n".
     '<div class="LC_GRADING_criteriatext" id="next_'.$last_link.'">'."\n";      '<a name="'.$link.'" />'."\n".
       '<a name="next_'.$last_link.'" />'."\n".
       '<div class="LC_GRADING_criteriatext">'."\n";
  @Apache::scripttag::parser_env = @_;   @Apache::scripttag::parser_env = @_;
  $result.=&Apache::scripttag::xmlparse($dimension{$instance.'.criteria.'.$id});   $result.=&Apache::scripttag::xmlparse($dimension{$instance.'.criteria.'.$id});
  $result.='</div>'."\n".   $result.='</div>'."\n".
Line 1875  sub start_IntroParagraph { Line 1872  sub start_IntroParagraph {
   
  } elsif ($tagstack->[-2] eq 'Task' && $target eq 'webgrade') {   } elsif ($tagstack->[-2] eq 'Task' && $target eq 'webgrade') {
     &Apache::lonxml::startredirection();      &Apache::lonxml::startredirection();
    } else {
       &Apache:;lonxml::error("Invalid use of <IntroParagraph> inside of <".$tagstack->[-2].">");
       &Apache::lonxml::get_all_text('/introparagraph',$parser,$style);
  }   }
   
     }      }

Removed from v.1.128.2.7  
changed lines
  Added in v.1.129


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