From ab666d3a01f644991ef576fb975e28c00222f3f1 Mon Sep 17 00:00:00 2001 From: Lucas Gass Date: Fri, 28 Jan 2022 22:04:21 +0000 Subject: [PATCH] Bug 29972: Make the select a specific item table configurable on opac-reserve.tt To test: 1. Apply patch and restart everything 2. Find a record that was multiple items on it, place a hold on that item. 3. On the "Placing hold" page, click "Show more options" and "A specific item." 4. See that the table can now be sorted by each column, make sure the sorting works 5. Go to Administration > Table settings, and in the OPAC section find reserves_table 6. Try hiding some columns and then do step 3 again. 7. Confirm the columns are properly being hidden. --- admin/columns_settings.yml | 25 ++++++++ .../bootstrap/en/modules/opac-reserve.tt | 63 ++++++++++++------- 2 files changed, 65 insertions(+), 23 deletions(-) diff --git a/admin/columns_settings.yml b/admin/columns_settings.yml index 56bec9ea04..49c37c93e5 100644 --- a/admin/columns_settings.yml +++ b/admin/columns_settings.yml @@ -1469,6 +1469,31 @@ modules: - columnname: notes + reserves_table: + columns: + - + columnname: copy_number + cannot_be_toggled: 1 + cannot_be_modified: 1 + - + columnname: item_type + cannot_be_toggled: 1 + cannot_be_modified: 1 + - + columnname: barcode + - + columnname: home_libray + - + columnname: last_location + - + columnname: collection + - + columnname: call_number + - + columnname: notes + - + columnname: information + subscriptionst: columns: - diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt index 6b65b4c721..84e05557f6 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt @@ -4,10 +4,13 @@ [% USE Price %] [% USE ItemTypes %] [% USE AuthorisedValues %] +[% USE TablesSettings %] [% INCLUDE 'doc-head-open.inc' %] Placing a hold › [% IF ( LibraryNameTitle ) %][% LibraryNameTitle | html %][% ELSE %]Koha online[% END %] catalog [% INCLUDE 'doc-head-close.inc' %] -[% BLOCK cssinclude %][% END %] +[% BLOCK cssinclude %] + [% Asset.css("css/datatables.css") | $raw %] +[% END %] [% INCLUDE 'bodytag.inc' bodyid='opac-holds' %] @@ -345,27 +348,29 @@ [% IF bibitemloo.itemholdable %] - - - [% IF ( item_level_itypes ) %] - - [% END %] - - [% UNLESS ( singleBranchMode ) %] - - - [% END %] - [% IF ( itemdata_ccode ) %] - - [% END %] - - [% IF ( itemdata_enumchron ) %] - - [% END %] - - - - + + + + [% IF ( item_level_itypes ) %] + + [% END %] + + [% UNLESS ( singleBranchMode ) %] + + + [% END %] + [% IF ( itemdata_ccode ) %] + + [% END %] + + [% IF ( itemdata_enumchron ) %] + + [% END %] + + + + + [% FOREACH itemLoo IN bibitemloo.itemLoop %] [% END # / FOREACH itemLoo IN bibitemloo.itemLoop%] +
Select a specific item:
Copy numberItem typeBarcodeHome libraryLast locationCollectionCall numberVol infoNotesInformation
Copy numberItem typeBarcodeHome libraryLast locationCollectionCall numberVol infoNotesInformation
@@ -451,6 +456,7 @@
[% END # / IF ( bibitemloo.itemholdable )%] @@ -471,7 +477,9 @@ [% INCLUDE 'opac-bottom.inc' %] [% BLOCK jsinclude %] -[% INCLUDE 'calendar.inc' %] + [% INCLUDE 'datatables.inc' %] + [% INCLUDE 'columns_settings.inc' %] + [% INCLUDE 'calendar.inc' %]