Bugzilla – Attachment 193023 Details for
Bug 41841
Update some patron admin templates to use grid layout for forms
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 41841: Update some patron admin templates to use grid layout for forms
Bug-41841-Update-some-patron-admin-templates-to-us.patch (text/plain), 59.31 KB, created by
Owen Leonard
on 2026-02-12 19:13:06 UTC
(
hide
)
Description:
Bug 41841: Update some patron admin templates to use grid layout for forms
Filename:
MIME Type:
Creator:
Owen Leonard
Created:
2026-02-12 19:13:06 UTC
Size:
59.31 KB
patch
obsolete
>From e1596f1fc18724e33f86b8b737fe42ac593431d9 Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Thu, 12 Feb 2026 12:54:54 -0500 >Subject: [PATCH] Bug 41841: Update some patron admin templates to use grid > layout for forms > >This patch updates patron-related administration templates with >new markup and CSS for layout forms using CSS grids. > >To test, apply the patch rebuild the staff interface CSS. > >Check the following pages, confirming that the "New" and "Edit" versions >of the form look correct in each case: > >- Patron categories >- Patron attribute types >- Patron restriction types > >Sponsored-by: Athens County Public Libraries >--- > .../prog/en/modules/admin/categories.tt | 330 ++++++++++++------ > .../en/modules/admin/patron-attr-types.tt | 232 +++++++----- > .../prog/en/modules/admin/restrictions.tt | 97 +++-- > 3 files changed, 433 insertions(+), 226 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/categories.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/categories.tt >index c0a66967ffb..282090f1fc8 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/categories.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/categories.tt >@@ -34,8 +34,8 @@ > [% INCLUDE 'doc-head-close.inc' %] > [% Asset.css("lib/jquery/plugins/multiple-select/multiple-select.min.css") | $raw %] > <style> >- #enrolmentmessage.hint { >- display: none; >+ fieldset.fg fieldset legend { >+ font-size: 1.2rem; > } > </style> > </head> >@@ -128,60 +128,99 @@ > [% ELSE %] > <h1>New category</h1> > [% END %] >- <fieldset class="rows"> >- <ol> >- [% IF category %] >- <li> <span class="label">Category code: </span>[% categorycode | html %] <input type="hidden" name="categorycode" value="[% category.categorycode | html %]" /><input type="hidden" name="is_a_modif" value="1" /> </li> >- [% ELSE %] >- <li> >+ <fieldset class="fg"> >+ [% IF category %] >+ <div class="fg-row"> >+ <div class="fg-label"> >+ <span class="label">Category code: </span> >+ </div> >+ <div class="fg-text"> >+ [% categorycode | html %] >+ <input type="hidden" name="categorycode" value="[% category.categorycode | html %]" /> >+ <input type="hidden" name="is_a_modif" value="1" /> >+ </div> >+ </div> >+ [% ELSE %] >+ <div class="fg-row"> >+ <div class="fg-label"> > <label for="categorycode" class="required">Category code: </label> >- <input type="text" name="categorycode" id="categorycode" size="10" maxlength="10" class="required focus" required="required" /> >- <span class="required">Required</span> >- </li> >- [% END %] >- <li> >+ </div> >+ <div class="fg-input"> >+ <input type="text" name="categorycode" id="categorycode" maxlength="10" class="required focus" required="required" /> >+ </div> >+ <div class="required">Required</div> >+ </div> >+ [% END %] >+ <div class="fg-row"> >+ <div class="fg-label"> > <label for="description" class="required">Description: </label> >- <input type="text" name="description" id="description" size="40" maxlength="80" class="required" required="required" value="[% category.description | html %]" /> >- <span class="required">Required</span> >- </li> >- <li> >+ </div> >+ <div class="fg-input"> >+ <input type="text" name="description" id="description" maxlength="80" class="required" required="required" value="[% category.description | html %]" /> >+ </div> >+ <div class="required">Required</div> >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> > <span class="label">Enrollment period: </span> >+ </div> >+ <div class="fg-text"> > <fieldset> > <legend>Choose one</legend> >- <ol> >- <li> >+ <div class="fg-row"> >+ <div class="fg-label"> > <label for="enrolmentperiod">In months: </label> >+ </div> >+ <div class="fg-input"> > [% IF category.enrolmentperiod %] >- <input type="text" class="enrollmentperiod" name="enrolmentperiod" id="enrolmentperiod" size="3" maxlength="3" value="[% category.enrolmentperiod | html %]" /> months >+ <input type="text" class="enrollmentperiod" name="enrolmentperiod" id="enrolmentperiod" maxlength="3" value="[% category.enrolmentperiod | html %]" /> months > [% ELSE %] >- <input type="text" class="enrollmentperiod" name="enrolmentperiod" id="enrolmentperiod" size="3" maxlength="3" value="" /> months >+ <input type="text" class="enrollmentperiod" name="enrolmentperiod" id="enrolmentperiod" maxlength="3" value="" /> months > [% END %] >- </li> >- <li> >+ </div> >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> > <label for="enrolmentperioddate">Until date: </label> >+ </div> >+ <div class="fg-input"> > <input type="text" class="enrollmentperiod flatpickr" data-flatpickr-futuredate="true" name="enrolmentperioddate" id="enrolmentperioddate" value="[% category.enrolmentperioddate | html %]" /> >- </li> >- </ol> >+ </div> >+ </div> > </fieldset> >- </li> >- <li> >+ </div> >+ </div> >+ <div class="fg-row input-sm"> >+ <div class="fg-label"> > <label for="password_expiry_days">Password expiration: </label> >- <input type="text" name="password_expiry_days" id="password_expiry_days" value="[% category.password_expiry_days | html %]" size="3" maxlength="5" /> days >- </li> >- <li> >+ </div> >+ <div class="fg-input"> <input type="text" name="password_expiry_days" id="password_expiry_days" value="[% category.password_expiry_days | html %]" maxlength="5" /> days </div> >+ </div> >+ <div class="fg-row input-sm"> >+ <div class="fg-label"> > <label for="dateofbirthrequired">Age required: </label> >- <input type="text" name="dateofbirthrequired" id="dateofbirthrequired" value="[% category.dateofbirthrequired | html %]" size="3" maxlength="3" /> years >- </li> >- <li> >+ </div> >+ <div class="fg-input"> <input type="text" name="dateofbirthrequired" id="dateofbirthrequired" value="[% category.dateofbirthrequired | html %]" maxlength="3" /> years </div> >+ </div> >+ <div class="fg-row input-sm"> >+ <div class="fg-label"> > <label for="upperagelimit">Upperage limit: </label> >- <input type="text" name="upperagelimit" id="upperagelimit" size="3" maxlength="3" value="[% category.upperagelimit | html %]" /> years >- </li> >- <li> >+ </div> >+ <div class="fg-input"> <input type="text" name="upperagelimit" id="upperagelimit" maxlength="3" value="[% category.upperagelimit | html %]" /> years </div> >+ </div> >+ <div class="fg-row input-sm"> >+ <div class="fg-label"> > <label for="enrolmentfee">Enrollment fee: </label> >- <input type="text" name="enrolmentfee" id="enrolmentfee" size="6" value="[% category.enrolmentfee | $Price on_editing => 1 %]" /> >- </li> >- <li> >+ </div> >+ <div class="fg-input"> >+ <input type="text" name="enrolmentfee" id="enrolmentfee" value="[% category.enrolmentfee | $Price on_editing => 1 %]" /> >+ </div> >+ </div> >+ <div class="fg-row input-md"> >+ <div class="fg-label"> > <label for="overduenoticerequired">Overdue notice required: </label> >+ </div> >+ <div class="fg-input"> > <select name="overduenoticerequired" id="overduenoticerequired"> > [% IF category.overduenoticerequired %] > <option value="0">No</option> >@@ -191,9 +230,13 @@ > <option value="1">Yes</option> > [% END %] > </select> >- </li> >- <li> >+ </div> >+ </div> >+ <div class="fg-row input-md"> >+ <div class="fg-label"> > <label for="hidelostitems">Lost items in staff interface: </label> >+ </div> >+ <div class="fg-input"> > <select name="hidelostitems" id="hidelostitems"> > [% IF category.hidelostitems %] > <option value="0">Shown</option> >@@ -203,9 +246,13 @@ > <option value="1">Hidden by default</option> > [% END %] > </select> >- </li> >- <li> >+ </div> >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> > <label for="category_type" class="required">Category type: </label> >+ </div> >+ <div class="fg-input"> > <select name="category_type" id="category_type"> > [% UNLESS category %]<option value="" selected="selected">Select a category type</option>[% ELSE %]<option value="">Select a category type</option>[% END %] > [% IF category and category.category_type == 'A' %]<option value="A" selected="selected">Adult</option>[% ELSE %]<option value="A">Adult</option>[% END %] >@@ -215,10 +262,14 @@ > [% IF category and category.category_type == 'P' %]<option value="P" selected="selected">Professional</option>[% ELSE %]<option value="P">Professional</option>[% END %] > [% IF category and category.category_type == 'X' %]<option value="X" selected="selected">Statistical</option>[% ELSE %]<option value="X">Statistical</option>[% END %] > </select> >- <span class="required">Required</span> >- </li> >- <li> >+ </div> >+ <div class="required">Required</div> >+ </div> >+ <div class="fg-row input-sm"> >+ <div class="fg-label"> > <label for="can_be_guarantee">Can be guarantee:</label> >+ </div> >+ <div class="fg-input"> > <select name="can_be_guarantee" id="can_be_guarantee"> > [% IF category.can_be_guarantee %] > <option value="1" selected>Yes</option> >@@ -228,16 +279,24 @@ > <option value="0" selected>No</option> > [% END %] > </select> >- </li> >- <li >- ><label for="library_limitation">Library limitations: </label> >+ </div> >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> >+ <label for="library_limitation">Library limitations: </label> >+ </div> >+ <div class="fg-input"> > <select id="library_limitation" name="branches" multiple size="10"> > [% PROCESS options_for_libraries libraries => Branches.all( selected => category.get_library_limits, unfiltered => 1, do_not_select_my_library => 1 ) %] > </select> >- <div class="hint">Limits the use of this category to the selected libraries.</div> >- </li> >- <li> >+ </div> >+ <div class="hint">Limits the use of this category to the selected libraries.</div> >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> > <label for="reset_password">Password reset in OPAC: </label> >+ </div> >+ <div class="fg-input"> > <select name="reset_password" id="reset_password"> > [% IF category.reset_password.defined %] > [% IF category.reset_password %] >@@ -267,9 +326,13 @@ > <option value="0">Not allowed</option> > [% END %] > </select> >- </li> >- <li> >+ </div> >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> > <label for="change_password">Password change in OPAC: </label> >+ </div> >+ <div class="fg-input"> > <select name="change_password" id="change_password"> > [% IF category.change_password.defined %] > [% IF category.change_password %] >@@ -299,14 +362,22 @@ > <option value="0">Not allowed</option> > [% END %] > </select> >- </li> >- <li> >+ </div> >+ </div> >+ <div class="fg-row input-sm"> >+ <div class="fg-label"> > <label for="min_password_length">Minimum password length:</label> >+ </div> >+ <div class="fg-input"> > <input id="min_password_length" type="text" inputmode="numeric" name="min_password_length" value="[% category.min_password_length | html %]" /> >- <div class="hint">Leave blank to use system default ([% Koha.Preference('minPasswordLength') | html %])</div> >- </li> >- <li class="pwd_setting_wrapper"> >+ </div> >+ <div class="hint">Leave blank to use system default ([% Koha.Preference('minPasswordLength') | html %])</div> >+ </div> >+ <div class="fg-row pwd_setting_wrapper"> >+ <div class="fg-label"> > <label for="require_strong_password">Require strong password:</label> >+ </div> >+ <div class="fg-input"> > <select id="require_strong_password" name="require_strong_password"> > [% IF category.require_strong_password.defined %] > [% IF category.require_strong_password %] >@@ -336,9 +407,13 @@ > <option value="0">No</option> > [% END %] > </select> >- </li> >- <li> >+ </div> >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> > <label for="force_password_reset_when_set_by_staff">Force new patron password reset: </label> >+ </div> >+ <div class="fg-input"> > <select name="force_password_reset_when_set_by_staff" id="force_password_reset_when_set_by_staff"> > [% IF category.force_password_reset_when_set_by_staff.defined %] > [% IF category.force_password_reset_when_set_by_staff %] >@@ -368,10 +443,14 @@ > <option value="0">Don't force</option> > [% END %] > </select> >- <div class="hint"> Choose whether staff-created patrons of this category are forced to change their password after their first OPAC login. </div> >- </li> >- <li >- ><label for="block_expired">Block expired patron OPAC actions:</label> >+ </div> >+ <div class="hint"> Choose whether staff-created patrons of this category are forced to change their password after their first OPAC login. </div> >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> >+ <label for="block_expired">Block expired patron OPAC actions:</label> >+ </div> >+ <div class="fg-input"> > <select name="BlockExpiredPatronOpacActions" id="block_expired" multiple="multiple"> > <optgroup label="Follow system preference"> > [% IF category and category.BlockExpiredPatronOpacActions_contains('follow_syspref_BlockExpiredPatronOpacActions') %] >@@ -398,15 +477,19 @@ > [% END %] > </optgroup> > </select> >- [%- SET pref_BlockExpiredPatronOpacActions_link = '<a href="/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=BlockExpiredPatronOpacActions&ok=Search">BlockExpiredPatronOpacActions</a>' -%] >- <div class="hint" >- >Choose which OPAC actions, if any, should be blocked for expired patrons in this category. Alternatively, you can use the system preference [%- pref_BlockExpiredPatronOpacActions_link | $raw | $KohaSpan -%] >- instead.</div >- > >- </li> >- [% IF ( Koha.Preference('CheckPrevCheckout') == 'softyes' || Koha.Preference('CheckPrevCheckout') == 'softno' ) %] >- <li >- ><label for="checkprevcheckout">Check for previous checkouts: </label> >+ </div> >+ [%- SET pref_BlockExpiredPatronOpacActions_link = '<a href="/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=BlockExpiredPatronOpacActions&ok=Search">BlockExpiredPatronOpacActions</a>' -%] >+ <div class="hint" >+ >Choose which OPAC actions, if any, should be blocked for expired patrons in this category. Alternatively, you can use the system preference [%- pref_BlockExpiredPatronOpacActions_link | $raw | $KohaSpan -%] >+ instead.</div >+ > >+ </div> >+ [% IF ( Koha.Preference('CheckPrevCheckout') == 'softyes' || Koha.Preference('CheckPrevCheckout') == 'softno' ) %] >+ <div class="fg-row input-sm"> >+ <div class="fg-label"> >+ <label for="checkprevcheckout">Check for previous checkouts: </label> >+ </div> >+ <div class="fg-input"> > <select name="checkprevcheckout" id="checkprevcheckout"> > [% IF category.checkprevcheckout == 'yes' %] > <option value="yes" selected="selected">Yes and try to override system preferences</option> >@@ -422,12 +505,16 @@ > <option value="inherit" selected="selected">Inherit from system preferences</option> > [% END %] > </select> >- <div class="hint"> Choose whether patrons of this category by default are reminded if they try to borrow an item they borrowed before. </div> >- </li> >- [% END %] >- [% IF ( Koha.Preference('ILLModule') ) %] >- <li> >+ </div> >+ <div class="hint"> Choose whether patrons of this category by default are reminded if they try to borrow an item they borrowed before. </div> >+ </div> >+ [% END %] >+ [% IF ( Koha.Preference('ILLModule') ) %] >+ <div class="fg-row input-sm"> >+ <div class="fg-label"> > <label for="can_place_ill_in_opac">Can place ILL in OPAC: </label> >+ </div> >+ <div class="fg-input"> > <select id="can_place_ill_in_opac" name="can_place_ill_in_opac"> > [% IF category.can_place_ill_in_opac %] > <option value="0">No</option> >@@ -437,11 +524,15 @@ > <option value="1">Yes</option> > [% END %] > </select> >- <div class="hint"> Choose whether patrons of this category can create new interlibrary loan requests. </div> >- </li> >- [% END %] >- <li> >+ </div> >+ <div class="hint"> Choose whether patrons of this category can create new interlibrary loan requests. </div> >+ </div> >+ [% END %] >+ <div class="fg-row"> >+ <div class="fg-label"> > <label for="default_privacy">Default privacy: </label> >+ </div> >+ <div class="fg-input"> > <select id="default_privacy" name="default_privacy"> > [% SET default_privacy = 'default' %] > [% IF category %][% SET default_privacy = category.default_privacy %][% END %] >@@ -460,13 +551,17 @@ > <option value="forever">Forever</option> > [% END %] > </select> >- <div class="hint" >- >Controls how long a patrons checkout history is kept for new patrons of this category. "Never" anonymizes checkouts on return, and "Forever" keeps a patron's checkout history indefinitely. When set to "Default", >- the amount of history kept is controlled by the cronjob <em>batch_anonymise.pl</em> which should be set up by your system administrator.</div >- > >- </li> >- <li> >+ </div> >+ <div class="hint"> >+ Controls how long a patrons checkout history is kept for new patrons of this category. "Never" anonymizes checkouts on return, and "Forever" keeps a patron's checkout history indefinitely. When set to "Default", the >+ amount of history kept is controlled by the cronjob <em>batch_anonymise.pl</em> which should be set up by your system administrator. >+ </div> >+ </div> >+ <div class="fg-row input-sm"> >+ <div class="fg-label"> > <label for="exclude_from_local_holds_priority">Exclude from local holds priority:</label> >+ </div> >+ <div class="fg-input"> > <select id="exclude_from_local_holds_priority" name="exclude_from_local_holds_priority"> > [% IF category.exclude_from_local_holds_priority %] > <option value="1" selected>Yes</option> >@@ -476,36 +571,51 @@ > <option value="0" selected>No</option> > [% END %] > </select> >- <div class="hint">If <i>Yes</i>, holds placed by patrons of this category will not be given priority.</div> >- </li> >- <li> >+ </div> >+ <div class="hint">If <i>Yes</i>, holds placed by patrons of this category will not be given priority.</div> >+ </div> >+ <div class="fg-row input-sm"> >+ <div class="fg-label"> > <label for="noissuescharge">Checkout charge limit: </label> >- <input type="text" pattern="^\d+(\.\d{2})?$" name="noissuescharge" id="noissuescharge" value="[% category.noissuescharge | $Price on_editing => 1 %]" size="5" maxlength="8" /> >- [%- SET pref_noissuescharge_link = '<a href="/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=noissuescharge&ok=Search">noissuescharge</a>' -%] >- <div class="hint">If set, this will override the global value set in the [%- pref_noissuescharge_link | $raw | $KohaSpan -%] system preference.</div> >- </li> >- <li> >+ </div> >+ <div class="fg-input"> >+ <input type="text" pattern="^\d+(\.\d{2})?$" name="noissuescharge" id="noissuescharge" value="[% category.noissuescharge | $Price on_editing => 1 %]" maxlength="8" /> >+ </div> >+ [%- SET pref_noissuescharge_link = '<a href="/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=noissuescharge&ok=Search">noissuescharge</a>' -%] >+ <div class="hint">If set, this will override the global value set in the [%- pref_noissuescharge_link | $raw | $KohaSpan -%] system preference.</div> >+ </div> >+ <div class="fg-row input-sm"> >+ <div class="fg-label"> > <label for="noissueschargeguarantees">Guarantees checkout charge limit: </label> >- <input type="text" pattern="^\d+(\.\d{2})?$" name="noissueschargeguarantees" id="noissueschargeguarantees" value="[% category.noissueschargeguarantees | $Price on_editing => 1 %]" size="5" maxlength="8" /> >- [%- SET pref_NoIssuesChargeGuarantees_link = '<a href="/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=NoIssuesChargeGuarantees&ok=Search">NoIssuesChargeGuarantees</a>' -%] >- <div class="hint">If set, this will override the global value set in the [%- pref_NoIssuesChargeGuarantees_link | $raw | $KohaSpan -%] system preference.</div> >- </li> >- <li> >+ </div> >+ <div class="fg-input"> >+ <input type="text" pattern="^\d+(\.\d{2})?$" name="noissueschargeguarantees" id="noissueschargeguarantees" value="[% category.noissueschargeguarantees | $Price on_editing => 1 %]" maxlength="8" /> >+ </div> >+ [%- SET pref_NoIssuesChargeGuarantees_link = '<a href="/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=NoIssuesChargeGuarantees&ok=Search">NoIssuesChargeGuarantees</a>' -%] >+ <div class="hint">If set, this will override the global value set in the [%- pref_NoIssuesChargeGuarantees_link | $raw | $KohaSpan -%] system preference.</div> >+ </div> >+ <div class="fg-row input-sm"> >+ <div class="fg-label"> > <label for="noissueschargeguarantorswithguarantees">Guarantors with guarantees checkout charge limit: </label> >+ </div> >+ <div class="fg-input"> > <input > type="text" > pattern="^\d+(\.\d{2})?$" > name="noissueschargeguarantorswithguarantees" > id="noissueschargeguarantorswithguarantees" > value="[% category.noissueschargeguarantorswithguarantees | $Price on_editing => 1 %]" >- size="5" > maxlength="8" > /> >- [%- SET pref_NoIssuesChargeGuarantorsWithGuarantees_link = '<a href="/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=NoIssuesChargeGuarantorsWithGuarantees&ok=Search">NoIssuesChargeGuarantorsWithGuarantees</a>' -%] >- <div class="hint">If set, this will override the global value set in the [%- pref_NoIssuesChargeGuarantorsWithGuarantees_link | $raw | $KohaSpan -%] system preference.</div> >- </li> >- <li> >+ </div> >+ [%- SET pref_NoIssuesChargeGuarantorsWithGuarantees_link = '<a href="/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=NoIssuesChargeGuarantees&ok=Search">NoIssuesChargeGuarantees</a>' -%] >+ <div class="hint">If set, this will override the global value set in the [%- pref_NoIssuesChargeGuarantorsWithGuarantees_link | $raw | $KohaSpan -%] system preference.</div> >+ </div> >+ <div class="fg-row input-sm"> >+ <div class="fg-label"> > <label for="enforce_expiry_notice">Enforce patron account expiry notice:</label> >+ </div> >+ <div class="fg-input"> > <select name="enforce_expiry_notice" id="enforce_expiry_notice"> > [% IF category.enforce_expiry_notice %] > <option value="1" selected>Yes</option> >@@ -515,9 +625,9 @@ > <option value="0" selected>No</option> > [% END %] > </select> >- <div class="hint">Make the account expiry notice mandatory for all patrons in this category and prevent patrons from opting out in the messaging preferences</div> >- </li> >- </ol> >+ </div> >+ <div class="hint">Make the account expiry notice mandatory for all patrons in this category and prevent patrons from opting out in the messaging preferences</div> >+ </div> > </fieldset> > > [% IF ( EnhancedMessagingPreferences ) %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/patron-attr-types.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/patron-attr-types.tt >index 631a41867b8..d0e459b15e4 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/patron-attr-types.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/patron-attr-types.tt >@@ -87,27 +87,41 @@ > <form action="/cgi-bin/koha/admin/patron-attr-types.pl" class="validated" method="post"> > [% INCLUDE 'csrf-token.inc' %] > <input type="hidden" name="op" value="[% confirm_op | html %]" /> >- <fieldset class="rows"> >- <ol> >- <li> >- [% IF attribute_type %] >+ <fieldset class="fg"> >+ <div class="fg-row"> >+ [% IF attribute_type %] >+ <div class="fg-label"> > <span class="label">Patron attribute type code: </span> >+ </div> >+ <div class="fg-input"> > <input type="hidden" name="code" value="[% attribute_type.code |html %]" /> > [% attribute_type.code |html %] >- [% ELSE %] >+ </div> >+ [% ELSE %] >+ <div class="fg-label"> > <label for="code" class="required">Patron attribute type code: </label> >+ </div> >+ <div class="fg-input"> > <input type="text" id="code" name="code" required="required" class="required focus" maxlength="64" /> >- <span class="required">Required</span> >- [% END %] >- </li> >- <li >- ><label for="description" class="required">Description: </label> >- <input type="text" id="description" name="description" required="required" class="required" size="50" maxlength="250" value="[% attribute_type.description |html %]" /> >- <span class="required">Required</span> >- </li> >+ </div> >+ <div class="required">Required</div> >+ [% END %] >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> >+ <label for="description" class="required">Description: </label> >+ </div> >+ <div class="fg-input"> >+ <input type="text" id="description" name="description" required="required" class="required" maxlength="250" value="[% attribute_type.description |html %]" /> >+ </div> >+ <div class="required">Required</div> >+ </div> > >- <li [% IF attribute_type AND attribute_type.repeatable AND NOT can_be_set_to_nonrepeatable %]aria-disabled="true"[% END %]> >- <label for="repeatable">Repeatable: </label> >+ <div class="fg-row input-checkbox" [% IF attribute_type AND attribute_type.repeatable AND NOT can_be_set_to_nonrepeatable %]aria-disabled="true"[% END %]> >+ <div class="fg-label"> >+ <label for="repeatable">Repeatable</label> >+ </div> >+ <div class="fg-input"> > [% IF attribute_type %] > [% IF attribute_type.repeatable AND NOT can_be_set_to_nonrepeatable %] > <input type="checkbox" id="repeatable" name="repeatable" checked="checked" disabled="disabled" title="At least one patron has more than one value for this attribute" /> >@@ -120,11 +134,15 @@ > [% ELSE %] > <input type="checkbox" id="repeatable" name="repeatable" /> > [% END %] >- <span class="hint">Check to let a patron record have multiple values of this attribute.</span> >- </li> >+ </div> >+ <div class="hint">Check to let a patron record have multiple values of this attribute.</div> >+ </div> > >- <li [% IF attribute_type AND not can_be_set_to_unique %]aria-disabled="true"[% END %]> >- <label for="unique_id">Unique identifier: </label> >+ <div class="fg-row input-checkbox" [% IF attribute_type AND not can_be_set_to_unique %]aria-disabled="true"[% END %]> >+ <div class="fg-label"> >+ <label for="unique_id">Unique identifier</label> >+ </div> >+ <div class="fg-input"> > [% IF attribute_type %] > [% IF attribute_type.unique_id %] > <input type="checkbox" id="unique_id" name="unique_id" checked="checked" /> >@@ -137,113 +155,159 @@ > [% ELSE %] > <input type="checkbox" id="unique_id" name="unique_id" /> > [% END %] >- <span class="hint">If checked, attribute will be a unique identifier. If a value is given to a patron record, the same value cannot be given to a different record.</span> >- </li> >- <li >- ><label for="is_date">Is a date: </label> >+ </div> >+ <div class="hint">If checked, attribute will be a unique identifier. If a value is given to a patron record, the same value cannot be given to a different record.</div> >+ </div> >+ <div class="fg-row input-checkbox"> >+ <div class="fg-label"> >+ <label for="is_date">Is a date</label> >+ </div> >+ <div class="fg-input"> > [% IF attribute_type AND attribute_type.is_date %] > <input type="checkbox" id="is_date" name="is_date" checked="checked" /> > [% ELSE %] > <input type="checkbox" id="is_date" name="is_date" /> > [% END %] >- <span class="hint">If checked, the attribute will be a date. Date attributes can be repeatable, but cannot be linked to an authorized value category.</span> >- </li> >- <li >- ><label for="opac_display">Display in OPAC: </label> >+ </div> >+ <div class="hint">If checked, the attribute will be a date. Date attributes can be repeatable, but cannot be linked to an authorized value category.</div> >+ </div> >+ <div class="fg-row input-checkbox"> >+ <div class="fg-label"> >+ <label for="opac_display">Display in OPAC</label> >+ </div> >+ <div class="fg-input"> > [% IF attribute_type AND attribute_type.opac_display %] > <input type="checkbox" id="opac_display" name="opac_display" checked="checked" /> > [% ELSE %] > <input type="checkbox" id="opac_display" name="opac_display" /> > [% END %] >- <span class="hint">Check to display this attribute on a patron's details page in the OPAC.</span> >- </li> >- <li >- ><label for="opac_editable">Editable in OPAC: </label> >+ </div> >+ <div class="hint">Check to display this attribute on a patron's details page in the OPAC.</div> >+ </div> >+ <div class="fg-row input-checkbox"> >+ <div class="fg-label"> >+ <label for="opac_editable">Editable in OPAC</label> >+ </div> >+ <div class="fg-input"> > [% IF attribute_type AND attribute_type.opac_editable %] > <input type="checkbox" id="opac_editable" name="opac_editable" checked="checked" /> > [% ELSE %] > <input type="checkbox" id="opac_editable" name="opac_editable" /> > [% END %] >- <span class="hint">Check to allow patrons to edit this attribute from their details page in the OPAC. (Requires above)</span> >- </li> >- <li >- ><label for="staff_searchable">Searchable: </label> >+ </div> >+ <div class="hint">Check to allow patrons to edit this attribute from their details page in the OPAC. (Requires above)</div> >+ </div> >+ <div class="fg-row input-checkbox"> >+ <div class="fg-label"> >+ <label for="staff_searchable">Searchable</label> >+ </div> >+ <div class="fg-input"> > [% IF attribute_type AND attribute_type.staff_searchable %] > <input type="checkbox" id="staff_searchable" name="staff_searchable" checked="checked" /> > [% ELSE %] > <input type="checkbox" id="staff_searchable" name="staff_searchable" /> > [% END %] >- <span class="hint"> Check to make this attribute searchable in staff patron searches. If checked, this attribute will appear in patron search dropdowns. </span> >- </li> >- <li >- ><label for="searched_by_default">Search by default: </label> >+ </div> >+ <div class="hint"> Check to make this attribute searchable in staff patron searches. If checked, this attribute will appear in patron search dropdowns. </div> >+ </div> >+ <div class="fg-row input-checkbox"> >+ <div class="fg-label"> >+ <label for="searched_by_default">Search by default</label> >+ </div> >+ <div class="fg-input"> > [% IF attribute_type AND attribute_type.searched_by_default %] > <input type="checkbox" id="searched_by_default" name="searched_by_default" checked="checked" /> > [% ELSE %] > <input type="checkbox" id="searched_by_default" name="searched_by_default" /> > [% END %] >- <span class="hint"> If checked, this field will be included in 'Standard' patron searches. Requires field to be marked as searchable above </span> >- </li> >- <li >- ><label for="mandatory">Staff interface mandatory: </label> >+ </div> >+ <div class="hint"> If checked, this field will be included in 'Standard' patron searches. Requires field to be marked as searchable above </div> >+ </div> >+ <div class="fg-row input-checkbox"> >+ <div class="fg-label"> >+ <label for="mandatory">Staff interface mandatory</label> >+ </div> >+ <div class="fg-input"> > [% IF attribute_type AND attribute_type.mandatory %] > <input type="checkbox" id="mandatory" name="mandatory" checked="checked" /> > [% ELSE %] > <input type="checkbox" id="mandatory" name="mandatory" /> > [% END %] >- <span class="hint">Check to make this attribute mandatory when creating or editing a patron from the staff interface.</span> >- </li> >- <li >- ><label for="opac_mandatory">OPAC mandatory: </label> >+ </div> >+ <div class="hint">Check to make this attribute mandatory when creating or editing a patron from the staff interface.</div> >+ </div> >+ <div class="fg-row input-checkbox"> >+ <div class="fg-label"> >+ <label for="opac_mandatory">OPAC mandatory</label> >+ </div> >+ <div class="fg-input"> > [% IF attribute_type AND attribute_type.opac_mandatory %] > <input type="checkbox" id="opac_mandatory" name="opac_mandatory" checked="checked" /> > [% ELSE %] > <input type="checkbox" id="opac_mandatory" name="opac_mandatory" /> > [% END %] >- <span class="hint">Check to make this attribute mandatory when creating or editing a patron from the OPAC. Requires 'Editable in OPAC.'</span> >- </li> >- <li >- ><label for="display_checkout">Display in patron's brief information: </label> >+ </div> >+ <div class="hint">Check to make this attribute mandatory when creating or editing a patron from the OPAC. Requires 'Editable in OPAC.'</div> >+ </div> >+ <div class="fg-row input-checkbox"> >+ <div class="fg-label"> >+ <label for="display_checkout">Display in patron's brief information</label> >+ </div> >+ <div class="fg-input"> > [% IF attribute_type AND attribute_type.display_checkout %] > <input type="checkbox" id="display_checkout" name="display_checkout" checked="checked" /> > [% ELSE %] > <input type="checkbox" id="display_checkout" name="display_checkout" /> > [% END %] >- <span class="hint">Check to show this attribute in the brief information panel in the patron's record (staff interface).</span> >- </li> >+ </div> >+ <div class="hint">Check to show this attribute in the brief information panel in the patron's record (staff interface).</div> >+ </div> > >- [% IF Koha.Preference('Pseudonymization') %] >- <li> >- <label for="keep_for_pseudonymization">Keep for pseudonymization: </label> >+ [% IF Koha.Preference('Pseudonymization') %] >+ <div class="fg-row input-checkbox"> >+ <div class="fg-label"> >+ <label for="keep_for_pseudonymization">Keep for pseudonymization</label> >+ </div> >+ <div class="fg-input"> > [% IF attribute_type AND attribute_type.keep_for_pseudonymization %] > <input type="checkbox" id="keep_for_pseudonymization" name="keep_for_pseudonymization" checked="checked" /> > [% ELSE %] > <input type="checkbox" id="keep_for_pseudonymization" name="keep_for_pseudonymization" /> > [% END %] >- <span class="hint">Check to make this attribute copied to the patron's pseudonymized attributes.</span> >- </li> >- [% END %] >+ </div> >+ <div class="hint">Check to make this attribute copied to the patron's pseudonymized attributes.</div> >+ </div> >+ [% END %] > >- <li >- ><label for="authorised_value_category">Authorized value category: </label> >+ <div class="fg-row"> >+ <div class="fg-label"> >+ <label for="authorised_value_category">Authorized value category: </label> >+ </div> >+ <div class="fg-input"> > <select name="authorised_value_category" id="authorised_value_category"> > <option value=""></option> > [% PROCESS options_for_authorised_value_categories authorised_value_categories => AuthorisedValues.GetCategories( selected => attribute_type.authorised_value_category ) %] > </select> >- <div class="hint" >- >If one is selected, the patron record input page will only allow values to be chosen from the authorized value list. However, an authorized value list is not enforced during batch patron import.</div >- > >- </li> >- <li >- ><label for="library_limitation">Library limitation: </label> >+ </div> >+ <div class="hint">If one is selected, the patron record input page will only allow values to be chosen from the authorized value list. However, an authorized value list is not enforced during batch patron import.</div> >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> >+ <label for="library_limitation">Library limitation: </label> >+ </div> >+ <div class="fg-input"> > <select id="library_limitation" name="branches" multiple size="10"> > <option value="">All libraries</option> > [% PROCESS options_for_libraries libraries => Branches.all( selected => attribute_type.library_limits ) %] > </select> >- <div class="hint">Limits the use of this attribute to the selected libraries. </div> >- </li> >- <li> >+ </div> >+ <div class="hint">Select "All libraries" if this attribute type should always be displayed. Otherwise select libraries you want to associate with this value. </div> >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> > <label for="category">Category: </label> >+ </div> >+ <div class="fg-input"> > <select name="category_code" id="category"> > <option value=""></option> > [% FOREACH cat IN categories %] >@@ -254,20 +318,22 @@ > [% END %] > [% END %] > </select> >- <div class="hint">Choose one to limit this attribute to one patron type. Please leave blank if you want these attributes to be available for all types of patrons.</div> >- </li> >- <li> >+ </div> >+ <div class="hint">Choose one to limit this attribute to one patron type. Please leave blank if you want these attributes to be available for all types of patrons.</div> >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> > <label for="class">Class: </label> >- [% PROCESS 'av-build-dropbox.inc' name="class", category="PA_CLASS" default=attribute_type.class empty=1 %] >- <div class="hint"> >- [% IF ( CAN_user_parameters_manage_auth_values ) %] >- Group attributes types with a block title (based on <a target="_blank" href="/cgi-bin/koha/admin/authorised_values.pl?searchfield=PA_CLASS">authorized values category 'PA_CLASS'</a>) >- [% ELSE %] >- Group attributes types with a block title (based on authorized values category 'PA_CLASS') >- [% END %] >- </div> >- </li> >- </ol> >+ </div> >+ <div class="fg-input"> [% PROCESS 'av-build-dropbox.inc' name="class", category="PA_CLASS" default=attribute_type.class empty=1 %] </div> >+ <div class="hint"> >+ [% IF ( CAN_user_parameters_manage_auth_values ) %] >+ Group attributes types with a block title (based on <a target="_blank" href="/cgi-bin/koha/admin/authorised_values.pl?searchfield=PA_CLASS">authorized values category 'PA_CLASS'</a>) >+ [% ELSE %] >+ Group attributes types with a block title (based on authorized values category 'PA_CLASS') >+ [% END %] >+ </div> >+ </div> > </fieldset> > <fieldset class="action"> > <input type="submit" class="btn btn-primary" value="Save" /> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/restrictions.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/restrictions.tt >index cf11b2c6d51..2b7a01b3cf6 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/restrictions.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/restrictions.tt >@@ -103,20 +103,31 @@ > [% ELSE %] > <h1>New restriction type</h1> > [% END %] >- <fieldset class="rows"> >- <ol> >- [% IF restriction %] >- <li> >- <span class="label">Code: </span>[% restriction.code | html %] >+ <fieldset class="fg"> >+ [% IF restriction %] >+ <div class="fg-row input-md"> >+ <div class="fg-label"> >+ <span class="label">Code: </span> >+ </div> >+ <div class="fg-text"> >+ [% restriction.code | html %] > <input type="hidden" name="code" value="[% restriction.code | html %]" /> >- </li> >- <li> >+ </div> >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> > <label for="display_text" class="required">Label: </label> >- <input type="text" value="[% restriction.display_text | html %]" name="display_text" id="display_text" size="50" maxlength="50" class="required" required="required" /> >- <span class="required">Required</span> >- </li> >- <li> >+ </div> >+ <div class="fg-input"> >+ <input type="text" value="[% restriction.display_text | html %]" name="display_text" id="display_text" maxlength="50" class="required" required="required" /> >+ </div> >+ <div class="required">Required</div> >+ </div> >+ <div class="fg-row input-sm"> >+ <div class="fg-label"> > <label for="lift_after_payment" class="required">Lift after payment: </label> >+ </div> >+ <div class="fg-input"> > <select type="text" name="lift_after_payment" id="lift_after_payment"> > [% IF restriction.lift_after_payment %] > <option value="0">No</option> >@@ -126,35 +137,55 @@ > <option value="1">Yes</option> > [% END %] > </select> >- </li> >- <li> >+ </div> >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> > <label for="fee_limit">Fee limit: </label> >- <input type="text" value="[% restriction.fee_limit | html %]" inputmode="decimal" pattern="^\d+(\.\d{2})?$" min="0" name="fee_limit" id="fee_limit" /> >- </li> >- [% ELSE %] >- <li> >+ </div> >+ <div class="fg-input"> >+ <input type="text" value="[% restriction.fee_limit | html %]" inputmode="decimal" pattern="^\d+(\.\d{2})?$" name="fee_limit" id="fee_limit" /> >+ </div> >+ </div> >+ [% ELSE %] >+ <div class="fg-row input-md"> >+ <div class="fg-label"> > <label for="code" class="required">Code: </label> >- <input type="text" name="code" id="code" size="50" maxlength="50" class="focus required type_input " required="required" /> >- <span class="required">Required</span> >- </li> >- <li> >+ </div> >+ <div class="fg-input"> >+ <input type="text" name="code" id="code" maxlength="50" class="focus required type_input " required="required" /> >+ </div> >+ <div class="required">Required</div> >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> > <label for="display_text" class="required">Label: </label> >- <input type="text" name="display_text" id="display_text" size="50" maxlength="50" class="required" required="required" /> >- <span class="required">Required</span> >- </li> >- <li> >+ </div> >+ <div class="fg-input"> >+ <input type="text" name="display_text" id="display_text" maxlength="50" class="required" required="required" /> >+ </div> >+ <div class="required">Required</div> >+ </div> >+ <div class="fg-row input-sm"> >+ <div class="fg-label"> > <label for="lift_after_payment">Lift after payment: </label> >- <select type="text" name="lift_after_payment" id="lift_after_payment"> >+ </div> >+ <div class="fg-input"> >+ <select name="lift_after_payment" id="lift_after_payment"> > <option value="0" selected="selected">No</option> > <option value="1">Yes</option> > </select> >- </li> >- <li> >+ </div> >+ </div> >+ <div class="fg-row"> >+ <div class="fg-label"> > <label for="fee_limit">Fee limit: </label> >- <input type="text" inputmode="decimal" pattern="^\d+(\.\d{2})?$" min="0" name="fee_limit" id="fee_limit" /> >- </li> >- [% END %] >- </ol> >+ </div> >+ <div class="fg-input"> >+ <input type="text" inputmode="decimal" pattern="^\d+(\.\d{2})?$" name="fee_limit" id="fee_limit" /> >+ </div> >+ </div> >+ [% END %] > </fieldset> > > <fieldset class="action"> >@@ -249,7 +280,7 @@ > //Require fee limit if "Lift after payment" is set true > $("#lift_after_payment").on("change", function(){ > if($(this).val() == 1){ >- $("#fee_limit").prop("required",true).after('<span class="required">Required</span>'); >+ $divee_limit").prop("required",true).after('<span class="required">Required</div>'); > } else { > $("#fee_limit").prop("required",false).nextAll().remove(); > } >-- >2.39.5
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 41841
: 193023