[open-ils-commits] [GIT] Evergreen ILS branch master updated. 6173680e927ddc76081a2c116c0407b71a08b37b

Evergreen Git git at git.evergreen-ils.org
Mon Apr 17 15:53:27 EDT 2017


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Evergreen ILS".

The branch, master has been updated
       via  6173680e927ddc76081a2c116c0407b71a08b37b (commit)
      from  406fe9fcf38278a26858ac4242a848b51bdd75f2 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 6173680e927ddc76081a2c116c0407b71a08b37b
Author: Jason Etheridge <jason at esilibrary.com>
Date:   Mon Apr 17 15:43:43 2017 -0400

    webstaff: sound effects for patron search
    
    Signed-off-by: Jason Etheridge <jason at esilibrary.com>
    Signed-off-by: Mike Rylander <mrylander at gmail.com>

diff --git a/Open-ILS/web/js/ui/default/staff/circ/patron/app.js b/Open-ILS/web/js/ui/default/staff/circ/patron/app.js
index 8a8e326..7f0e0d8 100644
--- a/Open-ILS/web/js/ui/default/staff/circ/patron/app.js
+++ b/Open-ILS/web/js/ui/default/staff/circ/patron/app.js
@@ -989,6 +989,7 @@ function($scope,  $q,  $routeParams,  $timeout,  $window,  $location,  egCore,
         egProgressDialog.open(); // Indeterminate
 
         patronSvc.patrons = [];
+        var which_sound = 'success';
         egCore.net.request(
             'open-ils.actor',
             'open-ils.actor.patron.search.advanced.fleshed',
@@ -1005,7 +1006,9 @@ function($scope,  $q,  $routeParams,  $timeout,  $window,  $location,  egCore,
             function() {
                 deferred.resolve();
             },
-            null, // onerror
+            function() { // onerror
+                which_sound = 'error';
+            },
             function(user) {
                 // hide progress bar as soon as the first result appears.
                 egProgressDialog.close();
@@ -1013,7 +1016,13 @@ function($scope,  $q,  $routeParams,  $timeout,  $window,  $location,  egCore,
                 patronSvc.patrons.push(user);
                 deferred.notify(user);
             }
-        )['finally'](egProgressDialog.close); // close on 0-hits or error
+        )['finally'](function() { // close on 0-hits or error
+            if (which_sound == 'success' && patronSvc.patrons.length == 0) {
+                which_sound = 'warning';
+            }
+            egCore.audio.play(which_sound + '.patron.by_search');
+            egProgressDialog.close();
+        });
 
         return deferred.promise;
     };

-----------------------------------------------------------------------

Summary of changes:
 .../web/js/ui/default/staff/circ/patron/app.js     |   13 +++++++++++--
 1 files changed, 11 insertions(+), 2 deletions(-)


hooks/post-receive
-- 
Evergreen ILS


More information about the open-ils-commits mailing list