[open-ils-commits] [GIT] Evergreen ILS branch rel_2_1 updated. 0c00116a764e656f32ec9dc4d8ff3e740cedfa4d
Evergreen Git
git at git.evergreen-ils.org
Mon Nov 7 10:52:02 EST 2011
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Evergreen ILS".
The branch, rel_2_1 has been updated
via 0c00116a764e656f32ec9dc4d8ff3e740cedfa4d (commit)
from d5aaefd25fc41cacdd3462ddcb5ebdfc205f2d73 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 0c00116a764e656f32ec9dc4d8ff3e740cedfa4d
Author: Jason Etheridge <jason at esilibrary.com>
Date: Thu Oct 27 14:16:12 2011 -0400
LP874597 password from phone # when cloning users
Patron: password from phone # does not work when cloning users
Signed-off-by: Jason Etheridge <jason at esilibrary.com>
Signed-off-by: Mike Rylander <mrylander at gmail.com>
diff --git a/Open-ILS/web/js/ui/default/actor/user/register.js b/Open-ILS/web/js/ui/default/actor/user/register.js
index ddb1de0..180797e 100644
--- a/Open-ILS/web/js/ui/default/actor/user/register.js
+++ b/Open-ILS/web/js/ui/default/actor/user/register.js
@@ -919,6 +919,18 @@ function checkCollectionsExemptPerm(cbox) {
);
}
+function usePhonePw(newVal) {
+ if(newVal && newVal.length >= 4) {
+ var newPw = newVal.substring(newVal.length - 4);
+ var pw1 = findWidget('au', 'passwd').widget;
+ var pw2 = findWidget('au', 'passwd2').widget;
+ pw1.attr('value', newPw);
+ pw2.attr('value', newPw);
+ return newPw;
+ } else {
+ return false;
+ }
+}
function attachWidgetEvents(fmcls, fmfield, widget) {
@@ -1079,16 +1091,10 @@ function attachWidgetEvents(fmcls, fmfield, widget) {
case 'day_phone':
// if configured, use the last four digits of the day phone number as the password
if(uEditUsePhonePw && patron.isnew()) {
- dojo.connect(widget.widget, 'onChange',
- function(newVal) {
- if(newVal && newVal.length >= 4) {
- var pw1 = findWidget('au', 'passwd').widget;
- var pw2 = findWidget('au', 'passwd2').widget;
- pw1.attr('value', newVal.substring(newVal.length - 4));
- pw2.attr('value', newVal.substring(newVal.length - 4));
- }
- }
- );
+ dojo.connect(widget.widget, 'onChange', widget.widget, usePhonePw);
+ if (patron.day_phone()) {
+ usePhonePw(patron.day_phone());
+ }
}
case 'evening_phone':
case 'other_phone':
-----------------------------------------------------------------------
Summary of changes:
Open-ILS/web/js/ui/default/actor/user/register.js | 26 +++++++++++++--------
1 files changed, 16 insertions(+), 10 deletions(-)
hooks/post-receive
--
Evergreen ILS
More information about the open-ils-commits
mailing list