1 [% PROCESS "opac/parts/misc_util.tt2";
5 ctx.result_start = 1 + ctx.page_size * page;
6 ctx.result_stop = ctx.page_size * (page + 1);
7 IF ctx.result_stop > ctx.hit_count; ctx.result_stop = ctx.hit_count; END;
9 result_count = ctx.result_start;
13 [% PROCESS "opac/parts/result/paginate.tt2" %]
14 [% ctx.results_count_header = PROCESS results_count_header;
15 ctx.results_count_header %]
17 <div id="result-bookbag-heading">
18 <div class="result-bookbag-name">[% ctx.bookbag.name | html %]</div>
19 <div class="result-bookbag-description">[% ctx.bookbag.description | html %]</div>
22 <div id="result_table_div">
23 <div class="facet_sidebar_hidden" id="facet_sidebar">
24 <h3 class="sr-only">[% l('Saved Searches') %]</h3>
25 [% INCLUDE "opac/parts/staff_saved_searches.tt2" %]
26 <h3 class="sr-only">[% l('Search Results facets') %]</h3>
27 [% INCLUDE 'opac/parts/result/facets.tt2' %]
28 <h3 class="sr-only">[% l('Search Results List') %]</h3>
30 <div id="result_block" class="result_block_visible">
31 <table id="result_table_table" title="[% l('Search Results') %]"
32 class="table_no_border_space table_no_cell_pad">
33 <tbody id="result_table">
34 [% FOR rec IN ctx.records;
35 attrs = {marc_xml => rec.marc_xml};
36 PROCESS get_marc_attrs args=attrs;
37 IF CGI.param('detail_record_view');
38 attrs.title = attrs.title_extended;
41 <tr class="result_table_row">
42 <td class="results_row_count" name="results_row_count">[%
43 result_count; result_count = result_count + 1
45 <td class='result_table_pic_header'>
46 <a href="[% mkurl(ctx.opac_root _ '/record/' _ rec.id) %]"><img alt="[% l('Image of item') %]"
47 name='item_jacket' class='result_table_pic' width="55"
48 src='[% ctx.media_prefix %]/opac/extras/ac/jacket/small/r/[% rec.id | uri %]' /></a><br />
50 <td class='result_table_title_cell' name='result_table_title_cell'>
51 <div class="result_metadata">
52 <abbr class="unapi-id" title='tag:[% ctx.hostname %],[% date.format(date.now, '%Y') %]:biblio-record_entry/[% rec.id %]'></abbr>
53 <a class='record_title search_link' name='record_[% rec.id %]'
54 href="[% mkurl(ctx.opac_root _ '/record/' _ rec.id) %]"
55 [% html_text_attr('title', l('Display record details for "[_1]"', attrs.title)) %]
56 >[% attrs.title | html %]</a>
58 FOR entry IN attrs.graphic_titles;
59 FOR alt IN entry.graphic;
62 diratt = ' dir="' _ alt.dir _ '"';
65 <div class="graphic880"[% diratt %]>
66 [% alt.value | html %]
74 <a title="[% l("Perform an Author Search") %]"
75 class="record_author" name='item_author'
77 authorquery = attrs.author | replace('[#"^$\+\-,\.:;&|\[\]()]', ' ');
78 mkurl(ctx.opac_root _ '/results', {qtype => 'author', query => authorquery}, ['page'])
79 -%]">[% attrs.author | html %]</a>
81 FOR entry IN attrs.graphic_authors;
82 FOR alt IN entry.graphic;
85 diratt = ' dir="' _ alt.dir _ '"';
88 <div class="graphic880"[% diratt %]>
89 [% alt.value | html %]
97 <div class='result_table_title_cell'>
98 [%- IF attrs.format_label; %]
99 <img title="[% attrs.format_label | html %]" alt="[% attrs.format_label | html %]" src="[% attrs.format_icon %]" /> [% attrs.format_label; %]
101 [%- UNLESS CGI.param('detail_record_view')
102 OR (show_more_details.default == 'true'
103 OR show_more_details.default == 'hide');
105 pubdate_clean = attrs.pubdate | html;
106 l(" ([_1])", pubdate_clean);
111 <span name="googleBooksLink" class="hide_me">
112 <a style='padding-left: 8px;'
113 class='classic_link hide_me'
114 name="googleBooks-link">[% l("Browse in Google Books Search") %]</a>
117 title="[% l('Record Holdings Summary') %]"
118 class="table_no_border_space table_no_cell_pad table_no_border results_info_table">
119 [% IF args.holdings.size > 0 %]
120 <tr name='bib_cn_list' class='result_table_title_cell'>
122 <strong>[% l('Call number:') %]</strong>
124 <td>[% args.holdings.0.label | html %]</td>
128 [% IF CGI.param('detail_record_view') %]
129 <!-- These fields are visible when viewing the results page in 'detailed' mode -->
131 [% IF attrs.pubinfo %]
132 <tr name="results_pub_tr">
134 <strong>[% l('Publisher:') %]</strong>
136 <td>[% attrs.pubinfo | html %]
138 FOR entry IN attrs.graphic_pubinfos;
139 FOR alt IN entry.graphic;
142 diratt = ' dir="' _ alt.dir _ '"';
145 <div class="graphic880"[% diratt %]>
146 [% alt.value | html %]
155 [% IF attrs.isbns.size > 0 %]
156 <tr name="results_isbn_tr">
158 <strong>[% l('ISBN:') %]</strong>
160 <td>[% attrs.isbns.0 | html %]</td>
163 [%- IF attrs.issns.size > 0 %]
164 <tr name="results_issn_tr">
166 <strong>[% l('ISSN:') %]</strong>
168 <td>[% attrs.issns.0 | html %]</td>
171 [%- IF openurl.enabled == 'true';
172 FOREACH issn IN args.issns;
174 res_urls = ResolverResolver.resolve_issn(issn, openurl.baseurl);
175 FOREACH res IN res_urls;
177 <tr name="results_issn_tr">
179 <strong><a href="[% res.target_url %]">
180 [% res.public_name | html %]</a></strong>
182 <td>[% res.target_coverage | html %]</td>
188 [% IF attrs.edition %]
189 <tr name="results_edition_tr">
191 <strong>[% l('Edition:') %]</strong>
193 <td>[% attrs.edition | html %]
195 FOR entry IN attrs.graphic_editions;
196 FOR alt IN entry.graphic;
199 diratt = ' dir="' _ alt.dir _ '"';
202 <div class="graphic880"[% diratt %]>
203 [% alt.value | html %]
212 [% IF attrs.phys_desc %]
213 <tr name="results_phys_desc_tr">
214 <td nowrap="nowrap" valign="top">
215 <strong>[% l('Phys. Desc.:') %]</strong>
218 [% args.phys_desc | html %]
222 [% FOR uri IN args.uris %]
223 <tr name='bib_uri_list' class='result_table_title_cell'>
225 <strong>[% l('Electronic resource') %]</strong>
227 <td><a href="[% uri.href %]">[% uri.link | html %]</a>[% ' - ' _ uri.note | html IF uri.note %]</td>
230 [%- IF args.holdings.size > 0;
231 FOREACH copy IN args.holdings;
232 IF copy.part_label != '';
238 <tr name='bib_cn_list' class='result_table_title_cell'>
240 <table title="[% l('Record Holdings Details') %]"
241 class='result_holdings_table'>
243 <th>[% l('Library') %]</th>
244 <th>[% l('Shelving location') %]</th>
245 <th>[% l('Call number') %]</th>
246 [%- IF has_parts == 'true'; %]
247 <th>[% l('Part') %]</th>
249 <th>[% l('Status') %]</th>
252 [% FOR copy IN args.holdings %]
255 [%- copy_info = copy;
256 INCLUDE "opac/parts/library_name_link.tt2"; %]
258 <td>[% copy.location | html %]</td>
259 <td>[% copy.label | html %]</td>
260 [%- IF has_parts == 'true'; %]
261 <td>[% copy.part_label %]</td>
263 <td>[% copy.status | html %]</td>
270 [%- has_parts = 'false';
273 [% END %] <!-- END detail_record_view -->
275 [% PROCESS "opac/parts/result/copy_counts.tt2" %]
276 [% IF rec.user_circulated %]
277 <div class="result_item_circulated">
278 <img src="[% ctx.media_prefix %]/images/green_check.png" alt="[% l('Checked Out Before') %]"/>
279 <span>[% l('I have checked this item out before') %]</span>
284 FOR note IN ctx.bookbag_items_by_bre_id.$rec_id.notes %]
285 <div class="result-bookbag-item-note">
286 [% note.note | html %]
291 <div class="result_table_utils_cont">
292 <div class="result_table_utils">
293 [%- search_ou = ctx.search_ou;
294 num_holdable_copies = attrs.marc_xml.findnodes('//*[local-name()="holdings" and @has_holdable="true"]').size || 0;
295 IF ctx.place_unfillable ||
296 ( num_holdable_copies > 0
297 && (ctx.holds_block.enabled != 'true' || attrs.org_copy_counts.$search_ou.available == 0)
300 <div class="results_aux_utils place_hold"><a
301 href="[% mkurl(ctx.opac_root _ '/place_hold',
302 {hold_target => rec.id, hold_type => 'T', hold_source_page => mkurl()}, ['query']) %]"
303 [% html_text_attr('title', l('Place Hold on [_1]', attrs.title)) %]
304 name="place_hold_link" class="no-dec"><img
305 src="[% ctx.media_prefix %]/images/green_check.png"
306 alt=""/><span class="result_place_hold">[% l('Place Hold') %]</span></a>
309 <div class="results_aux_utils result_util">
311 INCLUDE "opac/parts/bookbag_actions.tt2";
314 operation = ctx.mylist.grep(rec.id).size ? "delete" : "add";
315 label = (operation == "add") ? l("Add to my list") : l("Remove from my list");
316 title_label = (operation == "add") ?
317 l("Add [_1] to my list", attrs.title) :
318 l("Remove [_1] from my list", attrs.title);
319 href = mkurl(ctx.opac_root _ '/mylist/' _ operation,
320 {record => rec.id, anchor => 'record_' _ rec.id}, 1);
322 <a href="[% href %]" class="no-dec"
323 [% html_text_attr('title', title_label) %]>
324 <img src="[% ctx.media_prefix %]/images/clipboard.png" alt="" />
329 [% IF ENV.OILS_CONTENT_CAFE_USER %]
330 [% ident = attrs.isbn_clean || attrs.upc %]
331 <div class="results_aux_utils result_util">
333 [% html_text_attr('title', l('Reviews and More for [_1]', attrs.title)) %]
334 href="[% ctx.ext_proto %]://contentcafe2.btol.com/ContentCafeClient/ContentCafe.aspx?UserID=[%-
335 ENV.OILS_CONTENT_CAFE_USER %]&Password=[%-
336 ENV.OILS_CONTENT_CAFE_PASS %]&ItemKey=[% ident | uri %]&Options=Y">
337 <img src='[% ctx.media_prefix %]/images/starz.png' alt="[% l('Ratings Icon') %]"/>
338 <span class="results_reviews">[% l('Reviews & More') %]</span>
348 [%- IF ENV.OILS_CHILIFRESH_ACCOUNT %]
351 <td align='center'> <!-- Chilifresh reviews link -->
352 <span class="chili_review" id="isbn_[% attrs.isbn_clean | html %]"> </span>
357 <td colspan='5'> <!-- Chilifresh reviews panel -->
358 <div id="chili_review_[% attrs.isbn_clean | html %]" style="display: none;" align="center"></div>
367 <div class="result_footer_nav1">
368 [% ctx.results_count_header %]
371 resultBlock = document.querySelector('#result_block');
372 resultButton = document.querySelector('#return_to_hits');
373 facetSidebar = document.querySelector('#facet_sidebar');
374 facetButton = document.querySelector('#refine_hits');
375 function getFacety() {
376 resultBlock.setAttribute('class', 'result_block_hidden');
377 resultButton.setAttribute('class', 'results_header_btns result_block_visible');
378 facetSidebar.setAttribute('class', 'facet_sidebar_visible');
379 facetButton.setAttribute('class', 'result_block_hidden');
380 window.location.hash = 'return_to_hits';
382 function getResulty() {
383 resultBlock.setAttribute('class', 'result_block_visible');
384 resultButton.setAttribute('class', 'result_block_hidden');
385 facetSidebar.setAttribute('class', 'facet_sidebar_hidden');
386 facetButton.setAttribute('class', 'results_header_btns result_block_visible');
387 window.location.hash = 'refine_hits';