[LON-CAPA-cvs] cvs: loncom /interface lonpopulate.pm

albertel lon-capa-cvs@mail.lon-capa.org
Thu, 10 Aug 2006 21:46:42 -0000


albertel		Thu Aug 10 17:46:42 2006 EDT

  Modified files:              
    /loncom/interface	lonpopulate.pm 
  Log:
  - BUG#4960, notification wasnot able to be turned on because the JS
    was assigning a value of true not checking for a value of true
  
  
Index: loncom/interface/lonpopulate.pm
diff -u loncom/interface/lonpopulate.pm:1.46 loncom/interface/lonpopulate.pm:1.47
--- loncom/interface/lonpopulate.pm:1.46	Tue Aug  8 15:02:04 2006
+++ loncom/interface/lonpopulate.pm	Thu Aug 10 17:46:40 2006
@@ -1,5 +1,5 @@
 # automated enrollment configuration handler
-# $Id: lonpopulate.pm,v 1.46 2006/08/08 19:02:04 albertel Exp $
+# $Id: lonpopulate.pm,v 1.47 2006/08/10 21:46:40 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -113,30 +113,28 @@
  }
  if (calling == "notify") {
      var totalnote = 0;
-     if (formName.notify[1].checked = true) {
-         for (var i=0; i<formName.elements.length; i++) {
-             var elementname = formName.elements[i].name;
-             var check_name = elementname.match($notify_check);
-             if (check_name != null) {
-                 if (formName.elements[i].checked) {
-                     totalnote ++;
-                 }
-             } 
-         }
-         if (totalnote > 0) {
-             if (formName.notify[1].checked = true) {
-                 if (confirm("You have indicated that you do not want notification of roster changes messages to be sent, but "+totalnote+" have been checked as recipients.\\nClick 'OK' to erase all recipients, or 'Cancel'.")) {
-                     checker  = 1;
-                 } else {
-                     checker = 0;
-                 }
-             }
-         } else {
-             if (formName.notify[0].checked = true) {
-                 alert("You have indicated that you want notification of roster changes messages to be sent, but you have not selected any recipients.");
-                 checker = 0;
-             }
-         }
+     for (var i=0; i<formName.elements.length; i++) {
+	 var elementname = formName.elements[i].name;
+	 var check_name = elementname.match($notify_check);
+	 if (check_name != null) {
+	     if (formName.elements[i].checked) {
+		 totalnote ++;
+	     }
+	 } 
+     }
+     if (totalnote > 0) {
+	 if (formName.notify[1].checked == true) {
+	     if (confirm("You have indicated that you do not want notification of roster changes messages to be sent, but "+totalnote+" have been checked as recipients.\\nClick 'OK' to erase all recipients, or 'Cancel'.")) {
+		 checker  = 1;
+	     } else {
+		 checker = 0;
+	     }
+	 }
+     } else {
+	 if (formName.notify[0].checked == true) {
+	     alert("You have indicated that you want notification of roster changes messages to be sent, but you have not selected any recipients.");
+	     checker = 0;
+	 }
      }
  }
  if (calling == "viewclass") {