Owen Leonard
bfaf07b278
The return column sort was not using the right sort algorithm because it was confused by the combination of date data and text data ("Checked out"). I've added an explicit instruction to sort by date. The downside to this change is that checked out items are sorted with the oldest checkouts rather than the newest: Checked Out Checked Out 10/14/1988 07/14/2005 Not perfect, but an improvement over completely incorrect sorting. This patch also adds the necessary check for system dateformat preference to properly sort metric dates. Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com> Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
90 lines
2.9 KiB
Text
90 lines
2.9 KiB
Text
[% INCLUDE 'doc-head-open.inc' %]
|
|
<title>Circulation History for [% firstname %] [% surname %]</title>
|
|
[% INCLUDE 'doc-head-close.inc' %]
|
|
<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.min.js"></script>
|
|
<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.pager.js"></script>
|
|
<script type="text/javascript" id="js">$(document).ready(function() {
|
|
$.tablesorter.addParser({
|
|
id: 'articles',
|
|
is: function(s) {return false; },
|
|
format: function(s) { return s.toLowerCase().replace(/^(the|an|a) /,''); },
|
|
type: 'text'
|
|
});
|
|
$.tablesorter.defaults.widgets = ['zebra'];
|
|
$("#table_readingrec").tablesorter({[% IF ( dateformat_metric ) %]
|
|
dateFormat: 'uk',[% END %]
|
|
sortList: [[8,1]],
|
|
headers: { 1: { sorter: 'articles' }, 9: { sorter: 'shortDate'} }
|
|
}).tablesorterPager({container: $("#pagertable_readingrec"),positionFixed: false,size: 20});
|
|
}); </script>
|
|
</head>
|
|
<body>
|
|
[% INCLUDE 'header.inc' %]
|
|
[% INCLUDE 'patron-search.inc' %]
|
|
|
|
<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/members/members-home.pl">Patrons</a> › Circulation History for [% firstname %] [% surname %]</div>
|
|
|
|
<div id="doc3" class="yui-t2">
|
|
|
|
<div id="bd">
|
|
<div id="yui-main">
|
|
<div class="yui-b">
|
|
[% INCLUDE 'circ-toolbar.inc' %]
|
|
<h1>Circulation History</h1>
|
|
<form action="/cgi-bin/koha/members/readingrec.pl" method="get"><input type="hidden" name="borrowernumber" id="borrowernumber" value="[% borrowernumber %]" /></form>
|
|
|
|
<div id="pagertable_readingrec">
|
|
[% INCLUDE 'table-pager.inc' perpage='20' %]
|
|
</div>
|
|
<table id="table_readingrec">
|
|
<thead>
|
|
<th>Date</th>
|
|
<th>Title</th>
|
|
<th>Author</th>
|
|
<th>Call No.</th>
|
|
<th>Barcode</th>
|
|
<th>Number of Renewals</th>
|
|
<th>Checked out on</th>
|
|
<th>Checked out from</th>
|
|
<th>Date Due</th>
|
|
<th>Return Date</th>
|
|
</thead>
|
|
[% FOREACH loop_readin IN loop_reading %]
|
|
[% IF ( loop_readin.returndate ) %]<tr>[% ELSE %]<tr class="onissue">[% END %]
|
|
<td>
|
|
[% loop_readin.issuestimestamp %]
|
|
</td>
|
|
<td><a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% loop_readin.biblionumber %]">[% loop_readin.title |html %]</a></td>
|
|
|
|
<td>[% loop_readin.author %]</td>
|
|
|
|
<td>[% loop_readin.classification %]</td>
|
|
|
|
<td>[% loop_readin.barcode %]</td>
|
|
|
|
<td>
|
|
[% loop_readin.renewals %]</td>
|
|
<td>
|
|
[% loop_readin.issuedate %]</td>
|
|
<td>
|
|
[% loop_readin.issuingbranch %]</td>
|
|
<td>[% IF ( loop_readin.date_due ) %][% loop_readin.date_due %][% ELSE %] [% END %]</td>
|
|
<td>
|
|
[% IF ( loop_readin.returndate ) %]
|
|
[% loop_readin.returndate %]
|
|
[% ELSE %]
|
|
Checked Out
|
|
[% END %]
|
|
</td>
|
|
</tr>
|
|
[% END %]
|
|
</table>
|
|
|
|
</div>
|
|
</div>
|
|
|
|
<div class="yui-b">
|
|
[% INCLUDE 'circ-menu.inc' %]
|
|
</div>
|
|
</div>
|
|
[% INCLUDE 'intranet-bottom.inc' %]
|