Diff for /loncom/interface/lonpopulate.pm between versions 1.82 and 1.83

version 1.82, 2014/12/12 14:30:47 version 1.83, 2015/06/09 21:22:57
Line 51  sub header { Line 51  sub header {
 sub choose_header {  sub choose_header {
     my ($action) = @_;      my ($action) = @_;
     my $notify_check = '/^note_[0-9]+$/';      my $notify_check = '/^note_[0-9]+$/';
     my %lt =       my %js_lt = 
         &Apache::lonlocal::texthash(          &Apache::lonlocal::texthash(
             adds => 'You must select either "Enable" or "Disable" for nightly additions based on classlist changes',              adds => 'You must select either "Enable" or "Disable" for nightly additions based on classlist changes',
             drop => 'You must select either "Enable" or "Disable" for nightly removals based on classlist changes',              drop => 'You must select either "Enable" or "Disable" for nightly removals based on classlist changes',
Line 61  sub choose_header { Line 61  sub choose_header {
             ynot => 'You have indicated that you want notification of roster changes messages to be sent, but you have not selected any recipients.',              ynot => 'You have indicated that you want notification of roster changes messages to be sent, but you have not selected any recipients.',
             atle => 'You must check at least one checkbox, before proceeding to the next page',              atle => 'You must check at least one checkbox, before proceeding to the next page',
     );      );
     $lt{'both'} = &mt('You have selected "No" for both addition and removal of students[_1] in the institutional classlist but not in your LON-CAPA course.[_1]','\\n');      $js_lt{'both'} = &mt('You have selected "No" for both addition and removal of students[_1] in the institutional classlist but not in your LON-CAPA course.[_1]',"\n");
     $lt{'nnot'} = &mt('You have indicated that you do not want notification of roster changes messages to be sent, but [_1] have been checked as recipients.[_2]',"'+totalnote+'",'\\n');      $js_lt{'nnot'} = &mt('You have indicated that you do not want notification of roster changes messages to be sent, but [_1] have been checked as recipients.[_2]',"'+totalnote+'","\n");
       &js_escape(\%js_lt);
           
     my $scripttag = <<ENDJSONE;      my $scripttag = <<ENDJSONE;
 <script type="text/javascript" language="JavaScript">  <script type="text/javascript" language="JavaScript">
Line 88  function process(calling,numauto,nummanu Line 89  function process(calling,numauto,nummanu
        }         }
    }     }
    if (rad1 == 0) {     if (rad1 == 0) {
        alert('$lt{'adds'}');         alert('$js_lt{'adds'}');
        checker = 0         checker = 0
    }     }
    if (rad2 == 0) {     if (rad2 == 0) {
        alert('$lt{'drop'}');         alert('$js_lt{'drop'}');
        checker = 0         checker = 0
    }     }
  }   }
Line 116  function process(calling,numauto,nummanu Line 117  function process(calling,numauto,nummanu
          }           }
      }       }
      if (rad1 == 0) {       if (rad1 == 0) {
          alert('$lt{'drop'}');           alert('$js_lt{'drop'}');
          checker = 0;           checker = 0;
      }       }
      if (rad2 == 0) {       if (rad2 == 0) {
          alert('$lt{'ysno'}');           alert('$js_lt{'ysno'}');
          checker = 0;           checker = 0;
      }       }
      if (formName.updatedrops[unenrolldis].checked && formName.updateadds[enrolldis].checked ) {       if (formName.updatedrops[unenrolldis].checked && formName.updateadds[enrolldis].checked ) {
          alert('$lt{'both'}$lt{'noup'}');           alert('$js_lt{'both'}$js_lt{'noup'}');
          checker = 0;           checker = 0;
      }       }
  }   }
Line 141  function process(calling,numauto,nummanu Line 142  function process(calling,numauto,nummanu
      }       }
      if (totalnote > 0) {       if (totalnote > 0) {
  if (formName.notify[1].checked == true) {   if (formName.notify[1].checked == true) {
      if (confirm('$lt{'nnot'}$lt{'eras'}')) {       if (confirm('$js_lt{'nnot'}$js_lt{'eras'}')) {
  checker = 1;   checker = 1;
      } else {       } else {
  checker = 0;   checker = 0;
Line 149  function process(calling,numauto,nummanu Line 150  function process(calling,numauto,nummanu
  }   }
      } else {       } else {
  if (formName.notify[0].checked == true) {   if (formName.notify[0].checked == true) {
      alert('$lt{'ynot'}');       alert('$js_lt{'ynot'}');
      checker = 0;       checker = 0;
  }   }
      }       }
Line 177  function process(calling,numauto,nummanu Line 178  function process(calling,numauto,nummanu
         document.forms.studentform.state.value = "process";          document.forms.studentform.state.value = "process";
      }       }
      if (totcheck == 0) {       if (totcheck == 0) {
         alert('$lt{'atle'}')          alert('$js_lt{'atle'}')
         checker = 0;          checker = 0;
      }       }
  }    } 

Removed from v.1.82  
changed lines
  Added in v.1.83


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