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 <katrin.fischer.83@web.de>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

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 <nick@bywatersolutions.com>
This commit is contained in:
Josef Moravec 2018-01-03 10:56:37 +00:00 committed by Nick Clemens
parent 6fe90c2228
commit 33bb028c9e
2 changed files with 1 additions and 4 deletions

View File

@ -50,12 +50,10 @@
$("#changepasswordf").validate({
rules: {
newpassword: {
required: true,
password_strong: true,
password_no_spaces: true
},
newpassword2: {
required: true,
password_match: true
}
}

View File

@ -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("<p>" + _("Note: Quick add guarantor form populates address fields in full form") + "</p>");
$("#quick_add_list #guarantordelete").prop('id','qagd');
}
$("#qagd").click(function() { $("#guarantordelete").click(); });
$("#quick_add_form").show();
});