[open-ils-commits] r18958 - branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application (dbs)
svn at svn.open-ils.org
svn at svn.open-ils.org
Fri Dec 10 09:20:25 EST 2010
Author: dbs
Date: 2010-12-10 09:20:24 -0500 (Fri, 10 Dec 2010)
New Revision: 18958
Modified:
branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/SuperCat.pm
Log:
Give the recent_changes list the ability to sort authority records correctly
We were always sorting by bibliographic record entry, which does not
work all that well for authority records.
Modified: branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/SuperCat.pm
===================================================================
--- branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/SuperCat.pm 2010-12-10 05:03:25 UTC (rev 18957)
+++ branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/SuperCat.pm 2010-12-10 14:20:24 UTC (rev 18958)
@@ -1974,8 +1974,13 @@
my $limit = shift;
my $type = 'biblio';
- $type = 'authority' if ($self->api_name =~ /authority/o);
+ my $hint = 'bre';
+ if ($self->api_name =~ /authority/o) {
+ $type = 'authority';
+ $hint = 'are';
+ }
+
my $axis = 'create_date';
$axis = 'edit_date' if ($self->api_name =~ /edit/o);
@@ -1984,7 +1989,7 @@
return $_storage->request(
"open-ils.cstore.direct.$type.record_entry.id_list.atomic",
{ $axis => { ">" => $when }, id => { '>' => 0 } },
- { order_by => { bre => "$axis desc" }, limit => $limit }
+ { order_by => { $hint => "$axis desc" }, limit => $limit }
)->gather(1);
}
More information about the open-ils-commits
mailing list