alert the user when the OPAC's Quick Search->Item Barcode function returns a pre...
authorJason Etheridge <jason@esilibrary.com>
Tue, 12 Jul 2011 18:36:37 +0000 (14:36 -0400)
committerGalen Charlton <gmc@esilibrary.com>
Tue, 12 Jul 2011 21:34:42 +0000 (17:34 -0400)
Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Open-ILS/web/opac/locale/en-US/opac.dtd
Open-ILS/web/opac/skin/default/js/advanced.js
Open-ILS/web/opac/skin/default/xml/common/sidebar.xml

index bdaf91c..6d71f51 100644 (file)
@@ -412,6 +412,7 @@ Please see a librarian to renew your account.">
 <!ENTITY sidebar.relevantReviews.headerLabel "Reviews">
 <!ENTITY sidebar.quick.search "Quick Search">
 <!ENTITY sidebar.copy.not.found "No copy with the requested barcode was found">
+<!ENTITY sidebar.copy.not.cataloged "The copy with the requested barcode is not cataloged">
 
 <!--   ================================================================= 
                Search formats
index 0e898e4..0df0d37 100644 (file)
@@ -162,6 +162,11 @@ function advDrawBarcode(r) {
         return;
     }
     if(!title_ids) return;
+    if (title_ids[0] == -1) { // pre-cat record
+        alertId('myopac.copy.not.cataloged');
+        return;
+    }
+
     var args = {};
     if (title_ids.length == 1) {
         args.page = RDETAIL;
index 39c0a94..f1f4d36 100644 (file)
                        </div>
 
             <span class='hide_me' id='myopac.copy.not.found'>&sidebar.copy.not.found;</span>
+            <span class='hide_me' id='myopac.copy.not.cataloged'>&sidebar.copy.not.cataloged;</span>
                        <div style='margin-top: 8px;' class='adv_quick_search_submit'>
                                <a id='adv_quick_submit' href='javascript:advGenericSearch();' class='classic_link'>&common.submit;</a>
                        </div>