--- loncom/interface/lonmsg.pm 2003/07/25 01:18:04 1.58
+++ loncom/interface/lonmsg.pm 2003/10/15 18:01:10 1.67
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Routines for messaging
#
-# $Id: lonmsg.pm,v 1.58 2003/07/25 01:18:04 bowersj2 Exp $
+# $Id: lonmsg.pm,v 1.67 2003/10/15 18:01:10 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -115,6 +115,10 @@ use Apache::loncommon();
use Apache::lontexconvert();
use HTML::Entities();
use Mail::Send;
+use Apache::lonlocal;
+
+# Querystring component with sorting type
+my $sqs;
# ===================================================================== Package
@@ -140,7 +144,7 @@ sub packagemsg {
my $result='
Attachment: '.$fname.'.'.$ft.''; + $content{'message'}.='
'.&mt('Attachment').': '.$fname.'.'.$ft.''; } else { - $content{'message'}.='
Attachment: '.$fname.'.'.$ft.'';
}
@@ -209,8 +213,8 @@ sub unpackmsgid {
sub sendemail {
my ($to,$subject,$body)=@_;
$body=
- "*** This is an automatic message generated by the LON-CAPA system.\n".
- "*** Please do not reply to this address.\n\n".$body;
+ "*** ".&mt('This is an automatic message generated by the LON-CAPA system.')."\n".
+ "*** ".&mt('Please do not reply to this address.')."\n\n".$body;
my $msg = new Mail::Send;
$msg->to($to);
$msg->subject('[LON-CAPA] '.$subject);
@@ -359,10 +363,10 @@ sub user_crit_received {
my %contents=&unpackagemsg($message{$msgid},1);
my $status='rec: '.($contents{'sendback'}?
&user_normal_msg($contents{'sendername'},$contents{'senderdomain'},
- 'Receipt: '.$ENV{'user.name'}.' at '.$ENV{'user.domain'},
- 'User '.$ENV{'user.name'}.' at '.$ENV{'user.domain'}.
+ &mt('Receipt').': '.$ENV{'user.name'}.' at '.$ENV{'user.domain'},
+ &mt('User').' '.$ENV{'user.name'}.' '.&mt('at').' '.$ENV{'user.domain'}.
' acknowledged receipt of message'."\n".' "'.
- $contents{'subject'}.'"'."\n".'dated '.
+ $contents{'subject'}.'"'."\n".&mt('dated').' '.
$contents{'time'}.".\n"
):'no msg req');
$status.=' trans: '.
@@ -466,6 +470,9 @@ sub discourse {
$ENV{'course.'.$ENV{'request.course.id'}.'.domain'},
$ENV{'course.'.$ENV{'request.course.id'}.'.num'});
my $now=time;
+ my %lt=&Apache::lonlocal::texthash('cfa' => 'Check for All',
+ 'cfs' => 'Check for Section/Group',
+ 'cfn' => 'Check for None');
$r->print(<
ENDDISHEADER
+ my %coursepersonnel=
+ &Apache::lonnet::get_course_adv_roles();
+ foreach my $role (sort keys %coursepersonnel) {
+ foreach (split(/\,/,$coursepersonnel{$role})) {
+ my ($puname,$pudom)=split(/\:/,$_);
+ $r->print(
+ '
'.
+ &Apache::loncommon::plainname($puname,
+ $pudom).' ('.$_.'), '.$role.'');
+ }
+ }
+
foreach (sort keys %courselist) {
my ($end,$start)=split(/\:/,$courselist{$_});
my $active=1;
@@ -529,7 +549,7 @@ ENDDISHEADER
sub discrit {
my $r=shift;
- my $header = 'Critical Messages
'.
+ my $header = ''.&mt('Critical Messages').'
'.
'