[LON-CAPA-cvs] cvs: loncom /interface lonmsgdisplay.pm
goltermann
goltermann at source.lon-capa.org
Wed May 23 08:28:21 EDT 2012
goltermann Wed May 23 12:28:21 2012 EDT
Modified files:
/loncom/interface lonmsgdisplay.pm
Log:
bug #6593 broadcast messages
if there is only one course member for an access status (active/expired/future), a condition check was missing whether that entry was selected
Index: loncom/interface/lonmsgdisplay.pm
diff -u loncom/interface/lonmsgdisplay.pm:1.159 loncom/interface/lonmsgdisplay.pm:1.160
--- loncom/interface/lonmsgdisplay.pm:1.159 Wed Dec 28 21:49:54 2011
+++ loncom/interface/lonmsgdisplay.pm Wed May 23 12:28:21 2012
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Routines for messaging display
#
-# $Id: lonmsgdisplay.pm,v 1.159 2011/12/28 21:49:54 raeburn Exp $
+# $Id: lonmsgdisplay.pm,v 1.160 2012/05/23 12:28:21 goltermann Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -1462,9 +1462,12 @@
document.compemail.groupmail.value = document.$formname.groupmail[document.$formname.groupmail.selectedIndex].value;
|;
}
+ #typeof(...forminput.length) returns 'undefined' if only one entry exists
$broadcast_js .= qq|
if (typeof(document.$formname.selectedusers_forminput.length)=="undefined") {
- document.compemail.courserecips.value += '_&&&_'+document.$formname.selectedusers_forminput.value;
+ if (document.$formname.selectedusers_forminput.checked) {
+ document.compemail.courserecips.value += '_&&&_'+document.$formname.selectedusers_forminput.value;
+ }
} else {
for (var i=0; i<document.$formname.selectedusers_forminput.length; i++) {
if (document.$formname.selectedusers_forminput[i].checked) {
More information about the LON-CAPA-cvs
mailing list