version 1.56, 2008/06/04 21:33:54
|
version 1.65, 2009/09/05 17:20:58
|
Line 49 sub choose_header {
|
Line 49 sub choose_header {
|
my ($action) = @_; |
my ($action) = @_; |
my $notify_check = '/^note_[0-9]+$/'; |
my $notify_check = '/^note_[0-9]+$/'; |
my $scripttag = qq| |
my $scripttag = qq| |
<script language='javascript' type='text/javascript'> |
<script type=\"text/javascript\" language=\"JavaScript\"> |
<!-- |
<!-- |
function process(calling,numauto,nummanual,numlock,numunlock) { |
function process(calling,numauto,nummanual,numlock,numunlock) { |
var checker = 1 |
var checker = 1 |
Line 370 ENDONE
|
Line 370 ENDONE
|
ENDTWO |
ENDTWO |
if ($enrollvar{autoadds}) { |
if ($enrollvar{autoadds}) { |
$r->print(" |
$r->print(" |
<label><input type=\"radio\" name=\"autoadds\" value=\"1\" checked=\"true\" /> Enable </label> |
<label><input type=\"radio\" name=\"autoadds\" value=\"1\" checked=\"checked\" /> Enable </label> |
<label><input type=\"radio\" name=\"autoadds\" value=\"0\" /> Disable</label> |
<label><input type=\"radio\" name=\"autoadds\" value=\"0\" /> Disable</label> |
"); |
"); |
} else { |
} else { |
$r->print(" |
$r->print(" |
<label><input type=\"radio\" name=\"autoadds\" value=\"1\" /> Enable </label> |
<label><input type=\"radio\" name=\"autoadds\" value=\"1\" /> Enable </label> |
<label><input type=\"radio\" name=\"autoadds\" value=\"0\" checked=\"true\" /> Disable</label> |
<label><input type=\"radio\" name=\"autoadds\" value=\"0\" checked=\"checked\" /> Disable</label> |
"); |
"); |
} |
} |
$r->print(" |
$r->print(" |
Line 387 ENDTWO
|
Line 387 ENDTWO
|
Removals based on classlist changes: "); |
Removals based on classlist changes: "); |
if ($enrollvar{autodrops}) { |
if ($enrollvar{autodrops}) { |
$r->print(" |
$r->print(" |
<label><input type=\"radio\" name=\"autodrops\" value=\"1\" checked=\"true\" /> Enable </label> |
<label><input type=\"radio\" name=\"autodrops\" value=\"1\" checked=\"checked\" /> Enable </label> |
<label><input type=\"radio\" name=\"autodrops\" value=\"0\" /> Disable</label>"); |
<label><input type=\"radio\" name=\"autodrops\" value=\"0\" /> Disable</label>"); |
} else { |
} else { |
$r->print(" |
$r->print(" |
<label><input type=\"radio\" name=\"autodrops\" value=\"1\" /> Enable </label> |
<label><input type=\"radio\" name=\"autodrops\" value=\"1\" /> Enable </label> |
<label><input type=\"radio\" name=\"autodrops\" value=\"0\" checked=\"true\" /> Disable</label>"); |
<label><input type=\"radio\" name=\"autodrops\" value=\"0\" checked=\"checked\" /> Disable</label>"); |
} |
} |
$r->print(" |
$r->print(" |
</td> |
</td> |
Line 508 ENDTWO
|
Line 508 ENDTWO
|
} elsif ($action eq "notify") { |
} elsif ($action eq "notify") { |
my $notifycount = 0; |
my $notifycount = 0; |
my @notified = split(/,/,$enrollvar{notifylist}); |
my @notified = split(/,/,$enrollvar{notifylist}); |
my @domcoord; |
my (@domcoord,@showdom,@olddomcoord,@futuredomcoord); |
my @showdom; |
|
for (my $i=0; $i<@notified; $i++) { |
for (my $i=0; $i<@notified; $i++) { |
if ($notified[$i] !~ /:/) { |
if ($notified[$i] !~ /:/) { |
$notified[$i] =~ s/\@/:/; |
$notified[$i] =~ s/\@/:/; |
Line 522 ENDTWO
|
Line 521 ENDTWO
|
} else { |
} else { |
$noteset = "OFF"; |
$noteset = "OFF"; |
} |
} |
|
my $now = time; |
my %dompersonnel = &Apache::lonnet::get_domain_roles($dom,['dc']); |
my %dompersonnel = &Apache::lonnet::get_domain_roles($dom,['dc']); |
foreach my $server (keys(%dompersonnel)) { |
foreach my $server (keys(%dompersonnel)) { |
foreach my $user (sort(keys(%{$dompersonnel{$server}}))) { |
foreach my $user (sort(keys(%{$dompersonnel{$server}}))) { |
my ($trole,$uname,$udom,$runame,$rudom,$rsec) = split(/:/,$user); |
my ($trole,$uname,$udom,$runame,$rudom,$rsec) = split(/:/,$user); |
if (!grep(/^$uname:$udom$/,@domcoord)) { |
my ($end,$start) = split(':',$dompersonnel{$server}{$user}); |
push(@domcoord,$uname.':'.$udom); |
if (($end eq '') || ($end == 0) || ($end > $now)) { |
|
if ($start > $now) { |
|
if (!grep(/^\Q$uname\E:\Q$udom\E$/,@futuredomcoord)) { |
|
push(@futuredomcoord,$uname.':'.$udom); |
|
} |
|
} else { |
|
if (!grep(/^\Q$uname\E:\Q$udom\E$/,@domcoord)) { |
|
push(@domcoord,$uname.':'.$udom); |
|
} |
|
} |
|
} else { |
|
if (!grep(/^\Q$uname\E:\Q$udom\E$/,@olddomcoord)) { |
|
push(@olddomcoord,$uname.':'.$udom); |
|
} |
} |
} |
} |
} |
} |
} |
Line 547 ENDTWO
|
Line 560 ENDTWO
|
"); |
"); |
if ($notifycount) { |
if ($notifycount) { |
$r->print(" |
$r->print(" |
<label><input type=\"radio\" name=\"notify\" value=\"1\" checked=\"true\" /> Yes </label> |
<label><input type=\"radio\" name=\"notify\" value=\"1\" checked=\"checked\" /> Yes </label> |
<label><input type=\"radio\" name=\"notify\" value=\"0\" /> No</label> |
<label><input type=\"radio\" name=\"notify\" value=\"0\" /> No</label> |
"); |
"); |
} else { |
} else { |
$r->print(" |
$r->print(" |
<label><input type=\"radio\" name=\"notify\" value=\"1\" /> Yes </label> |
<label><input type=\"radio\" name=\"notify\" value=\"1\" /> Yes </label> |
<label><input type=\"radio\" name=\"notify\" value=\"0\" checked=\"true\" /> No</label> |
<label><input type=\"radio\" name=\"notify\" value=\"0\" checked=\"checked\" /> No</label> |
"); |
"); |
} |
} |
$r->print(" |
$r->print(" |
Line 565 ENDTWO
|
Line 578 ENDTWO
|
my %pname; |
my %pname; |
my %notifystate; |
my %notifystate; |
my %status; |
my %status; |
my $now = time; |
|
foreach my $person (sort(keys(%coursepersonnel))) { |
foreach my $person (sort(keys(%coursepersonnel))) { |
my $match = 0; |
my $match = 0; |
my ($role,$user,$usec) = ($person =~ /^([^:]+):([^:]+:[^:]+):([^:]*)/); |
my ($role,$user,$usec) = ($person =~ /^([^:]+):([^:]+:[^:]+):([^:]*)/); |
Line 601 ENDTWO
|
Line 613 ENDTWO
|
usnm => 'username:domain', |
usnm => 'username:domain', |
coac => 'Course Access', |
coac => 'Course Access', |
curn => 'Current notification status', |
curn => 'Current notification status', |
|
doms => 'Domain Coordinator status', |
notf => 'Notification?', |
notf => 'Notification?', |
ntac => 'Notification active', |
ntac => 'Notification active', |
ntin => 'Notification inactive', |
ntin => 'Notification inactive', |
Line 630 ENDTWO
|
Line 643 ENDTWO
|
if (grep(/^$viewer$/,@domcoord)) { |
if (grep(/^$viewer$/,@domcoord)) { |
$showalldc = 1; |
$showalldc = 1; |
} |
} |
foreach my $dc (@domcoord) { |
foreach my $dc (@domcoord,@futuredomcoord) { |
if (!grep(/^$dc$/,@ccs)) { |
if (!grep(/^$dc$/,@ccs)) { |
if (grep(/^$dc$/,@notified)) { |
if (grep(/^$dc$/,@notified)) { |
$notifystate{$dc} = 1; |
$notifystate{$dc} = 1; |
Line 645 ENDTWO
|
Line 658 ENDTWO
|
push(@showdom,$dc); |
push(@showdom,$dc); |
} |
} |
} |
} |
|
foreach my $olddc (@olddomcoord) { |
|
if (grep(/^$olddc$/,@notified)) { |
|
if (!grep(/^\Q$olddc\E$/,@ccs)) { |
|
$notifystate{$olddc} = 1; |
|
my ($dcname,$dcdom) = split(/:/,$olddc); |
|
$pname{$olddc} = &Apache::loncommon::plainname($dcname,$dcdom); |
|
push(@showdom,$olddc); |
|
} |
|
} |
|
} |
my $showdomnum = scalar(@showdom); |
my $showdomnum = scalar(@showdom); |
if ($showdomnum) { |
if ($showdomnum) { |
$r->print(" |
$r->print(" |
Line 662 ENDTWO
|
Line 685 ENDTWO
|
</tr> |
</tr> |
<tr> |
<tr> |
<td>"); |
<td>"); |
$r->print(¬ifier_tables('dc',\%lt,\@showdom,\%status,\%notifystate, |
$r->print(¬ifier_tables('dc',\%lt,\@showdom,\%status,\%notifystate,\%pname, |
\%pname,\$notifyshow)); |
\$notifyshow,\@olddomcoord,\@futuredomcoord)); |
$r->print(" |
$r->print(" |
</td> |
</td> |
</tr>"); |
</tr>"); |
Line 734 ENDTWO
|
Line 757 ENDTWO
|
my $colflag = $i%2; |
my $colflag = $i%2; |
$r->print(&Apache::loncommon::start_data_table_row()); |
$r->print(&Apache::loncommon::start_data_table_row()); |
$r->print(" |
$r->print(" |
<td><input type=\"checkbox\" name=\"cross_$i\" checked=\"true\" /></td> |
<td><input type=\"checkbox\" name=\"cross_$i\" checked=\"checked\" /></td> |
<td>$xl</td> |
<td>$xl</td> |
<td><input type =\"text\" size=\"10\" name=\"lcsec_$i\" value=\"$lc_sec\" /></td> |
<td><input type=\"text\" size=\"10\" name=\"lcsec_$i\" value=\"$lc_sec\" /></td> |
"); |
"); |
$r->print(&Apache::loncommon::end_data_table_row()); |
$r->print(&Apache::loncommon::end_data_table_row()); |
} |
} |
Line 825 ENDTWO
|
Line 848 ENDTWO
|
$r->print("Enrollment inactive"); |
$r->print("Enrollment inactive"); |
} |
} |
if ($shrflag) { |
if ($shrflag) { |
$r->print("</td><td><input type=\"text\" size=\"10\" name=\"loncapasec_$i\" value=\"$sec_id{$sections[$i]}\"></td><td><input type=\"checkbox\" name=\"sec_$i\" checked=\"true\" /></td>"); |
$r->print("</td><td><input type=\"text\" size=\"10\" name=\"loncapasec_$i\" value=\"$sec_id{$sections[$i]}\" /></td><td><input type=\"checkbox\" name=\"sec_$i\" checked=\"checked\" /></td>"); |
} else { |
} else { |
$r->print("</td><td><input type=\"text\" size=\"10\" name=\"loncapasec_$i\" value=\"\" /></td><td><input type=\"checkbox\" name=\"sec_$i\" /></td>"); |
$r->print("</td><td><input type=\"text\" size=\"10\" name=\"loncapasec_$i\" value=\"\" /></td><td><input type=\"checkbox\" name=\"sec_$i\" /></td>"); |
} |
} |
Line 874 ENDTWO
|
Line 897 ENDTWO
|
my $colflag = $j%2; |
my $colflag = $j%2; |
$r->print(&Apache::loncommon::start_data_table_row()); |
$r->print(&Apache::loncommon::start_data_table_row()); |
$r->print(" |
$r->print(" |
<td><input type=\"checkbox\" name=\"sec_$j\" checked=\"true\" /></td> |
<td><input type=\"checkbox\" name=\"sec_$j\" checked=\"checked\" /></td> |
<td>$currsections[$j]</td> |
<td>$currsections[$j]</td> |
<td><input type=\"text\" name=\"lcsec_$j\" size=\"10\" value=\"$sec_id{$currsections[$j]}\" /></td> |
<td><input type=\"text\" name=\"lcsec_$j\" size=\"10\" value=\"$sec_id{$currsections[$j]}\" /></td> |
"); |
"); |
Line 931 ENDTWO
|
Line 954 ENDTWO
|
"); |
"); |
if ($enrollvar{showphoto}) { |
if ($enrollvar{showphoto}) { |
$r->print(" |
$r->print(" |
<label><input type=\"radio\" name=\"showphotos\" value=\"1\" checked=\"true\" /> Yes </label> |
<label><input type=\"radio\" name=\"showphotos\" value=\"1\" checked=\"checked\" /> Yes </label> |
<label><input type=\"radio\" name=\"showphotos\" value=\"0\" /> No</label> |
<label><input type=\"radio\" name=\"showphotos\" value=\"0\" /> No</label> |
"); |
"); |
} else { |
} else { |
$r->print(" |
$r->print(" |
<label><input type=\"radio\" name=\"showphotos\" value=\"1\" /> Yes </label> |
<label><input type=\"radio\" name=\"showphotos\" value=\"1\" /> Yes </label> |
<label><input type=\"radio\" name=\"showphotos\" value=\"0\" checked=\"true\" /> No</label> |
<label><input type=\"radio\" name=\"showphotos\" value=\"0\" checked=\"checked\" /> No</label> |
"); |
"); |
} |
} |
$r->print(' |
$r->print(' |
Line 956 ENDTWO
|
Line 979 ENDTWO
|
$r->print(' |
$r->print(' |
<tr> |
<tr> |
<td>'. |
<td>'. |
&mt('Previously the owner of this course agreed to the conditions of use of digital student photos required by [_1].', $institution).'<br />'.&mt('As a result [_1]s can choose to automatically import student photos into this course.',&Apache::lonnet::plaintext('cc')).'<br /><nobr><label>'.&mt('[_1] owner acceptance of these conditions of use?','<b>Cancel</b>').' <input type="checkbox" name="cancel_agreement" value="1" /></label></nobr> |
&mt('Previously the owner of this course agreed to the conditions of use of digital student photos required by [_1].', $institution).'<br />'.&mt('As a result [_1]s can choose to automatically import student photos into this course.',&Apache::lonnet::plaintext('cc')).'<br /><span class="LC_nobreak"><label>'.&mt('[_1] owner acceptance of these conditions of use?','<b>Cancel</b>').' <input type="checkbox" name="cancel_agreement" value="1" /></label></span> |
</td> |
</td> |
</tr> |
</tr> |
'); |
'); |
Line 1088 Note: Any students previously added manu
|
Line 1111 Note: Any students previously added manu
|
if ($update) { |
if ($update) { |
$r->print('<br />'.$commentary.'<br /><br /> |
$r->print('<br />'.$commentary.'<br /><br /> |
<form name="photoupdate" method="post"> |
<form name="photoupdate" method="post"> |
<input type ="button" name="retrieve" value="'.&mt('Update photo repository').'" |
<input type="button" name="retrieve" value="'.&mt('Update photo repository').'" |
onclick="javascript:document.photoupdate.submit()" /> |
onclick="javascript:document.photoupdate.submit()" /> |
<input type ="hidden" name="action" value="'.$action.'" /> |
<input type="hidden" name="action" value="'.$action.'" /> |
<input type ="hidden" name="state" value="process" /> |
<input type="hidden" name="state" value="process" /> |
</form>'); |
</form>'); |
} else { |
} else { |
$r->print(&mt('Update of photos via the Automated Enrollment Manager is unavailable in this domain.') |
$r->print(&mt('Update of photos via the Automated Enrollment Manager is unavailable in this domain.') |
.'<br /><br /><input type="button" name=mainmenu" value="'.&mt('Go back').'" onclick="javascript:history.go(-1);" />'); |
.'<br /><br /><input type="button" name="mainmenu" value="'.&mt('Go back').'" onclick="javascript:history.go(-1);" />'); |
} |
} |
} else { |
} else { |
$r->print('Update of photos is unavailable, as import of student photos is currently disabled.<br />Enable this first via: <a href="/adm/populate?action=photos">'.$$tasktitleref{'photos'}.'</a>'); |
$r->print('Update of photos is unavailable, as import of student photos is currently disabled.<br />Enable this first via: <a href="/adm/populate?action=photos">'.$$tasktitleref{'photos'}.'</a>'); |
Line 1168 onclick="javascript:document.photoupdate
|
Line 1191 onclick="javascript:document.photoupdate
|
if ($autocount > 0) { |
if ($autocount > 0) { |
$cellcount ++; |
$cellcount ++; |
$r->print(<<END); |
$r->print(<<END); |
<td><fieldset><legend> <b>Change auto</b></legend><input type="button" value="check all" onclick="javascript:checkAll(document.studentform.chgauto)" /> |
<td><fieldset><legend>Change auto</legend><input type="button" value="check all" onclick="javascript:checkAll(document.studentform.chgauto)" /> |
<input type="button" value="uncheck all" onclick="javascript:uncheckAll(document.studentform.chgauto)" /></fieldset></td> |
<input type="button" value="uncheck all" onclick="javascript:uncheckAll(document.studentform.chgauto)" /></fieldset></td> |
END |
END |
} |
} |
if ($manualcount > 0) { |
if ($manualcount > 0) { |
$cellcount ++; |
$cellcount ++; |
$r->print(<<END); |
$r->print(<<END); |
<td><fieldset><legend> <b>Change manual</b></legend><input type="button" value="check all" onclick="javascript:checkAll(document.studentform.chgmanual)" /> |
<td><fieldset><legend>Change manual</legend><input type="button" value="check all" onclick="javascript:checkAll(document.studentform.chgmanual)" /> |
<input type="button" value="uncheck all" onclick="javascript:uncheckAll(document.studentform.chgmanual)" /></fieldset></td> |
<input type="button" value="uncheck all" onclick="javascript:uncheckAll(document.studentform.chgmanual)" /></fieldset></td> |
END |
END |
} |
} |
Line 1185 END
|
Line 1208 END
|
} |
} |
$cellcount ++; |
$cellcount ++; |
$r->print(<<END); |
$r->print(<<END); |
<td><fieldset><legend> <b>Lock manual</b></legend><input type="button" value="check all" onclick="javascript:checkAll(document.studentform.lockchg)" /> |
<td><fieldset><legend>Lock manual</legend><input type="button" value="check all" onclick="javascript:checkAll(document.studentform.lockchg)" /> |
<input type="button" value="uncheck all" onclick="javascript:uncheckAll(document.studentform.lockchg)" /></fieldset></td> |
<input type="button" value="uncheck all" onclick="javascript:uncheckAll(document.studentform.lockchg)" /></fieldset></td> |
END |
END |
} |
} |
Line 1195 END
|
Line 1218 END
|
} |
} |
$cellcount ++; |
$cellcount ++; |
$r->print(<<END); |
$r->print(<<END); |
<td><fieldset><legend> <b>Unlock manual</b></legend><input type="button" value="check all" onclick="javascript:checkAll(document.studentform.unlockchg)" /> |
<td><fieldset><legend>Unlock manual</legend><input type="button" value="check all" onclick="javascript:checkAll(document.studentform.unlockchg)" /> |
<input type="button" value="uncheck all" onclick="javascript:uncheckAll(document.studentform.unlockchg)" /></fieldset></td> |
<input type="button" value="uncheck all" onclick="javascript:uncheckAll(document.studentform.unlockchg)" /></fieldset></td> |
END |
END |
} |
} |
Line 1230 END
|
Line 1253 END
|
} |
} |
|
|
sub notifier_tables { |
sub notifier_tables { |
my ($role,$lt,$users,$status,$notifystate,$pname,$notifyshow) = @_; |
my ($role,$lt,$users,$status,$notifystate,$pname,$notifyshow,$olddomcoord, |
|
$futuredomcoord) = @_; |
my $output = &Apache::loncommon::start_data_table(); |
my $output = &Apache::loncommon::start_data_table(); |
$output .= &Apache::loncommon::start_data_table_header_row(); |
$output .= &Apache::loncommon::start_data_table_header_row(); |
$output .= "<th>$$lt{name}</th> |
$output .= "<th>$$lt{name}</th> |
<th>$$lt{usnm}</th>"; |
<th>$$lt{usnm}</th>"; |
if ($role eq 'cc') { |
if ($role eq 'dc') { |
|
$output .= "<th>$$lt{doms}</th>"; |
|
} elsif ($role eq 'cc') { |
$output .= "<th>$$lt{coac}</th>"; |
$output .= "<th>$$lt{coac}</th>"; |
} |
} |
$output .= "<th>$$lt{curn}</th> |
$output .= "<th>$$lt{curn}</th> |
Line 1246 sub notifier_tables {
|
Line 1272 sub notifier_tables {
|
$output .= '<td>'.$$pname{$$users[$i]}.'</td>'. |
$output .= '<td>'.$$pname{$$users[$i]}.'</td>'. |
'<td><input type="hidden" name="notifyname_'.$$notifyshow. |
'<td><input type="hidden" name="notifyname_'.$$notifyshow. |
'" value="'.$$users[$i].'" />'.$$users[$i].'</td>'; |
'" value="'.$$users[$i].'" />'.$$users[$i].'</td>'; |
if ($role eq 'cc') { |
if ($role eq 'dc') { |
|
$output .= '<td>'; |
|
if ((ref($olddomcoord) eq 'ARRAY') && (ref($futuredomcoord) eq 'ARRAY')) { |
|
if (grep(/^\Q$users->[$i]\E$/,@{$olddomcoord})) { |
|
$output .= &mt('expired'); |
|
} elsif (grep(/^\Q$users->[$i]\E$/,@{$futuredomcoord})) { |
|
$output .= &mt('future'); |
|
} else { |
|
$output .= &mt('active'); |
|
} |
|
} |
|
$output .= '</td>'; |
|
} elsif ($role eq 'cc') { |
$output .= '<td>'.$$status{$$users[$i]}.'</td>'; |
$output .= '<td>'.$$status{$$users[$i]}.'</td>'; |
} |
} |
$output .= '<td>'; |
$output .= '<td>'; |
Line 1291 sub print_accessdate_table {
|
Line 1329 sub print_accessdate_table {
|
'fnew' => 'for new students added when you update the class roster', |
'fnew' => 'for new students added when you update the class roster', |
'ifad' => 'If automated adds are enabled, then when students are added their student roles will become active on the date set here for first access, and their roles will become inactive on the date set here for last access. These default access dates will be overridden for specific students if the institutional classlist data supplied to the automatic enrollment process includes entries for the startdate and enddate fields for those students.', |
'ifad' => 'If automated adds are enabled, then when students are added their student roles will become active on the date set here for first access, and their roles will become inactive on the date set here for last access. These default access dates will be overridden for specific students if the institutional classlist data supplied to the automatic enrollment process includes entries for the startdate and enddate fields for those students.', |
'ncds' => 'changing default start and end access dates will affect <b>future enrollments</b> and also <b>currently inactive</b> students (i.e., those for whom access will begin in the future).', |
'ncds' => 'changing default start and end access dates will affect <b>future enrollments</b> and also <b>currently inactive</b> students (i.e., those for whom access will begin in the future).', |
'tcha' => 'To change access dates for <b>currently active</b> students, use User Management -> "Display Class Lists and Manage Multiple Users" to display currently active students, then use the dropdown menu for "Action to take for selected users:" to choose "Change starting/ending dates", select the students to change, and click "Proceed".', |
'tcha' => 'To change access dates for <b>currently active</b> students, use User Management -> "Manage Course Users" to display currently active students, then use the dropdown menu for "Action to take for selected users:" to choose "Change starting/ending dates", select the students to change, and click "Proceed".', |
); |
); |
my $dateshow; |
my $dateshow; |
if ( ($oldendshow eq '') && ($oldstartshow eq '') ) { |
if ( ($oldendshow eq '') && ($oldstartshow eq '') ) { |
Line 1623 start and end access dates for this cour
|
Line 1661 start and end access dates for this cour
|
} else { |
} else { |
$response .= "The last access date for students being added via automated enrollment has been changed to $showend.<br/>"; |
$response .= "The last access date for students being added via automated enrollment has been changed to $showend.<br/>"; |
} |
} |
$response .= '<br />'.&mt('Any change in access dates will only apply to students who are not currently active, i.e., those who currently have access start dates in the future, and to those added by future automated enrollment.').'<br /><br />'.&mt('To change access dates for any currently active students, use User Management -> "Display Class Lists and Manage Multiple Users" to display currently active students, then use the dropdown menu for "Action to take for selected users:" to choose "Change starting/ending dates", select the students to change, and click "Proceed".').'<br />'; |
$response .= '<br />'.&mt('Any change in access dates will only apply to students who are not currently active, i.e., those who currently have access start dates in the future, and to those added by future automated enrollment.').'<br /><br />'.&mt('To change access dates for any currently active students, use User Management -> "Manage Users" to display currently active students, then use the dropdown menu for "Action to take for selected users:" to choose "Change starting/ending dates", select the students to change, and click "Proceed".').'<br />'; |
|
|
# Generate message in case where old first access date was later than today, but new first access date is now today or earlier. |
# Generate message in case where old first access date was later than today, but new first access date is now today or earlier. |
|
|
Line 2380 sub print_photo_agreement {
|
Line 2418 sub print_photo_agreement {
|
my $institution = &Apache::lonnet::domain($dom,'description'); |
my $institution = &Apache::lonnet::domain($dom,'description'); |
if (&user_is_courseowner($courseowner)) { |
if (&user_is_courseowner($courseowner)) { |
$response = ' |
$response = ' |
<script type="text/javascript"> |
<script type="text/javascript" language="JavaScript"> |
function agreement_result(caller) { |
function agreement_result(caller) { |
document.permission.photopermission.value = caller; |
document.permission.photopermission.value = caller; |
if (caller == 0) { |
if (caller == 0) { |
Line 2413 function agreement_result(caller) {
|
Line 2451 function agreement_result(caller) {
|
</td> |
</td> |
</tr> |
</tr> |
</table> |
</table> |
<input type ="hidden" name="action" value="'.$action.'" /> |
<input type="hidden" name="action" value="'.$action.'" /> |
<input type ="hidden" name="state" value="process" /> |
<input type="hidden" name="state" value="process" /> |
<input type ="hidden" name="showphotos" value="1" /> |
<input type="hidden" name="showphotos" value="1" /> |
<input type= "hidden" name="photopermission" value="" /> |
<input type="hidden" name="photopermission" value="" /> |
</form> |
</form> |
'; |
'; |
} else { |
} else { |
Line 2471 sub print_photos_response {
|
Line 2509 sub print_photos_response {
|
if ($update) { |
if ($update) { |
$response .= '<br />'.$commentary.'<br /><br /> |
$response .= '<br />'.$commentary.'<br /><br /> |
<form name="photoupdate" method="post"> |
<form name="photoupdate" method="post"> |
<input type ="button" name="retrieve" value="'.&mt('Update photo repository').'" |
<input type="button" name="retrieve" value="'.&mt('Update photo repository').'" |
onclick="javascript:document.photoupdate.submit()" /> |
onclick="javascript:document.photoupdate.submit()" /> |
<input type ="hidden" name="action" value="'.$action.'" /> |
<input type="hidden" name="action" value="'.$action.'" /> |
<input type ="hidden" name="state" value="photoupdate" /> |
<input type="hidden" name="state" value="photoupdate" /> |
</form>'; |
</form>'; |
} |
} |
} |
} |
Line 2526 sub print_photoupdate_response {
|
Line 2564 sub print_photoupdate_response {
|
} |
} |
if ($outcome eq 'ok') { |
if ($outcome eq 'ok') { |
if (keys(%changes) > 0) { |
if (keys(%changes) > 0) { |
$response = &mt('Update of photos for registered students resulted in the following ').': <br /><script type="text/javascript"> |
$response = &mt('Update of photos for registered students resulted in the following ').': <br />' |
|
.'<script type="text/javascript" language="JavaScript"> |
function photowindow(photolink) { |
function photowindow(photolink) { |
var title = "Photo_Viewer"; |
var title = "Photo_Viewer"; |
var options = "scrollbars=1,resizable=1,menubar=0"; |
var options = "scrollbars=1,resizable=1,menubar=0"; |
Line 2935 sub get_dates_from_form {
|
Line 2974 sub get_dates_from_form {
|
sub date_setting_table { |
sub date_setting_table { |
my ($starttime,$endtime,$action) = @_; |
my ($starttime,$endtime,$action) = @_; |
my ($startform,$endform) = &setup_date_selectors($starttime,$endtime,$action); |
my ($startform,$endform) = &setup_date_selectors($starttime,$endtime,$action); |
my $perpetual = '<nobr><label><input type="checkbox" name="no_end_date"'; |
my $perpetual = '<span class="LC_nobreak"><label><input type="checkbox" name="no_end_date"'; |
if (($action eq 'setdates' && defined($endtime) && $endtime == 0) || (($action eq 'setaccess' || $action eq 'updatenow') && ($endtime eq '' || $endtime == 0)) ) { |
if (($action eq 'setdates' && defined($endtime) && $endtime == 0) || (($action eq 'setaccess' || $action eq 'updatenow') && ($endtime eq '' || $endtime == 0)) ) { |
$perpetual .= ' checked'; |
$perpetual .= ' checked'; |
} |
} |
$perpetual.= ' />'.' no ending date</label></nobr>'; |
$perpetual.= ' />'.' no ending date</label></span>'; |
my $start_table = ''; |
my $start_table = ''; |
$start_table .= "<table>\n"; |
$start_table .= "<table>\n"; |
$start_table .= '<tr><td align="right">Starting Date</td>'. |
$start_table .= '<tr><td align="right">Starting Date</td>'. |