Don't show contact invalidators for new users
authorJeff Godin <jgodin@tadl.org>
Wed, 30 Oct 2013 18:37:10 +0000 (14:37 -0400)
committerJeff Godin <jgodin@tadl.org>
Wed, 30 Oct 2013 18:37:10 +0000 (14:37 -0400)
Don't show contact invalidator buttons for new users. This affects
staged users and cloned users, where the contact fields have a value
when the editor initially loads.

Signed-off-by: Jeff Godin <jgodin@tadl.org>
Open-ILS/web/js/ui/default/actor/user/register.js

index 90faafa..1b055a4 100644 (file)
@@ -295,7 +295,10 @@ function load() {
         saveCloneButton.attr('disabled', true);
     }
         
-    uUpdateContactInvalidators();
+    if (!patron.isnew()) { // Only existing users get Invalidators
+        uUpdateContactInvalidators();
+    }
+
     lock_ready = true;
 }