From a2897a86dea1e750851f7fe771cd730cc044b8ba Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Tue, 23 Dec 2014 11:59:07 +0100 Subject: [PATCH] Bug 13492: Add the location column to the checkouts tables Test plan: 1/ Verify that the location column is correctly displayed on the checkouts tables (circ/circulation.pl and members/moremember.pl). 2/ Verify that you can hide/show this column (using the admin page and/or the ColVis DT plugin). Signed-off-by: Aleisha Signed-off-by: Kyle M Hall --- admin/columns_settings.yml | 4 ++++ koha-tmpl/intranet-tmpl/prog/en/includes/checkouts-table-footer.inc | 2 +- koha-tmpl/intranet-tmpl/prog/en/includes/checkouts-table.inc | 1 + koha-tmpl/intranet-tmpl/prog/en/js/checkouts.js | 2 ++ svc/checkouts | 2 ++ 5 files changed, 10 insertions(+), 1 deletion(-) diff --git a/admin/columns_settings.yml b/admin/columns_settings.yml index d88dec8..4c6243f 100644 --- a/admin/columns_settings.yml +++ b/admin/columns_settings.yml @@ -168,6 +168,8 @@ modules: - columnname: item_type - + columnname: location + - columnname: checkout_on - columnname: checkout_from @@ -214,6 +216,8 @@ modules: - columnname: item_type - + columnname: location + - columnname: checkout_on - columnname: checkout_from diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/checkouts-table-footer.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/checkouts-table-footer.inc index 549030f..0de211f 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/includes/checkouts-table-footer.inc +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/checkouts-table-footer.inc @@ -1,6 +1,6 @@ - Totals: + Totals: [% totaldue %] [% finetotal %] [% totalprice %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/checkouts-table.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/checkouts-table.inc index dcc0079..7c2e7a9 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/includes/checkouts-table.inc +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/checkouts-table.inc @@ -15,6 +15,7 @@ Due date Title Item type + Location Checked out on Checked out from Call no diff --git a/koha-tmpl/intranet-tmpl/prog/en/js/checkouts.js b/koha-tmpl/intranet-tmpl/prog/en/js/checkouts.js index b626ece..7607aae 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/js/checkouts.js +++ b/koha-tmpl/intranet-tmpl/prog/en/js/checkouts.js @@ -259,6 +259,7 @@ $(document).ready(function() { "sType": "anti-the" }, { "mDataProp": "itemtype_description" }, + { "mDataProp": "location" }, { "mDataProp": "issuedate_formatted" }, { "mDataProp": "branchname" }, { "mDataProp": "itemcallnumber" }, @@ -503,6 +504,7 @@ $(document).ready(function() { "sType": "anti-the" }, { "mDataProp": "itemtype" }, + { "mDataProp": "location" }, { "mDataProp": "issuedate_formatted" }, { "mDataProp": "branchname" }, { "mDataProp": "itemcallnumber" }, diff --git a/svc/checkouts b/svc/checkouts index af373aa..d2eb8ee 100755 --- a/svc/checkouts +++ b/svc/checkouts @@ -94,6 +94,7 @@ my $sql = ' itemlost, damaged, + location, DATEDIFF( issuedate, CURRENT_DATE() ) AS not_issued_today FROM issues @@ -151,6 +152,7 @@ while ( my $c = $sth->fetchrow_hashref() ) { barcode => $c->{barcode}, itemtype => $item_level_itypes ? $c->{itype} : $c->{itemtype}, itemtype_description => $item_level_itypes ? $c->{itype_description} : $c->{itemtype_description}, + location => $c->{location} ? GetAuthorisedValueByCode( 'LOC', $c->{location} ) : q{}, itemnotes => $c->{itemnotes}, branchcode => $c->{branchcode}, branchname => $c->{branchname}, -- 2.1.0