LP#1751126: Make print holds shelf list aware of clear mode.
authorJason Stephenson <jason@sigio.com>
Tue, 10 Apr 2018 14:51:24 +0000 (10:51 -0400)
committerGalen Charlton <gmc@equinoxinitiative.org>
Fri, 25 May 2018 18:35:26 +0000 (14:35 -0400)
We change the Print Full List button on the holds shelf view to be
aware of whether clear mode is active.  If clear mode is active, then
the list of holds to clear is printed.  If not, then the full holds
shelf list is printed.

This commit does not change the label of the print full list button.

Signed-off-by: Jason Stephenson <jason@sigio.com>
Signed-off-by: Dawn Dale <ddale@georgialibraries.org>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>

Open-ILS/web/js/ui/default/staff/circ/holds/app.js

index 8028da5..fc9ea34 100644 (file)
@@ -204,9 +204,12 @@ function($scope , $q , $routeParams , $window , $location , egCore , egHolds , e
         $scope.print_list_progress = 0;
 
         // collect the full list of holds
+        var method = 'open-ils.circ.captured_holds.id_list.on_shelf.retrieve.authoritative.atomic';
+        if (clear_mode)
+            method = 'open-ils.circ.captured_holds.id_list.expired_on_shelf_or_wrong_shelf.retrieve.atomic';
         egCore.net.request(
             'open-ils.circ',
-            'open-ils.circ.captured_holds.id_list.on_shelf.retrieve.authoritative.atomic',
+            method,
             egCore.auth.token(), $scope.pickup_ou.id()
         ).then( function(idlist) {