From f9dc8d5e4211ecb4029e443317e060b0c5508533 Mon Sep 17 00:00:00 2001 From: Mike Rylander Date: Wed, 14 Jan 2015 14:15:25 -0500 Subject: [PATCH] Save the record we land on from within the staff client as the "last record retrieved" Signed-off-by: Mike Rylander --- Open-ILS/web/js/ui/default/staff/cat/catalog/app.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Open-ILS/web/js/ui/default/staff/cat/catalog/app.js b/Open-ILS/web/js/ui/default/staff/cat/catalog/app.js index 9b466a93ee..9e9ad7d423 100644 --- a/Open-ILS/web/js/ui/default/staff/cat/catalog/app.js +++ b/Open-ILS/web/js/ui/default/staff/cat/catalog/app.js @@ -51,6 +51,10 @@ function($scope , $routeParams , $location , $q , egCore , egHolds, // set record ID on page load if available... $scope.record_id = $routeParams.record_id; + // Set the "last bib" cookie, if we have that + if ($scope.record_id) + egCore.hatch.setLocalItem("eg.cat.last_record_retrieved", $scope.record_id); + // also set it when the iframe changes to a new record $scope.handle_page = function(url) { @@ -62,6 +66,7 @@ function($scope , $routeParams , $location , $q , egCore , egHolds, var match = url.match(/\/+opac\/+record\/+(\d+)/); if (match) { $scope.record_id = match[1]; + egCore.hatch.setLocalItem("eg.cat.last_record_retrieved", $scope.record_id); // force the record_id to show up in the page. // not sure why a $digest isn't occuring here. -- 2.11.0