handle disabling mark overlay button when paging through search results collab/phasefx/web-client-sprint2
authorJason Etheridge <jason@esilibrary.com>
Thu, 13 Aug 2015 15:14:19 +0000 (11:14 -0400)
committerJason Etheridge <jason@esilibrary.com>
Thu, 13 Aug 2015 15:14:19 +0000 (11:14 -0400)
Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Open-ILS/web/js/ui/default/staff/cat/catalog/app.js

index ebbd8eb..5fc17f6 100644 (file)
@@ -209,6 +209,12 @@ function($scope , $routeParams , $location , $window , $q , egCore , egHolds , e
             $scope.record_id = match[1];
             egCore.hatch.setLocalItem("eg.cat.last_record_retrieved", $scope.record_id);
             $scope.holdings_record_id_changed($scope.record_id);
+            // FIXME -- we could add a permission check here
+            if ($scope.record_id == egCore.hatch.getLocalItem('eg.cat.marked_overlay_record')) {
+                $scope.disable_mark_for_overlay = true;
+            } else {
+                $scope.disable_mark_for_overlay = false;
+            }
             init_parts_url();
         } else {
             delete $scope.record_id;