From fdc06dec2a6e827a5c04c048a0478a2f80d2cd76 Mon Sep 17 00:00:00 2001 From: Julian Maurice Date: Tue, 5 Jan 2016 12:24:57 +0100 Subject: [PATCH] Bug 15471: Add column settings and filters to Holds queue table MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Add column visibility menu using DataTables Buttons Add a text filter on top of each column Also extend page width so that the large table is better centered Depends on bug 15285 Test plan 1. Go to Holds queue page (circ/view_holdsqueue.pl) 2. Check that table sorting and filtering work well and that you can hide each column 3. Go to Admin > Configure columns and change the settings for this table (Circulation > view_holdsqueue > holds-table). Verify that the settings work by going again to the Holds queue page 4. Check that filters continue to work after hiding some columns Tested on top of 15285, works as expected. Signed-off-by: Marc Véron Signed-off-by: Kyle M Hall Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com --- admin/columns_settings.yml | 25 +++++ .../intranet-tmpl/prog/en/css/datatables.css | 4 +- .../prog/en/modules/circ/view_holdsqueue.tt | 95 +++++++++++++++++-- 3 files changed, 113 insertions(+), 11 deletions(-) diff --git a/admin/columns_settings.yml b/admin/columns_settings.yml index a4129868fc..9d1e38ff6d 100644 --- a/admin/columns_settings.yml +++ b/admin/columns_settings.yml @@ -316,3 +316,28 @@ modules: columnname: export cannot_be_toggled: 1 cannot_be_modified: 1 + + view_holdsqueue: + holds-table: + - + columnname: title + - + columnname: collection: + - + columnname: document_type + - + columnname: callnumber + - + columnname: copynumber + - + columnname: enumeration + - + columnname: barcode + - + columnname: patron + - + columnname: send_to + - + columnname: date + - + columnname: notes diff --git a/koha-tmpl/intranet-tmpl/prog/en/css/datatables.css b/koha-tmpl/intranet-tmpl/prog/en/css/datatables.css index 1f9294736d..2912f8c951 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/css/datatables.css +++ b/koha-tmpl/intranet-tmpl/prog/en/css/datatables.css @@ -239,10 +239,10 @@ tr.even.selected td { } /* ColumnFilter */ -span.filter_column > input.text_filter { +span.filter_column > input[type="text"] { font-size: 80%; width: 100%; - padding: 0; + box-sizing: border-box; } /* Row grouping */ diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/view_holdsqueue.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/view_holdsqueue.tt index e419bcd99f..461a8da467 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/view_holdsqueue.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/view_holdsqueue.tt @@ -2,29 +2,49 @@ [% USE ItemTypes %] [% USE Branches %] [% USE AuthorisedValues %] +[% USE ColumnsSettings %] [% INCLUDE 'doc-head-open.inc' %] Koha › Circulation › Holds queue [% INCLUDE 'doc-head-close.inc' %] - - -[% INCLUDE 'header.inc' %] -[% INCLUDE 'cat-search.inc' %] [% INCLUDE 'datatables.inc' %] +[% INCLUDE 'columns_settings.inc' %] + + +[% INCLUDE 'header.inc' %] +[% INCLUDE 'cat-search.inc' %] -
+
@@ -51,7 +71,7 @@ $(document).ready(function() { [% IF ( itemsloop ) %] - + @@ -63,6 +83,63 @@ $(document).ready(function() { + + + + + + + + + + + + + [% FOREACH itemsloo IN itemsloop %] -- 2.39.5
Title Collection Item typeSend to Date Notes
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +