From 7e0fd5acbf027f40f9091384265b1feffdec0716 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Thu, 28 Jan 2016 08:54:56 -0500 Subject: [PATCH] Bug 15691 - Show card number minimum and maximum in visible hint when adding a patron Content-Type: text/plain; charset="utf-8" The CardnumberLength system preference defines card number minimum and maximum allowed values when adding a patron. This information is currently hidden in a title attribute on the card number input field. This patch moves the information into a
, matching other fields in the entry form which offer details about entry guidelines. To test, apply the patch and open the new patron entry form. Test for various values of CardnumberLength, and with 'cardnumber' mandatory or not mandatory as defined in BorrowerMandatoryField. --- .../prog/en/modules/members/memberentrygen.tt | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) 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 8a8d3d4..8433229 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt @@ -633,15 +633,22 @@ [% END %] Card number: [% IF minlength_cardnumber == maxlength_cardnumber %] - + + [% IF ( mandatorycardnumber ) %]Required[% END %] +
Card number must be exactly [% minlength_cardnumber %] characters.
[% ELSIF minlength_cardnumber && maxlength_cardnumber %] - + + [% IF ( mandatorycardnumber ) %]Required[% END %] +
Card number must be between [% minlength_cardnumber %] and [% maxlength_cardnumber %] characters.
[% ELSIF maxlength_cardnumber %] - + + [% IF ( mandatorycardnumber ) %]Required[% END %] +
Card number can be up to [% maxlength_cardnumber %] characters.
[% ELSE %] - + + [% IF ( mandatorycardnumber ) %]Required[% END %] +
There is no minimum or maximum character length.
[% END %] - [% IF ( mandatorycardnumber ) %]Required[% END %] [% END %] [% UNLESS nobranchcode %] -- 2.1.4