Diff for /loncom/interface/loncreateuser.pm between versions 1.304 and 1.305

version 1.304, 2009/08/06 05:48:56 version 1.305, 2009/08/06 20:40:59
Line 5631  sub build_search_response { Line 5631  sub build_search_response {
                     $response .= '<br />'.&mt('You may want to broaden your search to the selected LON-CAPA domain.');                      $response .= '<br />'.&mt('You may want to broaden your search to the selected LON-CAPA domain.');
                 }                  }
             }              }
             if (!($srch->{'srchby'} eq 'uname' && $srch->{'srchin'} eq 'dom' && $srch->{'srchtype'} eq 'exact' && $srch->{'srchdomain'} eq $env{'request.role.domain'})) {              my $createdom = $env{'request.role.domain'};
               if ($context eq 'requestcrs') {
                   if ($env{'form.coursedom'} ne '') {
                       $createdom = $env{'form.coursedom'};
                   }
               }
               if (!($srch->{'srchby'} eq 'uname' && $srch->{'srchin'} eq 'dom' && $srch->{'srchtype'} eq 'exact' && $srch->{'srchdomain'} eq $createdom)) {
                 my $cancreate =                  my $cancreate =
                     &Apache::lonuserutils::can_create_user($env{'request.role.domain'},$context);                      &Apache::lonuserutils::can_create_user($createdom,$context);
                   my $targetdom = '<span class="LC_cusr_emph">'.$createdom.'</span>';
                 if ($cancreate) {                  if ($cancreate) {
                     my $showdom = &display_domain_info($env{'request.role.domain'});                       my $showdom = &display_domain_info($createdom); 
                     $response .= '<br /><br />'                      $response .= '<br /><br />'
                                 .'<b>'.&mt('To add a new user:').'</b>'                                  .'<b>'.&mt('To add a new user:').'</b>'
                                 .'<br />'                                  .'<br />';
                                 .&mt("(You can only create new users in your current role's domain - [_1])"                      if ($context eq 'requestcrs') {
                                     ,'<span class="LC_cusr_emph">'.$env{'request.role.domain'}.'</span>')                          $response .= &mt("(You can only define new users in the new course's domain - [_1])",$targetdom);
                                 .'<ul><li>'                      } else {
                           $response .= &mt("(You can only create new users in your current role's domain - [_1])",$targetdom);
                       }
                       $response .='<ul><li>'
                                 .&mt("Set 'Domain/institution to search' to: [_1]",'<span class="LC_cusr_emph">'.$showdom.'</span>')                                  .&mt("Set 'Domain/institution to search' to: [_1]",'<span class="LC_cusr_emph">'.$showdom.'</span>')
                                 .'</li><li>'                                  .'</li><li>'
                                 .&mt("Set 'Search criteria' to: [_1]username is ..... in selected LON-CAPA domain[_2]",'<span class="LC_cusr_emph">','</span>')                                  .&mt("Set 'Search criteria' to: [_1]username is ..... in selected LON-CAPA domain[_2]",'<span class="LC_cusr_emph">','</span>')
Line 5652  sub build_search_response { Line 5662  sub build_search_response {
                                 .'</li></ul><br />';                                  .'</li></ul><br />';
                 } else {                  } else {
                     my $helplink = ' href="javascript:helpMenu('."'display'".')"';                      my $helplink = ' href="javascript:helpMenu('."'display'".')"';
                     $response .= '<br /><br />'                      $response .= '<br /><br />';
                                 .&mt("You are not authorized to create new users in your current role's domain - [_1]."                      if ($context eq 'requestcrs') {
                                     ,'<span class="LC_cusr_emph">'.$env{'request.role.domain'}.'</span>')                          $response .= &mt("You are not authorized to defined new users in the new course's domain - [_1].",$targetdom);
                                 .'<br />'                      } else {
                                 .&mt('Please contact the [_1]helpdesk[_2] if you need to create a new user.'                          $response .= &mt("You are not authorized to create new users in your current role's domain - [_1].",$targetdom);
                       }
                       $response .= '<br />'
                                    .&mt('Please contact the [_1]helpdesk[_2] if you need to create a new user.'
                                     ,' <a'.$helplink.'>'                                      ,' <a'.$helplink.'>'
                                     ,'</a>')                                      ,'</a>')
                                 .'<br /><br />';                                   .'<br /><br />';
                 }                  }
             }              }
         }          }

Removed from v.1.304  
changed lines
  Added in v.1.305


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