Bug 10856: (follow-up) if callnumbers are equal, order should be on itemnumber

If a lot of items has the same callnumber, the order should be on the
itemnumbers. Otherwise the left side is always filled with the same
items.

+ Fix a bad c/p for the next link (when js is disabled).

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This commit is contained in:
Jonathan Druart 2013-09-13 09:55:51 +02:00 committed by Galen Charlton
parent 5c0fa5ec3d
commit 84494966d4
2 changed files with 2 additions and 2 deletions

View File

@ -171,7 +171,7 @@ sub GetNearbyItems {
my @prev_items = @{
$dbh->selectall_arrayref(
$prev_query . $query_cond . ' ORDER BY cn_sort DESC, itemnumber LIMIT ?',
$prev_query . $query_cond . ' ORDER BY cn_sort DESC, itemnumber DESC LIMIT ?',
{ Slice => {} },
( @params, $gap )
)

View File

@ -67,7 +67,7 @@
<td rowspan="2" style="width:20px;">
[% IF shelfbrowser_next_item %]
<div id="browser_next">
<a href="/cgi-bin/koha/opac-detail.pl?biblionumber=[% shelfbrowser_prev_item.biblionumber %]&amp;shelfbrowse_itemnumber=[% shelfbrowser_prev_item.itemnumber %]#shelfbrowser">Next</a>
<a href="/cgi-bin/koha/opac-detail.pl?biblionumber=[% shelfbrowser_next_item.biblionumber %]&amp;shelfbrowse_itemnumber=[% shelfbrowser_next_item.itemnumber %]#shelfbrowser">Next</a>
</div>
[% END %]
</td>