Bug 14753 - Use columns configuration for checkins table

This patch adds the ability to configrue the visible columns on the
check in screen.

To test with both patches:
1 - Check in an item
2 - Note there is no 'Date acquired' column
3 - Apply  patches
4 - Note there is still no 'Date acquired' column
5 - Note that there is now a "Show / hide columns" button
6 - Verify that you can check the box and view the 'Date acquired'
column
7 - Verify that showing/hiding columns works (it will not carry over
        between items due to page reload)
8 - Verify that changes from the 'Configure columns' section of
Administration hold between checkins

Sponsored by: North Central Regional Library (ncrl.org)

Signed-off-by: Marc Véron <veron@veron.ch>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
This commit is contained in:
Nick Clemens 2016-02-10 00:54:26 +00:00 committed by Brendan Gallagher
parent 39e61f56ae
commit eb3b68b7a4
2 changed files with 40 additions and 2 deletions

View File

@ -317,6 +317,33 @@ modules:
cannot_be_toggled: 1
cannot_be_modified: 1
checkedintable:
-
columnname: due_date
-
columnname: title
-
columnname: author
-
columnname: barcode
-
columnname: homelibrary
-
columnname: holdinglibrary
-
columnname: location
-
columnname: itemcallnumber
-
columnname: dateaccessioned
is_hidden: 1
-
columnname: itype
-
columnname: borrower
-
columnname: itemnote
view_holdsqueue:
holds-table:
-

View File

@ -4,11 +4,14 @@
[% USE Borrowers %]
[% USE ItemTypes %]
[% USE AuthorisedValues %]
[% USE ColumnsSettings %]
[% INCLUDE 'doc-head-open.inc' %]
<title>Koha &rsaquo; Circulation &rsaquo; Check in [% title |html %]</title>
<link rel="stylesheet" type="text/css" href="[% themelang %]/css/datatables.css" />
[% INCLUDE 'doc-head-close.inc' %]
[% INCLUDE 'datatables.inc' %]
[% INCLUDE 'columns_settings.inc' %]
[% INCLUDE 'calendar.inc' %]
<script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery-ui-timepicker-addon.min.js"></script>
[% INCLUDE 'timepicker.inc' %]
@ -25,6 +28,14 @@ $(document).ready(function () {
Dopop('hold-transfer-slip.pl?borrowernumber=[% borrowernumber %]&amp;biblionumber=[% biblionumber %]');
[% END %]
var columns_settings = [% ColumnsSettings.GetColumns( 'circ', 'circulation', 'checkedintable', 'json' ) %]
var returns_table = KohaTable("#checkedintable", {
"bFilter":false,
"bPaginate":false,
"bInfo":false,
"bSort":false
}, columns_settings);
$("#return_date_override").datetimepicker({
onClose: function(dateText, inst) { $("#barcode").focus(); },
defaultDate: -1,
@ -589,7 +600,7 @@ $(document).ready(function () {
[% IF ( riloop ) %]
<h2>Checked-in items</h2>
<table id="checkedintable">
<tr><th class="ci-duedate">Due date</th><th class="ci-title">Title</th><th class="ci-author">Author</th><th class="ci-barcode">Barcode</th><th class="ci-homelibrary">Home library</th><th class="ci-holdinglibrary">Holding library</th><th class="ci-shelvinglocation">Shelving location</th><th class="ci-callnumber">Call number</th><th class="ci-dateaccessioned">Date acquired</th><th class="ci-type">Type</th><th class="ci-patron">Patron</th><th class="ci-note">Note</th></tr>
<thead><th class="ci-duedate">Due date</th><th class="ci-title">Title</th><th class="ci-author">Author</th><th class="ci-barcode">Barcode</th><th class="ci-homelibrary">Home library</th><th class="ci-holdinglibrary">Holding library</th><th class="ci-shelvinglocation">Shelving location</th><th class="ci-callnumber">Call number</th><th class="ci-dateaccessioned">Date acquired</th><th class="ci-type">Type</th><th class="ci-patron">Patron</th><th class="ci-note">Note</th></thead>
[% FOREACH riloo IN riloop %]
<tr>