Diff for /loncom/interface/lonparmset.pm between versions 1.306 and 1.309

version 1.306, 2006/05/16 20:43:57 version 1.309, 2006/06/02 06:48:54
Line 63  use Apache::lonhomework; Line 63  use Apache::lonhomework;
 use Apache::lonxml;  use Apache::lonxml;
 use Apache::lonlocal;  use Apache::lonlocal;
 use Apache::lonnavmaps;  use Apache::lonnavmaps;
   use Apache::longroup;
 use Apache::lonrss;  use Apache::lonrss;
   use lib '/home/httpd/lib/perl/';
   use LONCAPA;
   
 # --- Caches local to lonparmset  # --- Caches local to lonparmset
   
Line 1125  sub usermenu { Line 1128  sub usermenu {
     my %sectionhash = &Apache::loncommon::get_sections();      my %sectionhash = &Apache::loncommon::get_sections();
   
     my $groups;      my $groups;
     my %grouphash = &Apache::loncommon::coursegroups();      my %grouphash = &Apache::longroup::coursegroups();
   
     if (%sectionhash) {      if (%sectionhash) {
         $sections=$lt{'se'}.': <select name="csec"';          $sections=$lt{'se'}.': <select name="csec"';
Line 1265  sub sectionmenu { Line 1268  sub sectionmenu {
   
 sub groupmenu {  sub groupmenu {
     my ($r,$selectedgroups)=@_;      my ($r,$selectedgroups)=@_;
     my %grouphash = &Apache::loncommon::coursegroups();      my %grouphash = &Apache::longroup::coursegroups();
     return if (!%grouphash);      return if (!%grouphash);
   
     $r->print('<select name="Group" multiple="true" size="8" >');      $r->print('<select name="Group" multiple="true" size="8" >');
Line 1731  ENDTABLEHEADFOUR Line 1734  ENDTABLEHEADFOUR
                              '</font></tt><p><b>'.                               '</font></tt><p><b>'.
                              "<a href=\"javascript:openWindow('".                               "<a href=\"javascript:openWindow('".
   &Apache::lonnet::clutter($uri).'?symb='.    &Apache::lonnet::clutter($uri).'?symb='.
   &Apache::lonnet::escape($symbp{$rid}).    &escape($symbp{$rid}).
                              "', 'metadatafile', '450', '500', 'no', 'yes')\";".                               "', 'metadatafile', '450', '500', 'no', 'yes')\";".
                              " TARGET=_self>$title");                               " TARGET=_self>$title");
   
Line 3332  sub standard_parameter_names { Line 3335  sub standard_parameter_names {
    'weight' => 'Weight',     'weight' => 'Weight',
    'date_start' => 'Starting Date',     'date_start' => 'Starting Date',
    'date_end' => 'Ending Date',     'date_end' => 'Ending Date',
                                                      'interval' => 'Time Interval Length',
                                                      'tol' => 'Numerical Tolerance',
                                                      'sig' => 'Significant Digits',
                                                      'contentopen' => 'Content Opening Date',
                                                      'contentclose' => 'Content Closing Date',
                                                      'discussend' => 'End of Discussion Time',
                                                      'discusshide' => 'Discussion Hidden',
                                                      'problemstatus' => 'Problem Status Visible',
    'int_pos' => 'Positive Integer',     'int_pos' => 'Positive Integer',
    'int_zero_pos' => 'Positive Integer or Zero',     'int_zero_pos' => 'Positive Integer or Zero',
    'hinttries' => 'Number of Tries till Hints appear');     'hinttries' => 'Number of Tries till Hints appear');
Line 3342  sub standard_parameter_names { Line 3353  sub standard_parameter_names {
     }      }
 }  }
   
   #
   # Parameter Change Log
   #
   
   
 sub parm_change_log {  sub parm_change_log {
     my ($r)=@_;      my ($r)=@_;
     &startpage($r);      &startpage($r);
Line 3349  sub parm_change_log { Line 3365  sub parm_change_log {
       $env{'course.'.$env{'request.course.id'}.'.domain'},        $env{'course.'.$env{'request.course.id'}.'.domain'},
       $env{'course.'.$env{'request.course.id'}.'.num'});        $env{'course.'.$env{'request.course.id'}.'.num'});
     if ((keys(%parmlog))[0]=~/^error\:/) { undef(%parmlog); }      if ((keys(%parmlog))[0]=~/^error\:/) { undef(%parmlog); }
       $r->print('<form method="post"><input type="hidden" name="action" value="parameterchangelog" />');
       unless ($env{'form.show'}) { $env{'form.show'}=10; }
       my $countselect = &Apache::lonmeta::selectbox('show',
                                                     $env{'form.show'},
                                                     undef,
                                                     (10,20,50,100,1000,10000,100000));
       $r->print('<nobr>'.&mt('[_1] Records',$countselect).'</nobr>'.
         '<input type="submit" value="'.&mt('Display').'" />');
   
     my $courseopt=&Apache::lonnet::get_courseresdata($env{'course.'.$env{'request.course.id'}.'.num'},      my $courseopt=&Apache::lonnet::get_courseresdata($env{'course.'.$env{'request.course.id'}.'.num'},
      $env{'course.'.$env{'request.course.id'}.'.domain'});       $env{'course.'.$env{'request.course.id'}.'.domain'});
Line 3356  sub parm_change_log { Line 3380  sub parm_change_log {
       '<th>'.&mt('Time').'</th><th>'.&mt('User').'</th><th>'.&mt('Extent').'</th><th>'.&mt('Users').'</th><th>'.        '<th>'.&mt('Time').'</th><th>'.&mt('User').'</th><th>'.&mt('Extent').'</th><th>'.&mt('Users').'</th><th>'.
       &mt('Parameter').'</th><th>'.&mt('Part').'</th><th>'.&mt('New Value').'</th><th>'.&mt('Announce').'</th>'.        &mt('Parameter').'</th><th>'.&mt('Part').'</th><th>'.&mt('New Value').'</th><th>'.&mt('Announce').'</th>'.
       &Apache::loncommon::end_data_table_header_row());        &Apache::loncommon::end_data_table_header_row());
       my $shown=0;
     foreach my $id (sort { $parmlog{$b}{'exe_time'}<=>$parmlog{$a}{'exe_time'} } (keys(%parmlog))) {      foreach my $id (sort { $parmlog{$b}{'exe_time'}<=>$parmlog{$a}{'exe_time'} } (keys(%parmlog))) {
         my @changes=keys(%{$parmlog{$id}{'logentry'}});          my @changes=keys(%{$parmlog{$id}{'logentry'}});
  my $count=$#changes+1;   my $count=$#changes+1;
Line 3433  sub parm_change_log { Line 3458  sub parm_change_log {
     }      }
     $r->print(&Apache::loncommon::end_data_table_row());      $r->print(&Apache::loncommon::end_data_table_row());
  }   }
    $shown++;
    if ($shown>=$env{'form.show'}) { last; }
     }      }
     $r->print(&Apache::loncommon::end_data_table());      $r->print(&Apache::loncommon::end_data_table());
       $r->print('</form>');
     $r->print(&Apache::loncommon::end_page());      $r->print(&Apache::loncommon::end_page());
 }  }
   

Removed from v.1.306  
changed lines
  Added in v.1.309


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