[open-ils-commits] [GIT] Evergreen ILS branch master updated. 0d9bccad69ba6f186e2960530884e88a319aaf07

Evergreen Git git at git.evergreen-ils.org
Wed Jan 18 15:11:06 EST 2012


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  0d9bccad69ba6f186e2960530884e88a319aaf07 (commit)
      from  187562184c28f1d8ba25b3a6dae3ce3e8180e997 (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 0d9bccad69ba6f186e2960530884e88a319aaf07
Author: Thomas Berezansky <tsbere at mvlc.org>
Date:   Tue Jan 17 11:13:15 2012 -0500

    Don't show estimated wait for negative estimates
    
    JSPac code was just checking for the truth of the estimated_wait return,
    but the estimated_wait return can be -1 under some circumstances.
    
    Signed-off-by: Thomas Berezansky <tsbere at mvlc.org>
    Signed-off-by: Bill Erickson <berick at esilibrary.com>

diff --git a/Open-ILS/web/opac/skin/default/js/myopac.js b/Open-ILS/web/opac/skin/default/js/myopac.js
index 302f0ec..7f006d2 100644
--- a/Open-ILS/web/opac/skin/default/js/myopac.js
+++ b/Open-ILS/web/opac/skin/default/js/myopac.js
@@ -461,7 +461,8 @@ function myOShowHoldStatus(r) {
 
 	var row = $("myopac_holds_row_" + r.hold.id());
 
-    if(qstats.estimated_wait || myopacShowHoldEstimate) {
+    // A note: estimated_wait may be -1 under some circumstances where it shouldn't be shown.
+    if((qstats.estimated_wait && qstats.estimated_wait > 0) || myopacShowHoldEstimate) {
         myopacShowHoldEstimate = true;
         if(qstats.estimated_wait) {
             // wait is currently returned in seconds, but displayed in days

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

Summary of changes:
 Open-ILS/web/opac/skin/default/js/myopac.js |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)


hooks/post-receive
-- 
Evergreen ILS


More information about the open-ils-commits mailing list