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:33:02 +0000 (17:33 -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 e60841d..f1ea647 100644 (file)
@@ -413,6 +413,7 @@ Please see a librarian to renew your account.">
 <!ENTITY sidebar.quick.search "Quick Search">
 <!ENTITY sidebar.authority.browse "Authority Browse">
 <!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 08e9b22..cd48919 100644 (file)
@@ -183,6 +183,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 4bd6c53..f15fc27 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>