From 33bb028c9e683ac440573bc44b01aabda2b95fba Mon Sep 17 00:00:00 2001 From: Josef Moravec Date: Wed, 3 Jan 2018 10:56:37 +0000 Subject: [PATCH] Bug 19908: Password fields in edit/add patron form should respect BorrowerMandatoryField preference Test plan: 0) Do not apply the patch, note the password field is always required 1) Apply the patch 2) Try to add and edit patron with and without "password" in BorrowerMandatoryField, it should always respect this setting 3) Use "Change password" button in patron toolbar, the password field should be never required here - when leaved blank, the password is unchanged 4) Play with minPasswordLength and RequireStrongPassword preferences, to ensure they work as expected Signed-off-by: Katrin Fischer Signed-off-by: Jonathan Druart Conflicts: koha-tmpl/intranet-tmpl/prog/en/modules/members/member-password.tt koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt Signed-off-by: Nick Clemens --- .../intranet-tmpl/prog/en/modules/members/member-password.tt | 2 -- .../intranet-tmpl/prog/en/modules/members/memberentrygen.tt | 3 +-- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-password.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-password.tt index a80d89c9ba..572071f165 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-password.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-password.tt @@ -50,12 +50,10 @@ $("#changepasswordf").validate({ rules: { newpassword: { - required: true, password_strong: true, password_no_spaces: true }, newpassword2: { - required: true, password_match: true } } diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt index 468370c434..55c02e1834 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt @@ -97,12 +97,10 @@ $(document).ready(function() { $("#entryform").validate({ rules: { password: { - required: true, password_strong: true, password_no_spaces: true }, password2: { - required: true, password_match: true } } @@ -1297,6 +1295,7 @@ $(document).ready(function() { $("#quick_add_form #memberentry_guarantor").append("

" + _("Note: Quick add guarantor form populates address fields in full form") + "

"); $("#quick_add_list #guarantordelete").prop('id','qagd'); } + $("#qagd").click(function() { $("#guarantordelete").click(); }); $("#quick_add_form").show(); }); -- 2.39.5