version 1.141, 2010/01/13 18:23:01
|
version 1.148, 2010/02/12 15:21:37
|
Line 222 function folder_choice(targetform,caller
|
Line 222 function folder_choice(targetform,caller
|
|
|
$output .= ' |
$output .= ' |
<form method="post" action="/adm/email" name="folderlist"> |
<form method="post" action="/adm/email" name="folderlist"> |
<table border="0" cellspacing="2" cellpadding="2"> |
<table border="0" cellspacing="2" cellpadding="8"> |
<tr> |
|
<td align="left"> |
|
<table border="0" cellspacing="2" cellpadding="2"> |
|
<tr> |
<tr> |
<td align="center"><b>'.$lt{'fold'}.'</b><br />'."\n". |
<td><b>'.$lt{'fold'}.'</b><br />'."\n". |
&Apache::loncommon::select_form($folder,'folder',%formhash).' |
&Apache::loncommon::select_form($folder,'folder',%formhash).' |
</td> |
</td> |
<td align="center"><b>'.$lt{'show'}.'</b><br />'."\n". |
<td><b>'.$lt{'show'}.'</b><br />'."\n". |
&Apache::loncommon::select_form($env{'form.interdis'},'interdis', |
&Apache::loncommon::select_form($env{'form.interdis'},'interdis', |
%show).' |
%show).' |
</td> |
</td> |
<td align="center"><b>'.$lt{'status'}.'</b><br />'."\n". |
<td><b>'.$lt{'status'}.'</b><br />'."\n". |
&Apache::loncommon::select_form($msgstatus,'msgstatus',%statushash).' |
&Apache::loncommon::select_form($msgstatus,'msgstatus',%statushash).' |
</td> |
</td> |
<td align="center"><b>'.$lt{'actn'}.'</b><br />'. |
<td><b>'.$lt{'actn'}.'</b><br />'."\n".' |
&Apache::loncommon::select_form('view','folderaction',%actions).' |
<span class="LC_nobreak">'. |
</td><td><br />'. |
&Apache::loncommon::select_form('view','folderaction',%actions). |
'<input type="button" value="'.$lt{'go'}.'" onclick="javascript:folder_choice(this.form,'."'change'".');" /> |
' <input type="button" value="'.$lt{'go'}. |
|
'" onclick="javascript:folder_choice(this.form,'."'change'".');" /> |
|
</span> |
|
</td> |
|
<td><b>'.&mt('New Folder').'</b><br />'."\n".' |
|
<span class="LC_nobreak"> |
|
<input type="text" size="15" name="newfolder" value="" /> |
|
<input type="button" value="'.$lt{'go'}. |
|
'" onclick="javascript:folder_choice(this.form,'."'new'".');" /> |
|
</span> |
</td> |
</td> |
</tr> |
</tr> |
</table> |
</table> |
</td><td> </td><td> </td><td> </td><td> </td> |
'."\n". |
<td align="right"> |
|
<table><tr><td><br /> |
|
<input type="button" value="'.&mt('New Folder'). |
|
'" onclick="javascript:folder_choice(this.form,'."'new'".');" /></td>'. |
|
'<td align="center"><b>'.&mt('Name').'</b><br />'. |
|
'<input type="text" size="15" name="newfolder" value="" /> |
|
</td></tr></table> |
|
</td> |
|
</tr> |
|
</table>'."\n". |
|
'<input type="hidden" name="sortedby" value="'.$env{'form.sortedby'}.'" />'. |
'<input type="hidden" name="sortedby" value="'.$env{'form.sortedby'}.'" />'. |
'<input type="hidden" name="renamed" value="" />'. |
'<input type="hidden" name="renamed" value="" />'. |
($folder=~/^critical/?'</form>':''); |
($folder=~/^critical/?'</form>':''); |
Line 308 sub scrollbuttons {
|
Line 304 sub scrollbuttons {
|
'<input type="submit" name="lastview" value=">|" />'; |
'<input type="submit" name="lastview" value=">|" />'; |
} |
} |
$output .= |
$output .= |
'<br />' |
'<p>' |
.'<b>'.&mt($status.' messages:').'</b> ' |
.'<b>'.&mt($status.' messages:').'</b> ' |
.&mt('showing messages [_1] through [_2] of [_3].', |
.&mt('showing messages [_1] through [_2] of [_3].', |
$first,$finish,$total) |
$first,$finish,$total) |
|
.'</p>' |
.'</form>'; |
.'</form>'; |
|
|
return $output; |
return $output; |
Line 381 sub deletefolder {
|
Line 378 sub deletefolder {
|
my ($folder)=@_; |
my ($folder)=@_; |
my %permfolders = &get_permanent_folders(); |
my %permfolders = &get_permanent_folders(); |
if (defined($permfolders{$folder})) { |
if (defined($permfolders{$folder})) { |
return &mt('The folder "[_1]" may not be deleted',$folder); |
return &mt('The folder "[_1]" may not be deleted.',$folder); |
} |
} |
my %userfolders = &Apache::lonmsg::get_user_folders(); |
my %userfolders = &Apache::lonmsg::get_user_folders(); |
if (!defined($userfolders{$folder})) { |
if (!defined($userfolders{$folder})) { |
Line 1030 sub disfolder {
|
Line 1027 sub disfolder {
|
my ($startblock,$endblock) = &Apache::loncommon::blockcheck(\%setters,'com'); |
my ($startblock,$endblock) = &Apache::loncommon::blockcheck(\%setters,'com'); |
my %lt = &Apache::lonlocal::texthash( |
my %lt = &Apache::lonlocal::texthash( |
sede => 'Select a destination folder to which the messages will be moved.', |
sede => 'Select a destination folder to which the messages will be moved.', |
nome => 'No messages have been selected to apply ths action to.', |
nome => 'No messages have been selected to apply this action to.', |
chec => 'Check the checkbox for at least one message.', |
chec => 'Check the checkbox for at least one message.', |
); |
); |
my $jscript = &Apache::loncommon::check_uncheck_jscript(); |
my $jscript = &Apache::loncommon::check_uncheck_jscript(); |
Line 1206 ENDDISHEADER
|
Line 1203 ENDDISHEADER
|
} |
} |
} |
} |
$r->print("</table>\n"); |
$r->print("</table>\n"); |
$r->print('<table border="0" cellspacing="2" cellpadding="2"> |
$r->print('<table border="0" cellspacing="2" cellpadding="8"> |
<tr> |
<tr> |
<td>'. |
<td> |
'<input type="button" onclick="javascript:checkAll(document.disall.delmark)" value="'.&mt('Check All').'" /><br />'."\n". |
<fieldset> |
'<input type="button" onclick="javascript:uncheckAll(document.disall.delmark)" value="'.&mt('Uncheck All').'" />'."\n". |
<legend>'.&mt('Select').'</legend> |
'<input type="hidden" name="sortedby" value="'.$env{'form.sortedby'}.'" /></td><td> </td>'."\n". |
<span class="LC_nobreak"> |
'<td align="center"><b>'.&mt('Action').'</b><br />'."\n". |
<input type="button" onclick="javascript:checkAll(document.disall.delmark)" value="'.&mt('Check All').'" />'."\n". |
|
' <input type="button" onclick="javascript:uncheckAll(document.disall.delmark)" value="'.&mt('Uncheck All').'" />'."\n". |
|
'<input type="hidden" name="sortedby" value="'.$env{'form.sortedby'}.'" /> |
|
</span> |
|
</fieldset> |
|
</td>'."\n". |
|
'<td><b>'.&mt('Action').'</b><br />'."\n". |
' <select name="checkedaction">'."\n"); |
' <select name="checkedaction">'."\n"); |
|
|
if ($folder ne 'trash') { |
if ($folder ne 'trash') { |
Line 1234 ENDDISHEADER
|
Line 1237 ENDDISHEADER
|
$r->print("\n".'</select></td>'."\n"); |
$r->print("\n".'</select></td>'."\n"); |
|
|
if (keys(%gotfolders) > 0) { |
if (keys(%gotfolders) > 0) { |
$r->print('<td align="center"><b>'.&mt('Destination folder').'<b><br />'); |
$r->print('<td><b>'.&mt('Destination folder').'<b><br />'); |
my %userfolders; |
my %userfolders; |
foreach my $key (keys(%gotfolders)) { |
foreach my $key (keys(%gotfolders)) { |
$userfolders{$key} = $key; |
$userfolders{$key} = $key; |
Line 1243 ENDDISHEADER
|
Line 1246 ENDDISHEADER
|
$r->print(&Apache::loncommon::select_form('','movetofolder',%userfolders). |
$r->print(&Apache::loncommon::select_form('','movetofolder',%userfolders). |
'</td>'); |
'</td>'); |
} |
} |
$r->print('<td> </td><td> '. |
$r->print('<td>'. |
'<input type="button" name="go" value="'.&mt('Go'). |
'<input type="button" name="go" value="'.&mt('Go'). |
'" onclick="javascript:validate_checkedaction()"/></td>'."\n". |
'" onclick="javascript:validate_checkedaction()"/></td>'."\n". |
'</tr></table>'); |
'</tr></table>'); |
Line 1311 sub compout {
|
Line 1314 sub compout {
|
&printheader($r,'/adm/email?compose=multiforward', |
&printheader($r,'/adm/email?compose=multiforward', |
'Forwarding Multiple Messages'); |
'Forwarding Multiple Messages'); |
if ($multiforward > 1) { |
if ($multiforward > 1) { |
$r->print(&mt('Each of the [quant,_1,message] you checked' |
$r->print(&mt('Each of the[_1] [quant,_2,message] [_3]you checked' |
.' will be forwarded to the recipient(s) you select below.' |
.' will be forwarded to the recipient(s) you select below.' |
,'<b>'.$multiforward.'</b>') |
,'<b>',$multiforward,'</b>') |
.'<br />'); |
.'<br />'); |
} else { |
} else { |
$r->print(&mt('The message you checked will be forwarded to the recipient(s) you select below.').'<br />'); |
$r->print(&mt('The message you checked will be forwarded to the recipient(s) you select below.').'<br />'); |
Line 1844 sub retrieve_instructor_comments {
|
Line 1847 sub retrieve_instructor_comments {
|
|
|
sub disfacetoface { |
sub disfacetoface { |
my ($r,$user,$domain,$target)=@_; |
my ($r,$user,$domain,$target)=@_; |
if ($target eq '') { |
if ($target eq '') { |
my $target=$env{'form.grade_target'}; |
$target=$env{'form.grade_target'}; |
} |
} |
unless ($env{'request.course.id'}) { return; } |
unless ($env{'request.course.id'}) { return; } |
if (!&Apache::lonnet::allowed('dff',$env{'request.course.id'}) |
if (!&Apache::lonnet::allowed('dff',$env{'request.course.id'}) |
&& ! &Apache::lonnet::allowed('dff',$env{'request.course.id'}. |
&& ! &Apache::lonnet::allowed('dff',$env{'request.course.id'}. |
Line 2229 sub display_blocker_status {
|
Line 2232 sub display_blocker_status {
|
<th>$ltext->{'setb'}</th> |
<th>$ltext->{'setb'}</th> |
<th>$ltext->{'even'}</th> |
<th>$ltext->{'even'}</th> |
<th>$ltext->{'blck'}</th> |
<th>$ltext->{'blck'}</th> |
<th>$ltext->{'actn'}?</th> |
<th>$ltext->{'actn'}</th> |
</tr> |
</tr> |
END |
END |
foreach my $record (sort(keys(%{$records}))) { |
foreach my $record (sort(keys(%{$records}))) { |
Line 2249 END
|
Line 2252 END
|
$setuname,$setudom); |
$setuname,$setudom); |
$r->print(&Apache::loncommon::start_data_table_row()); |
$r->print(&Apache::loncommon::start_data_table_row()); |
$r->print(<<"END"); |
$r->print(<<"END"); |
<td>$ltext->{'star'}: $startform<br/>$ltext->{'endd'}: $endform</td> |
<td>$ltext->{'star'}: $startform<br />$ltext->{'endd'}: $endform</td> |
<td>$settername</td> |
<td>$settername</td> |
<td><input type="text" name="title_$parmcount" size="15" value="$title" /><input type="hidden" name="key_$parmcount" value="$record" /></td> |
<td><input type="text" name="title_$parmcount" size="15" value="$title" /><input type="hidden" name="key_$parmcount" value="$record" /></td> |
<td> |
<td> |
Line 2259 END
|
Line 2262 END
|
if ($blocks->{$block} eq 'on') { |
if ($blocks->{$block} eq 'on') { |
$blockstatus = 'checked="checked"'; |
$blockstatus = 'checked="checked"'; |
} |
} |
$r->print('<label><input type="checkbox" name="'.$block.'_'.$parmcount.'" '.$blockstatus.' value="1" />'.$types->{$block}.'</label><br />'); |
$r->print('<span class="LC_nobreak"><label><input type="checkbox" name="'.$block.'_'.$parmcount.'" '.$blockstatus.' value="1" />'.$types->{$block}.'</label></span><br />'); |
} |
} |
$r->print(<<"END"); |
$r->print(<<"END"); |
</td> |
</td> |
<td><label>$lt{'modi'}? <input type="checkbox" name="modify_$parmcount" /></label><br /><label>$lt{'canc'}? <input type="checkbox" name="cancel_$parmcount" /></label> |
<td><span class="LC_nobreak"><label> |
|
<input type="checkbox" name="modify_$parmcount" />$lt{'modi'} |
|
</label></span><br /><span class="LC_nobreak"> |
|
<label> |
|
<input type="checkbox" name="cancel_$parmcount" />$lt{'canc'} |
|
</label></span> |
END |
END |
$r->print(&Apache::loncommon::end_data_table_row()); |
$r->print(&Apache::loncommon::end_data_table_row()); |
$parmcount++; |
$parmcount++; |
Line 2300 END
|
Line 2308 END
|
<th>$ltext->{'dura'}</th> |
<th>$ltext->{'dura'}</th> |
<th>$ltext->{'even'} $lt{'exam'}</th> |
<th>$ltext->{'even'} $lt{'exam'}</th> |
<th>$ltext->{'blck'}</th> |
<th>$ltext->{'blck'}</th> |
<th>$ltext->{'actn'}?</th> |
<th>$ltext->{'actn'}</th> |
</tr> |
</tr> |
END |
END |
$r->print(&Apache::loncommon::start_data_table_row()); |
$r->print(&Apache::loncommon::start_data_table_row()); |
Line 2310 END
|
Line 2318 END
|
<td> |
<td> |
END |
END |
foreach my $block (@{$typeorder}) { |
foreach my $block (@{$typeorder}) { |
$r->print('<label><input type="checkbox" name="'.$block.'_'.$parmcount.'" value="1" />'.$types->{$block}.'</label><br />'); |
$r->print('<span class="LC_nobreak"><label><input type="checkbox" name="'.$block.'_'.$parmcount.'" value="1" />'.$types->{$block}.'</label></span><br />'); |
} |
} |
$r->print(<<"END"); |
$r->print(<<"END"); |
</td> |
</td> |
<td><label>$lt{'addb'}? <input type="checkbox" name="add_$parmcount" value="1" /></label></td> |
<td><span class="LC_nobreak"><label> |
|
<input type="checkbox" name="add_$parmcount" value="1" />$lt{'addb'} |
|
</label></span></td> |
END |
END |
$r->print(&Apache::loncommon::end_data_table_row()); |
$r->print(&Apache::loncommon::end_data_table_row()); |
$r->print(&Apache::loncommon::end_data_table()); |
$r->print(&Apache::loncommon::end_data_table()); |
Line 3265 sub sendoffmail {
|
Line 3275 sub sendoffmail {
|
'','','','',$recipid); |
'','','','',$recipid); |
} |
} |
} |
} |
if (!$env{'form.multiforward'}) { |
if (!$env{'form.multiforward'}) { |
if ($sendstatus=~/^(\s*(?:ok|con_delayed)\s*)*$/) { |
if ($sendstatus=~/^(\s*(?:ok|con_delayed)\s*)*$/) { |
$r->print('<br /><span class="LC_success">'.&mt('Completed.'). |
my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Completed.')); |
'</span>'); |
$message = &Apache::loncommon::confirmwrapper($message); |
|
$r->print($message); |
if ($env{'form.displayedcrit'}) { |
if ($env{'form.displayedcrit'}) { |
&discrit($r); |
&discrit($r); |
} |
} |
Line 3278 sub sendoffmail {
|
Line 3289 sub sendoffmail {
|
&Apache::loncommunicate::menu($r); |
&Apache::loncommunicate::menu($r); |
} |
} |
} else { |
} else { |
$r->print('<p>'.&Apache::lonhtmlcommon::confirm_success(&mt('Could not deliver message'),1).'<br /> '. |
my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Could not deliver message'),1); |
&mt('Please use the browser "Back" button and correct the recipient addresses ([_1]).',$sendstatus).'</p>'); |
$message .= '<br />'.&mt('Please use the browser "Back" button and correct the recipient addresses ([_1]).',$sendstatus); |
|
$message = &Apache::loncommon::confirmwrapper($message); |
|
$r->print($message); |
} |
} |
} |
} |
} |
} |
Line 3398 sub handler {
|
Line 3411 sub handler {
|
my ($result,$msg) = |
my ($result,$msg) = |
&statuschange($env{'form.markdel'},'deleted',$folder); |
&statuschange($env{'form.markdel'},'deleted',$folder); |
if (!$result) { |
if (!$result) { |
$r->print('<p class="LC_error">'. |
my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Failed to delete the message.'),1); |
&mt('Failed to delete the message.').'</p>'. |
$message .= '<p class="LC_error" style="font-size: inherit;">'.$msg.'</p>'; |
'<p class="LC_error">'.$msg."</p>\n"); |
$message = &Apache::loncommon::confirmwrapper($message); |
|
$r->print($message); |
} |
} |
&Apache::loncommunicate::menu($r); |
&Apache::loncommunicate::menu($r); |
&disall($r,($folder?$folder:$dismode),$msgstatus); |
&disall($r,($folder?$folder:$dismode),$msgstatus); |
Line 3422 sub handler {
|
Line 3436 sub handler {
|
$total ++; |
$total ++; |
} |
} |
&printheader($r,'','Marked Messages Read'); |
&printheader($r,'','Marked Messages Read'); |
$r->print(&mt('Marked [quant,_1,message] read',$total).'<p>'); |
my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Marked [quant,_1,message] read',$total)); |
|
$message = &Apache::loncommon::confirmwrapper($message); |
|
$r->print($message); |
|
# $r->print('<p>'); |
&Apache::loncommunicate::menu($r); |
&Apache::loncommunicate::menu($r); |
&disall($r,($folder?$folder:$dismode),$msgstatus); |
&disall($r,($folder?$folder:$dismode),$msgstatus); |
} elsif ($env{'form.markedaction'} eq 'markedunread') { |
} elsif ($env{'form.markedaction'} eq 'markedunread') { |
Line 3433 sub handler {
|
Line 3450 sub handler {
|
$total ++; |
$total ++; |
} |
} |
&printheader($r,'','Marked Messages Unread'); |
&printheader($r,'','Marked Messages Unread'); |
$r->print(&mt('Marked [quant,_1,message] unread',$total).'<p>'); |
my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Marked [quant,_1,message] unread',$total)); |
|
$message = &Apache::loncommon::confirmwrapper($message); |
|
$r->print($message); |
|
# $r->print('<p>'); |
&Apache::loncommunicate::menu($r); |
&Apache::loncommunicate::menu($r); |
&disall($r,($folder?$folder:$dismode),$msgstatus); |
&disall($r,($folder?$folder:$dismode),$msgstatus); |
} elsif ($env{'form.markedaction'} eq 'markedmove') { |
} elsif ($env{'form.markedaction'} eq 'markedmove') { |
Line 3442 sub handler {
|
Line 3462 sub handler {
|
&printheader($r,'','Moved Messages'); |
&printheader($r,'','Moved Messages'); |
if (!defined($gotfolders{$destfolder})) { |
if (!defined($gotfolders{$destfolder})) { |
$r->print(&mt('Destination folder [_1] is not a valid folder', |
$r->print(&mt('Destination folder [_1] is not a valid folder', |
$destfolder)); |
'<span class="LC_filename">'.$destfolder.'</span>')); |
} else { |
} else { |
my ($total,$failed,@failed_msg)=(0,0); |
my ($total,$failed,@failed_msg)=(0,0); |
my @to_move = &Apache::loncommon::get_env_multiple('form.delmark'); |
my @to_move = &Apache::loncommon::get_env_multiple('form.delmark'); |
Line 3456 sub handler {
|
Line 3476 sub handler {
|
push(@failed_msg,$msg); |
push(@failed_msg,$msg); |
} |
} |
} |
} |
if ($failed) { |
my $message = ''; |
$r->print('<p class="LC_error">' |
if ($failed) { |
.&mt('Failed to move [quant,_1,message]',$failed) |
$message .= &Apache::lonhtmlcommon::confirm_success(&mt('Failed to move [quant,_1,message]',$failed),1); |
.'</p>'); |
$message .= '<p class="LC_error" style="font-size: inherit;">'. |
$r->print('<p class="LC_error">'. |
join("</p>\n<p class=\"LC_error\" style=\"font-size: inherit;\">",@failed_msg). |
join("</p>\n<p class=\"LC_error\">",@failed_msg). |
"</p>\n"; |
"</p>\n"); |
} |
} |
$message .= &Apache::lonhtmlcommon::confirm_success(&mt('Moved [quant,_1,message]',$total)); |
$r->print('<p class="LC_success">' |
$message = &Apache::loncommon::confirmwrapper($message); |
.&mt('Moved [quant,_1,message]',$total) |
$r->print($message); |
.'</p>' |
# $r->print('<p>'); |
.'<p>'); |
|
} |
} |
&Apache::loncommunicate::menu($r); |
&Apache::loncommunicate::menu($r); |
&disall($r,($folder?$folder:$dismode),$msgstatus); |
&disall($r,($folder?$folder:$dismode),$msgstatus); |
Line 3485 sub handler {
|
Line 3504 sub handler {
|
} |
} |
} |
} |
&printheader($r,'','Deleted Messages'); |
&printheader($r,'','Deleted Messages'); |
|
my $message = ''; |
if ($failed) { |
if ($failed) { |
$r->print('<p class="LC_error">' |
$message .= &Apache::lonhtmlcommon::confirm_success(&mt('Failed to delete [quant,_1,message]',$failed),1); |
.&mt('Failed to delete [quant,_1,message]',$failed) |
$message .= '<p class="LC_error" style="font-size: inherit;">'. |
.'</p>'); |
join("</p>\n<p class=\"LC_error\" style=\"font-size: inherit;\">",@failed_msg). |
$r->print('<p class="LC_error">'. |
"</p>\n"; |
join("</p>\n<p class=\"LC_error\">",@failed_msg). |
} |
"</p>\n"); |
$message .= &Apache::lonhtmlcommon::confirm_success(&mt('Deleted [quant,_1,message]',$total)); |
} |
$message = &Apache::loncommon::confirmwrapper($message); |
$r->print('<p class="LC_success">' |
$r->print($message); |
.&mt('Deleted [quant,_1,message]',$total) |
# $r->print('<p>'); |
.'</p>' |
|
.'<p>'); |
|
&Apache::loncommunicate::menu($r); |
&Apache::loncommunicate::menu($r); |
&disall($r,($folder?$folder:$dismode),$msgstatus); |
&disall($r,($folder?$folder:$dismode),$msgstatus); |
} elsif ($env{'form.markunread'}) { |
} elsif ($env{'form.markunread'}) { |
Line 3552 sub handler {
|
Line 3570 sub handler {
|
} |
} |
if (keys(%forwardok) > 0) { |
if (keys(%forwardok) > 0) { |
my $count = keys(%forwardok); |
my $count = keys(%forwardok); |
$r->print('<br /><span class="LC_success">'. |
my $message = &Apache::lonhtmlcommon::confirm_success(&mt('[quant,_1,message] forwarded.',$count)); |
&mt('[quant,_1,message] forwarded.',$count). |
$message = &Apache::loncommon::confirmwrapper($message); |
'</span>'); |
$r->print($message); |
} |
} |
if (keys(%forwardfail) > 0) { |
if (keys(%forwardfail) > 0) { |
my $count = keys(%forwardfail); |
my $count = keys(%forwardfail); |
$r->print('<p><span class="LC_error">'. |
my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Could not forward [quant,_1,message].',$count),1); |
&mt('Could not forward [quant,_1,message].',$count). |
|
'</span> '); |
|
foreach my $key (keys(%forwardfail)) { |
foreach my $key (keys(%forwardfail)) { |
$r->print(&mt('Could not deliver forwarded message.').'</span> '. |
$message .= '<br />'.&mt('Could not deliver forwarded message.').'</span> '. |
&mt('The recipient addresses may need to be corrected').' ('.$forwardfail{$key}.').<br /><br />'); |
&mt('The recipient addresses may need to be corrected').' ('.$forwardfail{$key}.')'; |
} |
} |
|
$message = &Apache::loncommon::confirmwrapper($message); |
|
$r->print($message); |
} |
} |
&Apache::loncommunicate::menu($r); |
&Apache::loncommunicate::menu($r); |
} else { |
} else { |
Line 3588 sub handler {
|
Line 3606 sub handler {
|
my $showfolder = $env{'form.newfolder'}; |
my $showfolder = $env{'form.newfolder'}; |
my ($makeresult,$warning) = &makefolder($env{'form.newfolder'}); |
my ($makeresult,$warning) = &makefolder($env{'form.newfolder'}); |
if ($makeresult eq 'ok') { |
if ($makeresult eq 'ok') { |
$r->print('<p class="LC_success">' |
my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Folder "[_1]" created.',$showfolder)); |
.&mt('Folder "[_1]" created.',$showfolder) |
$message = &Apache::loncommon::confirmwrapper($message); |
.'</p>'); |
$r->print($message); |
} else { |
} else { |
$r->print('<p class="LC_warning">' |
my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Creation failed.').' '.$makeresult.'<br />'.$warning,1); |
.&mt('Creation failed.').' '.$makeresult.'<br />' |
$message = &Apache::loncommon::confirmwrapper($message); |
.$warning |
$r->print($message); |
.'</p>'); |
|
$showfolder = $folder; |
$showfolder = $folder; |
} |
} |
&Apache::loncommunicate::menu($r); |
&Apache::loncommunicate::menu($r); |
Line 3607 sub handler {
|
Line 3624 sub handler {
|
my $showfolder = ''; |
my $showfolder = ''; |
my $delresult = &deletefolder($folder); |
my $delresult = &deletefolder($folder); |
if ($delresult eq 'ok') { |
if ($delresult eq 'ok') { |
$r->print('<p class="LC_success">' |
my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Folder "[_1]" deleted.',$folder)); |
.&mt('Folder "[_1]" deleted.',$folder) |
$message = &Apache::loncommon::confirmwrapper($message); |
.'</p>'); |
$r->print($message); |
$env{'form.folder'} = ''; |
$env{'form.folder'} = ''; |
} else { |
} else { |
$r->print('<p class="LC_warning">' |
my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Deletion failed.').' '.$delresult,1); |
.&mt('Deletion failed.').' '.$delresult |
$message = &Apache::loncommon::confirmwrapper($message); |
.'</p>'); |
$r->print($message); |
$showfolder = $folder; |
$showfolder = $folder; |
} |
} |
&Apache::loncommunicate::menu($r); |
&Apache::loncommunicate::menu($r); |
Line 3624 sub handler {
|
Line 3641 sub handler {
|
my $showfolder = $env{'form.renamed'}; |
my $showfolder = $env{'form.renamed'}; |
my $renresult = &renamefolder($folder); |
my $renresult = &renamefolder($folder); |
if ($renresult eq 'ok') { |
if ($renresult eq 'ok') { |
$r->print('<p class="LC_success">' |
my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Folder "[_1]" renamed to "[_2]".',$folder,$showfolder)); |
.&mt('Folder "[_1]" renamed to "[_2]".',$folder,$showfolder) |
$message = &Apache::loncommon::confirmwrapper($message); |
.'</p>'); |
$r->print($message); |
} else { |
} else { |
$r->print('<p class="LC_warning">' |
my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Renaming failed.').' '.$renresult,1); |
.&mt('Renaming failed.').' '.$renresult |
$message = &Apache::loncommon::confirmwrapper($message); |
.'</p>'); |
$r->print($message); |
$showfolder = $folder; |
$showfolder = $folder; |
} |
} |
&Apache::loncommunicate::menu($r); |
&Apache::loncommunicate::menu($r); |