From: Mike Rylander Date: Thu, 14 Apr 2016 20:07:08 +0000 (-0400) Subject: webstaff: Make alert type selection sticky when an alert is saved X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=df94a022a619ed5bd6e89e97ee9b316d055dc0f4;p=working%2FEvergreen.git webstaff: Make alert type selection sticky when an alert is saved Signed-off-by: Mike Rylander --- diff --git a/Open-ILS/web/js/ui/default/staff/cat/volcopy/app.js b/Open-ILS/web/js/ui/default/staff/cat/volcopy/app.js index 45d0cd71bc..1664541528 100644 --- a/Open-ILS/web/js/ui/default/staff/cat/volcopy/app.js +++ b/Open-ILS/web/js/ui/default/staff/cat/volcopy/app.js @@ -1873,6 +1873,10 @@ function($scope , $q , $window , $routeParams , $location , $timeout , egCore , temp : false }; + egCore.hatch.getItem('cat.copy.alerts.last_type').then(function(t) { + if (t) $scope.copy_alert.alert_type = t; + }); + if (copy_list.length == 1) { $scope.copy_alert_list = copy_list[0].copy_alerts(); } @@ -1896,6 +1900,14 @@ function($scope , $q , $window , $routeParams , $location , $timeout , egCore , ); cp.copy_alerts().push( a ); }); + + if (copy_alert.alert_type) { + egCore.hatch.setItem( + 'cat.copy.alerts.last_type', + copy_alert.alert_type + ); + } + } $modalInstance.close();