From a92f0ae7d5c1150ffb6e45ff60d6e97fc1a4b38a Mon Sep 17 00:00:00 2001 From: Tomas Cohen Arazi Date: Thu, 29 Apr 2021 08:53:43 -0300 Subject: [PATCH] Bug 28261: Add visual feedback on overridden pickup locations on patron's page This patch makes the patron pages in the staff interface use the API and Select2 to render the pickup locations list. This has the effect of adding visual feedback on those pickup locations that need an override, based on the current configuration options. All the checks are done in the GET /holds/:hold_id/pickup_locations route, so this is a fairly trivial change. To test: 1. Have a couple holds for a patron, some overrriden, some not 2. Visit the patrons' detail page, holds tab. => SUCCESS: You see the holds, pickup location has a dropdown 3. Repeat in the circulation tab for the patron => SUCCESS: You see the holds, pickup location has a dropdown 4. Apply this patch 5. Repeat 2 and 3 => SUCCESS: Same behavior as before, but the dropdown is rendered with Select2 and has a search feature. Overridden pickup locations have an icon telling so 6. Sign off :-D Signed-off-by: Martin Renvoize --- .../prog/en/modules/circ/circulation.tt | 1 + .../prog/en/modules/members/moremember.tt | 1 + koha-tmpl/intranet-tmpl/prog/js/holds.js | 57 ++++++++++++++++++- 3 files changed, 57 insertions(+), 2 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt index fb3abec220..8a689d016e 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt @@ -1171,6 +1171,7 @@ [% INCLUDE 'columns_settings.inc' %] [% Asset.js("lib/jquery/plugins/jquery-ui-timepicker-addon.min.js") | $raw %] [% INCLUDE 'timepicker.inc' %] + [% INCLUDE 'select2.inc' %] [% Asset.js("lib/jquery/plugins/rowGroup/dataTables.rowGroup.min.js") | $raw %]