[open-ils-commits] r18242 - branches/rel_1_6_0/Open-ILS/xul/staff_client/server/patron (phasefx)

svn at svn.open-ils.org svn at svn.open-ils.org
Fri Oct 8 11:47:00 EDT 2010


Author: phasefx
Date: 2010-10-08 11:46:57 -0400 (Fri, 08 Oct 2010)
New Revision: 18242

Modified:
   branches/rel_1_6_0/Open-ILS/xul/staff_client/server/patron/ue_config.js
Log:
make sure we change the juvenile flag on the patron object when we automatically change the juvenile checkbox in the UI

Modified: branches/rel_1_6_0/Open-ILS/xul/staff_client/server/patron/ue_config.js
===================================================================
--- branches/rel_1_6_0/Open-ILS/xul/staff_client/server/patron/ue_config.js	2010-10-08 15:45:04 UTC (rev 18241)
+++ branches/rel_1_6_0/Open-ILS/xul/staff_client/server/patron/ue_config.js	2010-10-08 15:46:57 UTC (rev 18242)
@@ -1154,6 +1154,8 @@
         if( dob < base ) { /* patron is of age */
             ident_field.required = false;
 	        uEditFindFieldByKey('juvenile').widget.node.checked = false;
+            patron.juvenile(0);
+            patron.ischanged(1);
             if(!uEditNodeVal(ident_field))
                 hideMe(ident_field.widget.node.parentNode.parentNode.parentNode);
             return;
@@ -1169,10 +1171,13 @@
     }
 
     unHideMe(ident_field.widget.node.parentNode.parentNode.parentNode);
-    if(!uEditFindFieldByKey('juvenile').widget.node.checked)
-	    uEditFindFieldByKey('juvenile').widget.node.checked = true;
-	ident_field.required = true;
-	uEditCheckErrors();
+    if(!uEditFindFieldByKey('juvenile').widget.node.checked) {
+        uEditFindFieldByKey('juvenile').widget.node.checked = true;
+        patron.juvenile(1);
+        patron.ischanged(1);
+    }
+    ident_field.required = true;
+    uEditCheckErrors();
 }
 
 



More information about the open-ils-commits mailing list