allow caller to define the sort field/direction in PL retrieval call. by default...
authorerickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 21 May 2010 13:02:19 +0000 (13:02 +0000)
committererickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 21 May 2010 13:02:19 +0000 (13:02 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@16468 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/src/perlmods/OpenILS/Application/Acq/Picklist.pm

index fb7e72e..34b61a6 100644 (file)
@@ -198,10 +198,10 @@ sub retrieve_user_picklist {
     # don't grab the PL with name == "", because that is the designated temporary picklist
     my $list = $e->search_acq_picklist([
             {
-                owner=>$e->requestor->id, 
-                name=>{'!='=>''}
+                owner => $e->requestor->id, 
+                name => {'!=' => ''}
             }, {
-                order_by => {acqpl => 'name'},
+                order_by => $$options{order_by} || {acqpl => 'edit_time DESC'},
                 limit => $$options{limit} || 10,
                 offset => $$options{offset} || 0,
             }