The hold queue report shows collection code but not item type. This
patch adds it. Also added is use of the KohaAuthorisedValues template
plugin to display the collection code description instead of code.
To test, apply the patch and view the holds queue. There should be a new
item type column showing an item type description for each row. The
collection column should now show the collection description instead of
code.
Signed-off-by: Melia Meggs <melia@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
my $dbh = C4::Context->dbh;
my @bind_params = ();
my $dbh = C4::Context->dbh;
my @bind_params = ();
- my $query = q/SELECT tmp_holdsqueue.*, biblio.author, items.ccode, items.location, items.enumchron, items.cn_sort, biblioitems.publishercode,biblio.copyrightdate,biblioitems.publicationyear,biblioitems.pages,biblioitems.size,biblioitems.publicationyear,biblioitems.isbn,items.copynumber
+ my $query = q/SELECT tmp_holdsqueue.*, biblio.author, items.ccode, items.itype, items.location, items.enumchron, items.cn_sort, biblioitems.publishercode,biblio.copyrightdate,biblioitems.publicationyear,biblioitems.pages,biblioitems.size,biblioitems.publicationyear,biblioitems.isbn,items.copynumber
FROM tmp_holdsqueue
JOIN biblio USING (biblionumber)
LEFT JOIN biblioitems USING (biblionumber)
FROM tmp_holdsqueue
JOIN biblio USING (biblionumber)
LEFT JOIN biblioitems USING (biblionumber)
+[% USE ItemTypes %]
+[% USE KohaAuthorisedValues %]
[% INCLUDE 'doc-head-open.inc' %]
<title>Koha › Circulation › Holds queue</title>
[% INCLUDE 'doc-head-close.inc' %]
[% INCLUDE 'doc-head-open.inc' %]
<title>Koha › Circulation › Holds queue</title>
[% INCLUDE 'doc-head-close.inc' %]
<script type="text/javascript">//<![CDATA[
$(document).ready(function() {
$("#holdst").dataTable({
<script type="text/javascript">//<![CDATA[
$(document).ready(function() {
$("#holdst").dataTable({
- "aaSorting": [[ 2, "asc" ]],
+ "aaSorting": [[ 3, "asc" ]],
"bPaginate": false,
"bLengthChange": false,
"bFilter": false,
"bPaginate": false,
"bLengthChange": false,
"bFilter": false,
<tr>
<th class="hq-title">Title</th>
<th class="hq-collection">Collection</th>
<tr>
<th class="hq-title">Title</th>
<th class="hq-collection">Collection</th>
+ <th class="hq-itemtype">Item type</th>
<th class="hq-callnumber">Call number</th>
<th class="hq-copynumber">Copy number</th>
<th class="hq-enumchron">Enumeration</th>
<th class="hq-callnumber">Call number</th>
<th class="hq-copynumber">Copy number</th>
<th class="hq-enumchron">Enumeration</th>
[% IF ( itemsloo.size ) %][% itemsloo.size %][% END %] [% IF ( itemsloo.isbn ) %]ISBN: [% itemsloo.isbn %][% END %]</p>
</div>
</td>
[% IF ( itemsloo.size ) %][% itemsloo.size %][% END %] [% IF ( itemsloo.isbn ) %]ISBN: [% itemsloo.isbn %][% END %]</p>
</div>
</td>
- <td class="hq-collection">[% itemsloo.ccode %]</td>
+ <td class="hq-collection">[% KohaAuthorisedValues.GetByCode( 'CCODE', itemsloo.ccode ) %]</td>
+ <td class="hq-itemtype">[% ItemTypes.GetDescription( itemsloo.itype ) %]</td>
<td class="hq-callnumber">[% itemsloo.location %] [% itemsloo.itemcallnumber %]</td>
<td class="hq-copynumber">[% itemsloo.copynumber %]</td>
<td class="hq-enumchron">[% itemsloo.enumchron %]</td>
<td class="hq-callnumber">[% itemsloo.location %] [% itemsloo.itemcallnumber %]</td>
<td class="hq-copynumber">[% itemsloo.copynumber %]</td>
<td class="hq-enumchron">[% itemsloo.enumchron %]</td>