Diff for /loncom/interface/lonuserutils.pm between versions 1.109 and 1.109.2.2

version 1.109, 2009/12/20 01:49:42 version 1.109.2.2, 2010/01/05 22:08:48
Line 1185  sub default_role_selector { Line 1185  sub default_role_selector {
                     'exs'  => "Existing sections",                      'exs'  => "Existing sections",
                     'new'  => "New section",                      'new'  => "New section",
                   );                    );
     $options = '<select name="defaultrole">'."\n".      $options = '<select name="defaultrole">'."\n";
                ' <option value="">'.&mt('Please select').'</option>'."\n";       unless (($context eq 'course') && (&Apache::loncommon::needs_gci_custom())) {
           $options .= ' <option value="">'.&mt('Please select').'</option>'."\n";
       }
     if ($context eq 'course') {      if ($context eq 'course') {
         $options .= &default_course_roles($context,$checkpriv,$crstype,%customroles);          $options .= &default_course_roles($context,$checkpriv,$crstype,%customroles);
     } elsif ($context eq 'author') {      } elsif ($context eq 'author') {
Line 3655  sub print_first_users_upload_form { Line 3657  sub print_first_users_upload_form {
     $str .= '<input type="hidden" name="action" value="upload" />';      $str .= '<input type="hidden" name="action" value="upload" />';
     $str .= '<input type="hidden" name="state"  value="got_file" />';      $str .= '<input type="hidden" name="state"  value="got_file" />';
   
     $str .= '<h2>'.&mt('Upload a file containing information about users').'</h2>'."\n";      $str .= '<h3>'.&mt('Upload a file containing information about users').'</h3>'."\n";
   
     # Excel and CSV Help      # Excel and CSV Help
     $str .= '<div class="LC_left_float">'      $str .= '<div class="LC_left_float">'
Line 3666  sub print_first_users_upload_form { Line 3668  sub print_first_users_upload_form {
                 &mt("How do I create a CSV file from a spreadsheet"))                  &mt("How do I create a CSV file from a spreadsheet"))
            .'</div><br clear="all" />'."\n";             .'</div><br clear="all" />'."\n";
     $str .= &Apache::lonhtmlcommon::start_pick_box()      $str .= &Apache::lonhtmlcommon::start_pick_box()
            .&Apache::lonhtmlcommon::row_title(&mt('File'));             .&Apache::lonhtmlcommon::row_title(&mt('File'))
     if (&Apache::lonlocal::current_language() ne 'en') {             .&Apache::loncommon::upfile_select_html()
         if ($context eq 'course') {   
             $str .= '<p class="LC_info">'."\n"  
                    .&mt('Please upload an UTF8 encoded file to ensure a correct character encoding in your classlist.')."\n"  
                    .'</p>'."\n";  
         }  
     }  
     $str .= &Apache::loncommon::upfile_select_html()  
            .&Apache::lonhtmlcommon::row_closure()             .&Apache::lonhtmlcommon::row_closure()
            .&Apache::lonhtmlcommon::row_title(             .&Apache::lonhtmlcommon::row_title(
                 '<label for="noFirstLine">'                  '<label for="noFirstLine">'
Line 5030  sub roles_by_context { Line 5025  sub roles_by_context {
         if ($env{'request.role'} =~ m{^dc\./}) {          if ($env{'request.role'} =~ m{^dc\./}) {
             push(@allroles,'ad');              push(@allroles,'ad');
         }          }
         push(@allroles,('ta','ep','in'));          if (&Apache::loncommon::needs_gci_custom()) {
         if ($crstype eq 'Community') {              if ($crstype eq 'Community') {
             push(@allroles,'co');                  push(@allroles,'co');
               } else {
                   push(@allroles,'cc');
               }
         } else {          } else {
             push(@allroles,'cc');              push(@allroles,('ta','ep','in'));
         }              if ($crstype eq 'Community') {
         if ($custom) {                  push(@allroles,'co');
             push(@allroles,'cr');              } else {
                   push(@allroles,'cc');
               }
               if ($custom) {
                   push(@allroles,'cr');
               }
         }          }
     } elsif ($context eq 'author') {      } elsif ($context eq 'author') {
         @allroles = ('ca','aa');          @allroles = ('ca','aa');

Removed from v.1.109  
changed lines
  Added in v.1.109.2.2


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