The fix to bug 6600 changed the default sort order of the items display - it used to order by home branch and now it orders by holding branch, a source of confusion for our libraries. There are a couple of ways to fix this problem - 1. tablesort items and set the default sort 2. change the default ORDER BY in Items.pm I have a patch for 2, but am worried about ramifications of that change. 1 might cause problems for bibs with many items. What do you think, which is better?
Created attachment 6450 [details] [review] Bug 7271 - change sort in items.pm to sort by home library instead of holding branch
As Ian reports in but 6600 - GetItemsInfo is used in the following scripts: ./C4/XSLT.pm ./C4/Reserves.pm ./reports/reservereport.pl ./labels/label-item-search.pl ./virtualshelves/sendshelf.pl ./catalogue/moredetail.pl ./catalogue/detailprint.pl ./catalogue/detail.pl ./basket/basket.pl ./basket/sendbasket.pl ./serials/routing-preview.pl ./misc/migration_tools/rebuild_zebra.pl ./opac/opac-reserve.pl ./opac/opac-sendbasket.pl ./opac/opac-detail.pl ./opac/opac-ISBDdetail.pl ./opac/opac-sendshelf.pl So it seems reasonable that one should check all of these places during testing - I admit that I have not *yet* made it through this whole list, but I wanted to get the patch out for further review and/or "that's a terrible idea don't do that!" This does fix a micro-regression in that the sorting of items was different/confusing after the patch for bug 6600, and also preserves the functionality of 6600. I am sure that QA will have an opinion on this one.
Isn't this the kind of thing that should be a preference? Some library asked for it to sort the way it does, so changing it on them would probably upset them. Just a thought. Nicole
No, actually the sort here isn't intentional - this is a regression.
that is to say - it puts it back the way it was before the patch that changed the sort - the change to the sort was an unintended side effect of another patch.
Created attachment 7998 [details] [review] Bug 7271 - change sort in items.pm to sort by home library instead of holding branch Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Fixes a regression.
JOINS with 'branches' table twice, once for home and once for holding, and elegantly distinguishes the two. Marking as Passed QA.
This bug will be included in the Koha 3.6.5 release.