From a1cfeda380e2ddd1f2de12a73ef616fbdb6a108c Mon Sep 17 00:00:00 2001 From: Dan Scott Date: Tue, 14 Jan 2014 23:46:41 -0500 Subject: [PATCH] Restore OpenSearch support and use TPAC search This enables users to easily add the Evergreen search engine to their browser's built-in set of search engines, and most importantly directs searches to the TPAC instead of the weird old Supercat interface. Signed-off-by: Dan Scott Signed-off-by: Ben Shum --- Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm | 5 +++-- Open-ILS/src/templates/opac/parts/base.tt2 | 1 + 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm index 388822636c..873b956498 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm @@ -1201,6 +1201,7 @@ sub opensearch_osd { my $lib = shift; my $class = shift; my $base = shift; + my $host = shift; if ($version eq '1.0') { print < + template="https://$host/eg/opac/results?locg=$lib;query={searchTerms};page={startPage?};startIndex={startIndex?};count={count?};searchLang={language?}"/> Search $lib Mike Rylander for GPLS/PINES @@ -1301,7 +1302,7 @@ sub opensearch_feed { $class = 'keyword'; } - return opensearch_osd($version, $lib, $class, $base); + return opensearch_osd($version, $lib, $class, $base, $host); } diff --git a/Open-ILS/src/templates/opac/parts/base.tt2 b/Open-ILS/src/templates/opac/parts/base.tt2 index ae44122470..eaed67e386 100644 --- a/Open-ILS/src/templates/opac/parts/base.tt2 +++ b/Open-ILS/src/templates/opac/parts/base.tt2 @@ -13,6 +13,7 @@ [% l('Catalog - [_1]', ctx.page_title) %] + [% IF want_dojo %]