From: Suzanne Paterno Date: Tue, 6 Aug 2019 15:29:57 +0000 (-0400) Subject: LP 1774268: Default Hold Notification checkboxes X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=ddf5b4b34c9cac881f3ccbf693b191e2b06cf2fc;p=working%2FEvergreen.git LP 1774268: Default Hold Notification checkboxes On patron edit screen set the email and phone notification to true when patron doesn't have any prefernces. This mimics the behavior in the xul client. Signed-off-by: Michele Morgan Signed-off-by: Jason Boyer --- 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 72a9ebd863..f8c5ca7106 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 @@ -1896,8 +1896,12 @@ function($scope , $routeParams , $q , $uibModal , $window , egCore , function extract_hold_notify() { var p = $scope.patron; - var notify = $scope.user_settings['opac.hold_notify'] || ''; - + var notify = $scope.user_settings['opac.hold_notify']; + if (!notify) { + $scope.hold_notify_type.phone = true; + $scope.hold_notify_type.email = true; + return; + } $scope.hold_notify_type.phone = Boolean(notify.match(/phone/)); $scope.hold_notify_type.email = Boolean(notify.match(/email/)); $scope.hold_notify_type.sms = Boolean(notify.match(/sms/));