LP#1519925 - Allow MARC Federated Search to search UPC index of local catalog.
authorJosh Stompro <stomproj@larl.org>
Wed, 25 Nov 2015 19:36:08 +0000 (13:36 -0600)
committerJason Stephenson <jstephenson@mvlc.org>
Mon, 30 Nov 2015 19:47:16 +0000 (14:47 -0500)
If a organization added UPC search for certain Z39.50 servers then the UPC search box
would display in the MARC Federated Search interface, but the local catalog would
not be searched.  This adds the ability to search the local catalog "Evergreen Catalog"
UPC index from that interface.

Confirm the Issue:

1. To trigger the initial problem you need a Z39.50 server setup that includes a UPC
Search.  For OCLC the following Z39.50 attributes add UPC searching.
Name:upc, Label:UPC, Code:1007, Format:4, Truncation:0

2. Now the MARC Federated Search should include a UPC search option.  Try searching
for a UPC that exists in the local catalog.  Nothing should come up.

After patch applied:

1. Now if you search for a UPC in the MARC Federated Search that you know exists,
it will show up.

Signed-off-by: Josh Stompro <stomproj@larl.org>
Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>

Open-ILS/src/perlmods/lib/OpenILS/Application/Search/Biblio.pm
Open-ILS/src/perlmods/lib/OpenILS/Application/Search/Z3950.pm

index 8de593b..777ef7e 100644 (file)
@@ -1002,6 +1002,7 @@ sub cat_search_z_style_wrapper {
     $$searchhash{searches}{keyword}{term} = $$args{search}{keyword} if $$args{search}{keyword};
     $$searchhash{searches}{'identifier|isbn'}{term} = $$args{search}{isbn} if $$args{search}{isbn};
     $$searchhash{searches}{'identifier|issn'}{term} = $$args{search}{issn} if $$args{search}{issn};
+    $$searchhash{searches}{'identifier|upc'}{term} = $$args{search}{upc} if $$args{search}{upc};
 
     $$searchhash{searches}{keyword}{term} .= join ' ', $$searchhash{searches}{keyword}{term}, $$args{search}{tcn}       if $$args{search}{tcn};
     $$searchhash{searches}{keyword}{term} .= join ' ', $$searchhash{searches}{keyword}{term}, $$args{search}{publisher} if $$args{search}{publisher};
index a5a4f6c..cff8c6f 100644 (file)
@@ -194,6 +194,7 @@ sub fetch_service_defs {
             publisher => {code => 'publisher', label => 'Publisher'},
             pubdate => {code => 'pubdate', label => 'Pub Date'},
             item_type => {code => 'item_type', label => 'Item Type'},
+            upc => {code => 'upc', label => 'UPC'},
         }
     };