Owen Leonard
013edd90e3
This patch adds columns configuration to the holds awaiting pickup tables. Doing so helps solve the printing issue by adding a "Print" option to both tables. Using this print function will provide a printable version of only that table. To test you should have multiple holds in your system which are marked "waiting" and some which have been waiting longer than the value specified in the ReservesMaxPickUpDelay system preference. Apply the patch and go to Circulation -> Holds awaiting pickup. - On both the "Holds waiting" and "Holds waiting over..." tabs the DataTable should display correctly and all the controls should work, including the columns settings and the choices in the export menu. - Confirm that the "Print" action creates a printable version of only the table you are viewing. - Go to Administration -> Columns settings -> Circulation. - Change some visibility controls for the tables under the "holds_awaiting_pickup" heading (id=holdso and id=holdst). Confirm that these changes are reflected in the "Holds waiting" interface. Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
155 lines
6.8 KiB
Text
155 lines
6.8 KiB
Text
[% USE raw %]
|
|
[% USE Asset %]
|
|
[% USE Koha %]
|
|
[% USE KohaDates %]
|
|
[% USE Branches %]
|
|
[% USE ColumnsSettings %]
|
|
[% SET footerjs = 1 %]
|
|
[% INCLUDE 'doc-head-open.inc' %]
|
|
<title>Koha › Circulation › Holds awaiting pickup</title>
|
|
[% INCLUDE 'doc-head-close.inc' %]
|
|
</head>
|
|
|
|
<body id="circ_waitingreserves" class="circ">
|
|
[% INCLUDE 'header.inc' %]
|
|
[% INCLUDE 'circ-search.inc' %]
|
|
|
|
<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a>
|
|
› <a href="/cgi-bin/koha/circ/circulation-home.pl">Circulation</a>
|
|
› <a href="/cgi-bin/koha/circ/waitingreserves.pl">Holds awaiting pickup</a>
|
|
</div>
|
|
|
|
<div class="main container-fluid">
|
|
<div class="row">
|
|
<div class="col-sm-12">
|
|
<main>
|
|
<div class="row">
|
|
|
|
[% IF Koha.Preference('CircSidebar') %]
|
|
<div class="col-sm-10 col-sm-push-2">
|
|
[% ELSE %]
|
|
<div class="col-sm-12">
|
|
[% END %]
|
|
|
|
<h2>Holds awaiting pickup for your library on: [% show_date | $KohaDates %]
|
|
[% IF ( all_branches_link ) %]
|
|
<span style="margin-left:20px"><a href="[% all_branches_link | url %]">
|
|
View all libraries</a></span>
|
|
[% END %]
|
|
</h2>
|
|
[% IF ( cancel_result ) %]
|
|
[% FOREACH cancel_result %]
|
|
[% IF ( messagetransfert ) %]
|
|
<div class="dialog message">
|
|
<h2>This item is on hold for pick-up at [% Branches.GetName( branchname ) | html %]</h2>
|
|
<p><strong>[% nextreservtitle | html %]</strong> is on hold for <strong> [% nextreservsurname | html %], [% nextreservfirstname | html %]</strong>.
|
|
Please retain this item and check it in to process the hold.
|
|
</p>
|
|
<form name="cancelReservewithtransfert" action="waitingreserves.pl#[% tab | html %]" method="post">
|
|
<button type="submit" class="approve"><i class="fa fa-fw fa-check"></i> OK</button>
|
|
</form>
|
|
</div>
|
|
[% END %]
|
|
[% IF ( waiting ) %]
|
|
<div class="dialog message">
|
|
<h2>This item is on hold for pick-up at your library</h2>
|
|
<p><strong>[% nextreservtitle | html %]</strong> is on hold for <strong>[% nextreservsurname | html %], [% nextreservfirstname | html %]</strong>.
|
|
Please retain this item and check it in to process the hold.
|
|
</p>
|
|
<form name="cancelReservewithwaiting" action="waitingreserves.pl#[% tab | html %]" method="post">
|
|
<button type="submit" class="approve"><i class="fa fa-fw fa-check"></i> OK</button>
|
|
</form>
|
|
</div>
|
|
[% END %]
|
|
[% END %]
|
|
[% ELSE %]
|
|
<div id="resultlist" class="toptabs">
|
|
<ul>
|
|
<li><a href="#holdswaiting">Holds waiting: [% reservecount | html %]</a></li>
|
|
<li>
|
|
<a href="#holdsover">
|
|
Holds waiting over [% Koha.Preference('ReservesMaxPickUpDelay') | html %] days: [% overcount | html %]
|
|
</a>
|
|
</li>
|
|
</ul>
|
|
<div id="holdswaiting">
|
|
[% IF ( reserveloop ) %]
|
|
[% INCLUDE waiting_holds.inc table_name='holdst' reserveloop=reserveloop tab='holdwaiting' %]
|
|
[% ELSE %]
|
|
<div class="dialog message">No holds found.</div>
|
|
[% END %]
|
|
</div>
|
|
<div id="holdsover">
|
|
[% IF ( ReservesMaxPickUpDelay ) %]<p>Holds listed here have been awaiting pickup for more than [% ReservesMaxPickUpDelay | html %] days.</p>[% END %]
|
|
[% IF ( overloop ) %]
|
|
<span id="holdsover-cancel-all">
|
|
<form name="cancelAllReserve" action="waitingreserves.pl" method="post">
|
|
<input type="hidden" name="cancelall" value="1" />
|
|
<input type="hidden" name="allbranches" value="[% allbranches | html %]" />
|
|
<input type="hidden" name="tab" value="holdsover">
|
|
[% IF TransferWhenCancelAllWaitingHolds %]
|
|
<input type="submit" value="Cancel and Transfer all" />
|
|
[% ELSE %]
|
|
<input type="submit" value="Cancel all" />
|
|
[% END %]
|
|
</form>
|
|
[% UNLESS TransferWhenCancelAllWaitingHolds %]
|
|
Only items that need not be transferred will be cancelled (TransferWhenCancelAllWaitingHolds syspref)
|
|
[% END %]
|
|
</span>
|
|
[% INCLUDE waiting_holds.inc table_name='holdso' reserveloop=overloop tab='holdsover' %]
|
|
[% ELSE %]
|
|
<div class="dialog message">No holds found.</div>
|
|
[% END %]
|
|
</div>
|
|
</div>
|
|
[% END %]
|
|
|
|
[% IF Koha.Preference('CircSidebar') %]
|
|
</div> <!-- /.col-sm-10.col-sm-push-2 -->
|
|
<div class="col-sm-2 col-sm-pull-10">
|
|
<aside>
|
|
[% INCLUDE 'circ-nav.inc' %]
|
|
</aside>
|
|
</div> <!-- /.col-sm-2.col-sm-pull-10 -->
|
|
</div> <!-- /.row -->
|
|
[% END %]
|
|
|
|
</main>
|
|
</div> <!-- /.col-sm-12 -->
|
|
</div> <!-- /.row -->
|
|
|
|
[% MACRO jsinclude BLOCK %]
|
|
[% INCLUDE 'datatables.inc' %]
|
|
[% INCLUDE 'columns_settings.inc' %]
|
|
<script>
|
|
var holdst_columns_settings = [% ColumnsSettings.GetColumns( 'circ', 'holds_awaiting_pickup', 'holdst', 'json' ) | $raw %];
|
|
var holdso_columns_settings = [% ColumnsSettings.GetColumns( 'circ', 'holds_awaiting_pickup', 'holdso', 'json' ) | $raw %];
|
|
|
|
$(document).ready(function() {
|
|
|
|
KohaTable("holdst", {
|
|
"aoColumnDefs": [
|
|
{ "sortable": false, "searchable": false, 'targets': [ 'NoSort' ] },
|
|
{ "type": "anti-the", "targets" : [ "anti-the" ] },
|
|
{ "type": "title-string", "targets" : [ "title-string" ] }
|
|
],
|
|
"sPaginationType": "full"
|
|
}, holdst_columns_settings);
|
|
|
|
KohaTable("holdso", {
|
|
"aoColumnDefs": [
|
|
{ "sortable": false, "searchable": false, 'targets': [ 'NoSort' ] },
|
|
{ "type": "anti-the", "targets" : [ "anti-the" ] },
|
|
{ "type": "title-string", "targets" : [ "title-string" ] }
|
|
],
|
|
"sPaginationType": "full"
|
|
}, holdso_columns_settings);
|
|
|
|
$('#resultlist').tabs();
|
|
|
|
});
|
|
</script>
|
|
[% END %]
|
|
|
|
[% INCLUDE 'intranet-bottom.inc' %]
|