From ecc2a8b1d07a61eb917cb0dca553ee5b8b424f94 Mon Sep 17 00:00:00 2001 From: Jeff Davis Date: Wed, 19 Feb 2020 12:36:30 -0800 Subject: [PATCH] LP#1774268: handle opac.hold_notify empty string in AngJS patron editor If a patron does not want either phone or email hold notifications, their opac.hold_notify user setting will be an empty string. Let's ensure that the hold notify checkboxes remain unchecked in the patron editor when that is the case. Signed-off-by: Jeff Davis Signed-off-by: Michele Morgan Signed-off-by: Jason Boyer --- Open-ILS/web/js/ui/default/staff/circ/patron/regctl.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Open-ILS/web/js/ui/default/staff/circ/patron/regctl.js b/Open-ILS/web/js/ui/default/staff/circ/patron/regctl.js index 4c299334b4..6da1de9622 100644 --- a/Open-ILS/web/js/ui/default/staff/circ/patron/regctl.js +++ b/Open-ILS/web/js/ui/default/staff/circ/patron/regctl.js @@ -1912,6 +1912,11 @@ function($scope , $routeParams , $q , $uibModal , $window , egCore , function extract_hold_notify() { var p = $scope.patron; var notify = $scope.user_settings['opac.hold_notify']; + if (notify === '') { + $scope.hold_notify_type.phone = false; + $scope.hold_notify_type.email = false; + return; + } if (!notify) { $scope.hold_notify_type.phone = true; $scope.hold_notify_type.email = true; -- 2.11.0