--- loncom/interface/lonmsgdisplay.pm 2006/06/27 18:34:43 1.33 +++ loncom/interface/lonmsgdisplay.pm 2006/06/30 02:06:15 1.35.2.2 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Routines for messaging display # -# $Id: lonmsgdisplay.pm,v 1.33 2006/06/27 18:34:43 albertel Exp $ +# $Id: lonmsgdisplay.pm,v 1.35.2.2 2006/06/30 02:06:15 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -453,7 +453,7 @@ sub disnew { my %lt=&Apache::lonlocal::texthash( 'nm' => 'New Messages', 'su' => 'Subject', - 'co' => 'Course/Group', + 'co' => 'Course', 'da' => 'Date', 'us' => 'Username', 'op' => 'Open', @@ -622,9 +622,9 @@ ENDDISHEADER } $r->print(''); if ($env{'form.sortedby'} eq "revcourse") { - $r->print(''.&mt('Course/Group').''); + $r->print(''.&mt('Course').''); } else { - $r->print(''.&mt('Course/Group').''); + $r->print(''.&mt('Course').''); } $r->print(''); if ($env{'form.sortedby'} eq "revstatus") { @@ -883,6 +883,9 @@ ENDUPLOAD my $studentsel = &discourse(); $r->print($studentsel); } + if ($env{'form.displayedcrit'}) { + $r->print(''); + } $r->print(''. &Apache::lonfeedback::generate_preview_button('compemail','message'). &Apache::lonhtmlcommon::htmlareaselectactive('message')); @@ -1086,7 +1089,7 @@ sub examblock { $r->print('Not allowed'); return; } - my $usertype = (&Apache::loncommon::course_type() eq 'Group') ? 'members', + my $usertype = (&Apache::loncommon::course_type() eq 'Group') ? 'members' : 'students'; my %lt=&Apache::lonlocal::texthash( 'comb' => 'Communication Blocking', @@ -1379,7 +1382,7 @@ sub build_block_table { my ($r,$startblock,$endblock,$setters) = @_; my %lt = &Apache::lonlocal::texthash( 'cacb' => 'Currently active communication blocks', - 'cour' => 'Course/Group', + 'cour' => 'Course', 'dura' => 'Duration', 'blse' => 'Block set by' ); @@ -1641,12 +1644,13 @@ sub sendoffmail { &statuschange($msgid,'replied',$folder); } - my $to = $env{'form.selectedusers.forminput'}; + my @to = + &Apache::loncommon::get_env_multiple('form.selectedusers.forminput'); my $mode = $env{'form.sendmode'}; my %toaddr; - if ($to) { - foreach my $dest (@$to) { + if (@to) { + foreach my $dest (@to) { my ($user,$domain) = split(/:/, $dest); if (($user ne '') && ($domain ne '')) { my $address = $user.":".$domain; # How the code below expects it. @@ -1895,6 +1899,7 @@ sub handler { &compout($r,'',$env{'form.replyto'},undef,undef,$folder,$dismode); } elsif ($env{'form.confirm'}) { &printheader($r,'','Confirmed Receipt'); + my $replying = 0; foreach (keys %env) { if ($_=~/^form\.rec\_(.*)$/) { $r->print(''.&mt('Confirming Receipt').': '. @@ -1905,9 +1910,12 @@ sub handler { $r->print(''.&mt('Confirming Receipt').': '. &Apache::lonmsg::user_crit_received($msgid).'
'); &compout($r,'','','',$msgid); + $replying = 1; } } - &discrit($r); + if (!$replying) { + &discrit($r); + } } elsif ($env{'form.critical'}) { &printheader($r,'','Displaying Critical Messages'); &discrit($r); @@ -2001,7 +2009,9 @@ sub handler { $env{'form.subject'}, $env{'form.message'},'/adm/communicate','public'); } - &disall($r,($folder?$folder:$dismode)); + if (!$env{'form.displayedcrit'}) { + &disall($r,($folder?$folder:$dismode)); + } } elsif ($env{'form.newfolder'}) { &printheader($r,'','New Folder'); &makefolder($env{'form.newfolder'});