From: miker Date: Fri, 1 Jul 2005 12:40:01 +0000 (+0000) Subject: added "online_loc" to the opensearch results X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=81b14859c429e818eeb3a9aac68dc2393ea470a0;p=Evergreen.git added "online_loc" to the opensearch results git-svn-id: svn://svn.open-ils.org/ILS/trunk@1020 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/src/extras/opensearch.ttk b/Open-ILS/src/extras/opensearch.ttk index 1f5aecf1dc..f45c5fa333 100644 --- a/Open-ILS/src/extras/opensearch.ttk +++ b/Open-ILS/src/extras/opensearch.ttk @@ -105,12 +105,12 @@ FOREACH mr_id IN mr_list; IF mods.author(); -%] <b>Author:</b> <a href="http://gapines.org/opac/?sub_frame=1&target=mr_result&mr_search_type=author&mr_search_query=[% mods.author() | uri | html %]&page=0&mr_search_depth=[% depth %]&mr_search_location=[% location %]">[% mods.author() | html %]</a><br> -[%- +[% END; IF mods.subject(); --%] +%] <b>Subjects:</b> -[%- +[% FOREACH sub IN mods.subject(); IF loop.count() > 3; ', ...'; @@ -119,12 +119,46 @@ FOREACH mr_id IN mr_list; IF loop.index; ', '; END; - -%]<a href="http://gapines.org/opac/?sub_frame=1&target=mr_result&mr_search_type=subject&mr_search_query=[% sub.list.0 | uri | html %]&page=0&mr_search_depth=[% depth %]&mr_search_location=[% location %]">[% sub.list.0 | html %]</a>[%- + -%] +<a href="http://gapines.org/opac/?sub_frame=1&target=mr_result&mr_search_type=subject&mr_search_query=[% sub.list.0 | uri | html %]&page=0&mr_search_depth=[% depth %]&mr_search_location=[% location %]">[% sub.list.0 | html %]</a>[% END; --%]<br> -[%- +%] +<br> + +[% + l = mods.online_loc(); + IF l.size; + '<b>Other Resources:</b>'; + x = l.size / 2; + i = 0; + saw = { 'no' => 'no' }; +%][% + WHILE i <= x; + + h = i * 2; + t = h + 1; + + h = l.list.$h | uri | html; + t = l.list.$t | html; + +%][% + IF saw.exists(t); + i = i + 1; + NEXT; + END + +%][% + saw.$t = t; + + '<a href="' _ h _ '">' _ t _ '</a>&nbsp;'; + + i = i + 1; + END; + '<br>'; + END; + END; --%] +%] <b>Copies Available:</b> [% mr_id.2 %]