fetch lineitems in substream since they are so large
authorerickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Mon, 20 Apr 2009 18:32:57 +0000 (18:32 +0000)
committererickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Mon, 20 Apr 2009 18:32:57 +0000 (18:32 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@12921 dcc99617-32d9-48b4-a31d-7c20da2025e4

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

index 7d0fc98..262ddbd 100644 (file)
@@ -613,13 +613,13 @@ sub delete_picklist {
     $picklist = $mgr->editor->retrieve_acq_picklist($picklist) unless ref $picklist;
 
     # delete all 'new' lineitems
-    my $lis = $mgr->editor->search_acq_lineitem({picklist => $picklist->id, state => 'new'});
+    my $lis = $mgr->editor->search_acq_lineitem({picklist => $picklist->id, state => 'new'}, {substream => 1});
     for my $li (@$lis) {
         return 0 unless delete_lineitem($mgr, $li);
     }
 
     # detach all non-'new' lineitems
-    $lis = $mgr->editor->search_acq_lineitem({picklist => $picklist->id, state => {'!=' => 'new'}});
+    $lis = $mgr->editor->search_acq_lineitem({picklist => $picklist->id, state => {'!=' => 'new'}, {substream => 1}});
     for my $li (@$lis) {
         $li->clear_picklist;
         return 0 unless update_lineitem($mgr, $li);