[LON-CAPA-cvs] cvs: loncom /interface loncreateuser.pm
raeburn
raeburn at source.lon-capa.org
Wed Jul 26 15:42:22 EDT 2017
raeburn Wed Jul 26 19:42:22 2017 EDT
Modified files:
/loncom/interface loncreateuser.pm
Log:
- Fix javascript used to loop over checkboxes for institutional types
when configuring self-enrollment in a course.
Index: loncom/interface/loncreateuser.pm
diff -u loncom/interface/loncreateuser.pm:1.440 loncom/interface/loncreateuser.pm:1.441
--- loncom/interface/loncreateuser.pm:1.440 Sun Apr 2 04:36:07 2017
+++ loncom/interface/loncreateuser.pm Wed Jul 26 19:42:22 2017
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Create a user
#
-# $Id: loncreateuser.pm,v 1.440 2017/04/02 04:36:07 raeburn Exp $
+# $Id: loncreateuser.pm,v 1.441 2017/07/26 19:42:22 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -5829,12 +5829,13 @@
}
function check_types(num,countfail,needaction) {
- var typeidx = getIndexByName('selfenroll_types_'+num);
+ var boxname = 'selfenroll_types_'+num;
+ var typeidx = getIndexByName(boxname);
var count = 0;
if (typeidx != -1) {
- if (document.$formname.elements[typeidx].length) {
- for (var k=0; k<document.$formname.elements[typeidx].length; k++) {
- if (document.$formname.elements[typeidx][k].checked) {
+ if (document.$formname.elements[boxname].length) {
+ for (var k=0; k<document.$formname.elements[boxname].length; k++) {
+ if (document.$formname.elements[boxname][k].checked) {
count ++;
}
}
More information about the LON-CAPA-cvs
mailing list