From: Dan Scott Date: Tue, 14 Aug 2012 21:09:55 +0000 (-0400) Subject: TPAC: Display the ISSN in search results X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=dd6f4b6cb3242e97b99b6789cee2629b4f84c225;p=contrib%2FConifer.git TPAC: Display the ISSN in search results Also, do not display URIs from the bib if we have OpenURL results. Signed-off-by: Dan Scott --- diff --git a/Open-ILS/src/templates_conifer/opac/parts/result/table.tt2 b/Open-ILS/src/templates_conifer/opac/parts/result/table.tt2 new file mode 100644 index 0000000000..d5e7cf241a --- /dev/null +++ b/Open-ILS/src/templates_conifer/opac/parts/result/table.tt2 @@ -0,0 +1,297 @@ +[% PROCESS "opac/parts/misc_util.tt2"; + + USE ResolverResolver; + + ctx.result_start = 1 + ctx.page_size * page; + ctx.result_stop = ctx.page_size * (page + 1); + IF ctx.result_stop > ctx.hit_count; ctx.result_stop = ctx.hit_count; END; + + result_count = ctx.result_start; + +%] + +[% PROCESS "opac/parts/result/paginate.tt2" %] +[% ctx.results_count_header = PROCESS results_count_header; + ctx.results_count_header %] + +[% IF ctx.bookbag %] +
+
[% ctx.bookbag.name | html %]
+
[% ctx.bookbag.description | html %]
+
+[% END %] +
+
+ [% INCLUDE "opac/parts/staff_saved_searches.tt2" %] + [% INCLUDE 'opac/parts/result/facets.tt2' %] +
+
+ + + [% FOR rec IN ctx.records; + attrs = {marc_xml => rec.marc_xml}; + PROCESS get_marc_attrs args=attrs; + IF CGI.param('detail_record_view') OR (show_more_details.default == 'true' OR show_more_details.default == 'hide'); + attrs.title = attrs.title_extended; + END; + -%] + + + + + + + + + [%- IF ENV.OILS_CHILIFRESH_ACCOUNT %] + + + + + + + [%- END %] + [% END %] + +
[% + result_count; result_count = result_count + 1 + %]. + [% ident = attrs.isbn_clean || attrs.upc; IF ident; %] + [% l('Image of item') %]
+ [% END %] +
+ +
+
+ [% attrs.author | html %] +    + [% attrs.pubdate | html %] +
+ + [% IF args.holdings.size > 0 %] + + + + + [% END %] + + [% IF CGI.param('detail_record_view') OR (show_more_details.default == 'true' OR show_more_details.default == 'hide') %] + + + [% IF attrs.publisher %] + + + + + [% END %] + [% IF attrs.isbns.size > 0 %] + + + + + [% END %] + [%- IF attrs.issns.size > 0 %] + + + + + [%- END %] + [%- IF openurl.enabled == 'true'; + FOREACH issn IN args.issns; + NEXT IF issn == ''; + res_urls = ResolverResolver.resolve_issn(issn, openurl.baseurl); + FOREACH res IN res_urls; + %] + + + + + [% END %] + [% END %] + [% END %] + + [% IF attrs.edition %] + + + + + [% END %] + [% IF attrs.phys_desc %] + + + + + [% END %] + [%- IF res_urls.size == 0; + FOR uri IN args.uris; + %] + + + + + [%- END; %] + [%- END %] + [%- IF args.holdings.size > 0; + FOREACH copy IN args.holdings; + IF copy.part_label != ''; + has_parts = 'true'; + LAST; + END; + END; + %] + + + + [%- has_parts = 'false'; + END; + %] + [% END %] +
+ [% l('Call number:') %] + [% args.holdings.0.label | html %]
+ [% l('Publisher:') %] + [% attrs.publisher | html %]
+ [% l('ISBN:') %] + [% attrs.isbns.0 | html %]
+ [% l('ISSN:') %] + [% attrs.issns.0 | html %]
+ + [% res.public_name | html %] + [% res.target_coverage | html %]
+ [% l('Edition:') %] + [% attrs.edition | html %]
+ [% l('Phys. Desc.:') %] + + [% args.phys_desc | html %] +
+ [% l('Electronic resource') %] + [% uri.link | html %][% ' - ' _ uri.note | html IF uri.note %]
+ + + + + + [%- IF has_parts == 'true'; %] + + [%- END %] + + + + [% FOR copy IN args.holdings %] + + + + + [%- IF has_parts == 'true'; %] + + [%- END %] + + + [% END %] + +
[% l('Library') %][% l('Shelving location') %][% l('Call number') %][% l('Part') %][% l('Status') %]
[% copy.library | html %][% copy.location | html %][% copy.label | html %][% copy.part_label %][% copy.status | html %]
+
+ [% PROCESS "opac/parts/result/copy_counts.tt2" %] + [% IF rec.user_circulated %] +
+ [% l('Checked Out Before') %] + [% l('I have checked this item out before') %] +
+ [% END %] + [% IF ctx.bookbag; + rec_id = rec.id; + FOR note IN ctx.bookbag_items_by_bre_id.$rec_id.notes %] +
+ [% note.note | html %] +
+ [% END %] + [% END %] +
+
+ + [% IF attrs.format_icon %] + [% attrs.format_label | html %] + [% END %] + + + + + + + [% l("Browse in Google Books Search") %] + + +
+
+[%- search_ou = ctx.search_ou; + num_holdable_copies = attrs.marc_xml.findnodes('//*[local-name()="holdings" and @has_holdable="true"]').size || 0; + IF ctx.place_unfillable || + ( num_holdable_copies > 0 + && (ctx.holds_block.enabled != 'true' || attrs.org_copy_counts.$search_ou.available == 0) + ) +%] + +[%- END -%] +
+ [% IF ctx.user; + INCLUDE "opac/parts/bookbag_actions.tt2"; + %] + [% ELSE; + operation = ctx.mylist.grep(rec.id).size ? "delete" : "add"; + label = (operation == "add") ? l("Add to my list") : l("Remove from my list"); + href = mkurl(ctx.opac_root _ '/mylist/' _ operation, + {record => rec.id, anchor => 'record_' _ rec.id}, 1); + %] + + + [% label %] + + [% END %] +
+ [% IF ENV.OILS_CONTENT_CAFE_USER %] + + [% END %] +
+
+
+ + +
+ + +
+
+
+
+ [% ctx.results_count_header %] +