From 3c971d96cadc7c22ded11df08876ab3181afa41e Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Tue, 6 May 2025 13:55:01 +0000 Subject: [PATCH] Bug 39843: Use select2 for multiple selects on patron attributes and extend due dates pages This patch adds Select2 functionality to the select[multiple] fields on the patron attributes and batch extend due dates pages. To test, apply the patch and go to Administration -> Patron attribute types. - Create or edit a patron attribute type. - Test the "Library limitation" field: Selecting a single or multiple library and clearing selections. - Save your changes and confirm that your selections were saved correctly. - Perform the same test on Tools -> Batch extend due dates: - Test the patron categories, item types, and libraries fields. Sponsored-by: Athens County Public Libraries Signed-off-by: David Nind Signed-off-by: Martin Renvoize --- .../prog/en/modules/admin/patron-attr-types.tt | 10 +++++++--- .../prog/en/modules/tools/batch_extend_due_dates.tt | 6 +++++- 2 files changed, 12 insertions(+), 4 deletions(-) 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 985bf597133..56ab6a79b98 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 @@ -235,12 +235,12 @@ >
  • - [% PROCESS options_for_libraries libraries => Branches.all( selected => attribute_type.library_limits ) %] -
    Select "All libraries" if this attribute type should always be displayed. Otherwise select libraries you want to associate with this value.
    +
    Limits the use of this attribute to the selected libraries.
  • @@ -406,6 +406,7 @@ [% MACRO jsinclude BLOCK %] [% Asset.js("js/admin-menu.js") | $raw %] [% INCLUDE 'datatables.inc' %] + [% INCLUDE 'select2.inc' %] [% END %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/batch_extend_due_dates.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/batch_extend_due_dates.tt index e2fe82ee1a6..e975b761323 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/batch_extend_due_dates.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/batch_extend_due_dates.tt @@ -87,7 +87,7 @@ Checkout criteria:
    1. - + [% SET categories = Categories.all() %]