]> git.evergreen-ils.org Git - Evergreen.git/blob - Open-ILS/src/templates-bootstrap/opac/parts/result/table.tt2
LP2061136 - Stamping 1405 DB upgrade script
[Evergreen.git] / Open-ILS / src / templates-bootstrap / opac / parts / result / table.tt2
1 [%  PROCESS "opac/parts/misc_util.tt2";
2
3     USE ResolverResolver;
4
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;
8
9     result_count = ctx.result_start;
10
11 %]
12
13 [% IF ctx.bookbag %]
14 <div class="row">
15     <div class="col-12">
16         <h2 class="result-bookbag-name">[% ctx.bookbag.name | html %]</h2>
17         <div class="result-bookbag-description">[% ctx.bookbag.description | html %]</div>
18     </div>
19 </div>
20 [% END %]
21
22 <div class="row">
23     <div class="col-12">
24     [% PROCESS "opac/parts/result/paginate.tt2" %]
25     [% ctx.results_count_header = PROCESS results_count_header;
26         ctx.results_count_header %]
27     </div>
28 </div>
29 <div class="row">
30     <div class="col-xl-2 d-none d-xl-block">
31         [% INCLUDE 'opac/parts/result/facets.tt2' %]
32     </div>
33     <div id="result_table_div" class="border-bottom col-12 col-xl-10 px-3">
34         <div id="result_block" class="result_block_visible">
35             [% IF !ctx.is_meta %]
36             <div id="record_selector_block" class="mx-2 hidden">
37                 <input type="checkbox" id="select_all_records" />
38                 <label for="select_all_records">[% l('Select [_1] - [_2]', ctx.result_start, ctx.result_stop) %]</label>
39                 <span id="selected_records_summary">
40                 <a href="[% mkurl(ctx.opac_root _ '/mylist') %]" class="no-dec" rel="nofollow" vocab="">
41                     <span id="selected_records_count">[% ctx.mylist.size %]
42
43                     </span>
44                             [% l('selected') %]
45                 </a></span>
46                 <span id="hit_selected_record_limit" class="hidden">Reached limit!</span>
47                 <a id="clear_basket" href="#">[% l('Clear basket') %]</a>
48             </div>
49             [% END %]
50
51
52                 [%  FOR rec IN ctx.records;
53                     attrs = {};
54                     attrs.marc_xml = rec.marc_xml;
55                     attrs.mr_constituent_ids = [];
56                         FOREACH mr_constituent_id IN rec.mr_constituent_ids;
57                             attrs.mr_constituent_ids.push(mr_constituent_id);
58                         END;
59                         PROCESS get_marc_attrs args=attrs;
60                         IF show_detail_view;
61                             attrs.title = attrs.title_extended;
62                         END;
63                         # note: rec.id refers to the record identifier, regardless
64                         # of the type of record. i.e. rec.id = mmr_id ? mmr_id : bre_id
65                         IF rec.mmr_id;
66                             IF rec.mr_constituent_count > 1;
67                                 # metarecords link to record list page
68                                 record_url_path = ctx.opac_root _ '/results';
69                                 add_parms = {metarecord => rec.mmr_id};
70                                 del_parms = ['page'];
71                             ELSE;
72                                 # for MR, bre_id refers to the master and in
73                                 # this case, only, record
74                                     record_url_path = ctx.opac_root _ '/record/' _ attrs.mr_constituent_ids.0;
75                                 add_parms = { badges => rec.badges.join(',') };
76                                 del_parms = ['quux'];
77                             END;
78                             hold_type = 'M';
79                         ELSE;
80                         record_url_path = ctx.opac_root _ '/record/' _ rec.bre_id;
81                         add_parms = { badges => rec.badges.join(',') };
82                         del_parms = ['quux'];
83                         hold_type = 'T';
84                         END; -%]
85
86                     <div class="row" style="border-top: 1px solid grey;">
87
88                     <!--Count&Checkboxes-->
89                         <div class="col-lg-1">
90                             <div class="results_row_count"> [% IF !ctx.is_meta; %]
91                                 <label for="select-[% rec.bre_id %]">[% result_count; result_count = result_count + 1 %]</label>
92                                 <input type="checkbox" id="select-[% rec.bre_id %]"
93                                     [% IF is_selected %] checked="checked" [% END %]
94                                     title="[% l('Add to Basket') %]"
95                                     aria-label="[% l('Add to Basket') %]"
96                                     class="result_record_selector" value="[% rec.bre_id %]" />
97                                 [% END %]
98                             </div>
99                         </div>
100                         <!--Cover Image-->
101                         <div class='col-sm-2 text-center' id="result[% rec.bre_id %]">
102                             <a href="[% mkurl(record_url_path, add_parms, del_parms); %]"><img alt=""
103                             id='item_jacket[% rec.bre_id %]' class='my-2 img-fluid'
104                             src='[% ctx.media_prefix %]/opac/extras/ac/jacket/large/r/[% rec.bre_id | uri %]' style="max-height:150px;" /></a><br />
105                         </div>
106                             <!--Info-->
107                         <div class='result_table_title_cell col'>
108                             <div class="row align-items-start">
109                                 <div class="result_metadata col-md-8 col-12">
110                                     [% IF rec.mmr_id %]
111                                     <abbr class="unapi-id" title='tag:[% ctx.hostname %],[% date.format(date.now, '%Y') %]:metabib-metarecord/[% rec.mmr_id %]'></abbr>
112                                     [% ELSE %]
113                                     <abbr class="unapi-id" title='tag:[% ctx.hostname %],[% date.format(date.now, '%Y') %]:biblio-record_entry/[% rec.bre_id %]'></abbr>
114                                     [% END %]
115                                     <a class='record_title search_link' id='record_[% rec.id %]'
116                                         href="[% mkurl(record_url_path, add_parms, del_parms); %]"
117                                         [% html_text_attr('title', l('Display record details for "[_1]"', attrs.title)) %]>
118                                         [% IF attrs.hl.title; attrs.hl.title; ELSE; attrs.title | html; END %]
119                                     </a>
120                                     <span class="mx-2">
121                                         [%- IF attrs.format_label; %]
122                                             [% FOR format IN attrs.all_formats %]
123                                                 <img alt="" src="[% format.icon %]" />
124                                                 [% format.label | html %]
125                                             [% END %]
126                                         [%- END %]
127
128                                         [%- UNLESS show_detail_view;
129                                             IF attrs.pubdate;
130                                                 pubdate_clean = attrs.pubdate | html;
131                                                 l(" ([_1])", pubdate_clean);
132                                             ELSIF attrs.copyright;
133                                                 copyright_clean = attrs.copyright | html;
134                                                 l(" ([_1])", copyright_clean);
135                                             END;
136                                         END -%]
137                                     </span>
138                                         [% IF rec.mr_constituent_count.defined && rec.mr_constituent_count > 1 %]
139                                     <span title="[% l('This group contains [_1] records', rec.mr_constituent_count) %]">([% rec.mr_constituent_count %])</span>
140                                         [% END %]
141
142                                         [%- FOR entry IN attrs.graphic_titles;
143                                                 FOR alt IN entry.graphic;
144                                                 diratt = "";
145                                                 IF alt.dir;
146                                                     diratt = ' dir="' _ alt.dir _ '"';
147                                                 END; -%]
148                                     <div class="graphic880"[% diratt %]>
149                                         [% alt.value | html %]
150                                     </div>
151                                         [%- END; END; -%]
152
153                                     <div>
154                                     [% IF attrs.author; %]
155                                         <a  title="[% l("Perform an Author Search") %]"
156                                             class="record_author"
157                                             href="[%-
158                                             authorquery = attrs.author | replace('[#"^$\+\-,\.:;&|\[\]()]', ' ');
159                                             mkurl(ctx.opac_root _ '/results', {qtype => 'author', query => authorquery}, general_search_parms.merge(expert_search_parms, browse_search_parms, facet_search_parms))
160                                             -%]" rel="nofollow" vocab="">[% IF attrs.hl.author; attrs.hl.author; ELSE; attrs.author | html; END %]</a>
161                                     [% END %]
162
163
164                                             [%-
165                                             FOR entry IN attrs.graphic_authors;
166                                                 FOR alt IN entry.graphic;
167                                                     diratt = "";
168                                                     IF alt.dir;
169                                                         diratt = ' dir="' _ alt.dir _ '"';
170                                                     END;
171                                             -%]
172                                         <div class="graphic880"[% diratt %]>
173                                             [% alt.value | html %]
174                                         </div>
175                                         [%- END; END; -%]
176                                     </div>
177
178                                     [%- IF !show_detail_view AND args.holdings.size > 0 %]
179                                         <div class="result_call_number">
180                                             [% l('Call Number:') %] [% args.holdings.0.label | html %]
181                                         </div>
182                                     [% END %]
183
184                                         [% IF rec.popularity > 0.0 AND ctx.hide_badge_scores != 'true' %]
185                                         <div><span><strong>[% l('Popularity:') %]</strong> [% rec.popularity %] / 5.0</span></div>
186                                         [% END %]
187                                         <table
188                                             role="presentation"
189                                             title="[% l('Record Holdings Summary') %]"
190                                             class="table_no_border_space table_no_border results_info_table container-fluid">
191
192
193                                             [%- IF show_detail_view -%]
194                                             [% IF args.holdings.size > 0 %]
195                                             <tr class='result_table_title_cell'>
196                                                 <td valign='top'><strong>[% l('Call number:') %]</strong></td>
197                                                 <td>[% args.holdings.0.label | html %]</td>
198                                             </tr>
199                                             [% END %]
200                                             <!-- These fields are visible when viewing the results page in 'detailed' mode -->
201                                             [% UNLESS rec.mmr_id %]
202                                             <!-- Do not show publication-specific information on a metarecord search results page -->
203                                             [% IF attrs.publisher %]
204                                             <tr>
205                                                 <td valign="top"><strong>[% l('Publisher:') %]</strong></td>
206                                                 <td>[% attrs.pubplace | html; %] [% attrs.publisher | html; %] [% attrs.pubdate | html; %]
207                                                 [%- FOR entry IN attrs.graphic_pubinfos;
208                                                         FOR alt IN entry.graphic;
209                                                         diratt = "";
210                                                         IF alt.dir;
211                                                             diratt = ' dir="' _ alt.dir _ '"';
212                                                         END;
213                                                 -%]
214                                                 <div class="graphic880"[% diratt %]>[% alt.value | html %]</div>
215                                                 [%- END; END; -%]
216                                                 </td>
217                                             </tr>
218                                             [% ELSIF attrs.producer %]
219                                             <tr>
220                                                 <td valign="top"><strong>[% l('Producer:') %]</strong></td>
221                                                 <td>[% attrs.prodplace | html; %] [% attrs.producer | html; %] [% attrs.proddate | html; %]</td>
222                                             </tr>
223                                             [% ELSIF attrs.distributor %]
224                                             <tr>
225                                                 <td valign="top"><strong>[% l('Distributor:') %]</strong></td>
226                                                 <td>[% attrs.distplace | html; %] [% attrs.distributor | html; %] [% attrs.distdate | html; %]</td>
227                                             </tr>
228                                             [% ELSIF attrs.manufacturer %]
229                                             <tr>
230                                                 <td valign="top"><strong>[% l('Manufacturer:') %]</strong></td>
231                                                 <td>[% attrs.manplace | html; %] [% attrs.manufacturer | html; %] [% attrs.mandate | html; %]</td>
232                                             </tr>
233                                             [% END %]
234                                             [% IF attrs.isbns.size > 0 %]
235                                             <tr>
236                                                 <td valign="top"><strong>[% l('ISBN:') %]</strong></td>
237                                                 <td>[% attrs.isbns.0 | html %]</td>
238                                             </tr>
239                                             [% END %]
240                                             [%- IF attrs.issns.size > 0 %]
241                                             <tr>
242                                                 <td valign="top">
243                                                     <strong>[% l('ISSN:') %]</strong>
244                                                 </td>
245                                                 <td>[% attrs.issns.0 | html %]</td>
246                                             </tr>
247                                             [%- END %]
248                                             [%- IF openurl.enabled == 'true';
249                                                 FOREACH issn IN args.issns;
250                                                     NEXT IF issn == '';
251                                                     res_urls = ResolverResolver.resolve_issn(issn, openurl.baseurl);
252                                                     FOREACH res IN res_urls; %]
253                                             <tr>
254                                                 <td valign="top"><strong><a href="[% res.target_url %]">[% res.public_name | html %]</a></strong>
255                                                 </td>
256                                                     <td>[% res.target_coverage | html %]
257                                                     [%- IF res.target_embargo != '';' - ';res.target_embargo | html; END;-%]
258                                                     </td>
259                                             </tr>
260                                                     [% END %]
261                                                 [% END %]
262                                             [% END %]
263
264                                             [% IF attrs.edition %]
265                                             <tr>
266                                                 <td valign="top"><strong>[% l('Edition:') %]</strong></td>
267                                                 <td>[% attrs.edition | html %]
268                                                     [%- FOR entry IN attrs.graphic_editions;
269                                                         FOR alt IN entry.graphic;
270                                                             diratt = "";
271                                                             IF alt.dir; diratt = ' dir="' _ alt.dir _ '"'; END;
272                                                     -%]
273                                                     <div class="graphic880"[% diratt %]>
274                                                         [% alt.value | html %]
275                                                     </div>
276                                                     [%- END; END; -%]
277                                                 </td>
278                                             </tr>
279                                             [% END %]
280                                             [% IF attrs.phys_desc %]
281                                                 <tr >
282                                                     <td valign="top"><strong>[% l('Phys. Desc.:') %]</strong></td>
283                                                     <td>[% args.phys_desc | html %]</td>
284                                                 </tr>
285                                             [% END %]
286                                             [% FOR uri IN args.uris %]
287                                                 <tr class='result_table_title_cell row'>
288                                                     <td valign='top'><strong>[% l('Electronic resource') %]</strong></td>
289                                                     <td><a href="[% uri.href | html %]" class="uri_link" target="_blank">[% uri.link | html %]</a>
290                                                         [%- IF uri.note -%]
291                                                             [%- '- <span property="description">' _ uri.note _ '</span>' %]
292                                                         [%- ELSE -%]
293                                                             [% IF ctx.get_org_setting(ctx.search_ou, 'opac.uri_default_note_text') %]
294                                                                 [% link_note = ctx.get_org_setting(ctx.search_ou, 'opac.uri_default_note_text') %]
295                                                                 [% '- <span property="description">'; link_note | html; '</span>' %]
296                                                             [% END %]
297                                                         [%- END -%]</td>
298                                                 </tr>
299                                             [% END %]
300                                             [% END %]
301                                             [%- IF args.holdings.size > 0;
302                                                 FOREACH copy IN args.holdings;
303                                                     IF copy.part_label != '';
304                                                         has_parts = 'true';
305                                                         LAST;
306                                                     END;
307                                                 END;
308                                             %]
309                                             <tr  class='result_table_title_cell container-fluid'>
310                                                 <td colspan="2">
311                                                     <table role="presentation" title="[% l('Record Holdings Details') %]" class='container-fluid table table-hover mt-4 miniTable holdingsTable'>
312                                                         <thead>
313                                                             <tr>
314                                                                 <th>[% l('Location') %]</th>
315                                                                 <th>[% l('Shelving Location') %]</th>
316                                                                 <th>[% l('Call Number') %]</th>
317                                                                 [%- IF has_parts == 'true'; %]
318                                                                 <th>[% l('Part') %]</th>
319                                                                 [%- END %]
320                                                                 <th>[% l('Status') %]</th>
321                                                             </tr>
322                                                         </thead>
323                                                     <tbody>
324                                                     [% FOR copy IN args.holdings %]
325                                                         <tr mobile-count="#[% loop.count %]">
326                                                             <td mobile-title="[% l('Location') %]"><span class="sr-only">Location </span>[%- copy_info = copy; INCLUDE "opac/parts/library_name_link.tt2"; %]</td>
327                                                             <td mobile-title="[% l('Shelving Location') %]"><span class="sr-only">Shelving Location </span>[% copy.location | html %]</td>
328                                                             <td mobile-title="[% l('Call Number') %]"><span class="sr-only">Call Number </span>[% copy.label | html %]</td>
329                                                             [%- IF has_parts == 'true'; %]
330                                                             <td mobile-title="[% l('Part') %]"><span class="sr-only">Part </span>[% copy.part_label %]</td>
331                                                             [%- END %]
332                                                             <td mobile-title="[% l('Status') %]"><span class="sr-only">Status </span>[% copy.status | html %]</td>
333                                                         </tr>
334                                                     [% END %]
335                                                     </tbody>
336                                                     </table>
337                                                 </td>
338                                             </tr>
339                                             [%- has_parts = 'false'; END; %]
340                                         [% END %] <!-- END detail_record_view -->
341                                     </table>
342                                     [%
343                                         IF ebook_api.enabled == 'true';
344                                             INCLUDE "opac/parts/ebook_api/avail.tt2";
345                                         END;
346                                     %]
347                                     [% UNLESS rec.mmr_id;
348                                             PROCESS "opac/parts/result/copy_counts.tt2";
349                                     END; %]
350                                     [% IF ctx.use_courses %]
351                                         [%- courseStrings = [] %]
352                                         [% FOREACH course IN rec.courses %]
353                                             [% courseString = course.name _ ' (' _ course.course_number _ ')' %]
354                                             [% courseStrings.push(courseString); %]
355                                         [% END %]
356                                         [% IF courseStrings.size > 0 %]
357                                             <span><strong>[% l('Associated Courses: ') %]</strong></span>
358                                             <span>[% courseStrings.join(', ') %]</span>
359                                         [% END %]
360                                     [% END %]
361                                     [% IF rec.user_circulated %]
362                                     <div class="result_item_circulated">
363                                     <i class="fas fa-book-reader" aria-hidden="true"></i>
364                                     <span>[% l('I have checked this item out before') %]</span>
365                                     </div>
366                                     [% END %]
367                                     [% IF ctx.bookbag;
368                                         rec_id = rec.id;
369                                         FOR note IN ctx.bookbag_items_by_bre_id.$rec_id.notes %]
370                                             <div class="result-bookbag-item-note">[% note.note | html %]</div>
371                                         [% END %]
372                                     [% END %]
373
374                                 </div>
375
376
377                                 <div class="col-md-4">
378                                     <div class="result_table_utils row">
379                                         <div class="btn-group-vertical mx-auto my-2" >
380                                         [%- search_ou = ctx.search_ou;
381                                             num_holdable_copies = attrs.marc_xml.findnodes('//*[local-name()="holdings" and @has_holdable="true"]').size || 0;
382                                             IF ctx.place_unfillable || (num_holdable_copies > 0 && (ctx.holds_block.enabled != 'true' || attrs.org_copy_counts.$search_ou.available == 0))
383                                         %]
384                                         [% del_parms = ['tag','subfield','term','_special','sort','page'];
385                                         add_parms = {hold_target => rec.id, hold_type => hold_type, hold_source_page => mkurl()};
386
387                                         IF is_advanced;
388                                             # Do not pass "advanced params" to hold code
389                                             # Instead, pass the scrubed query in one-line form
390                                             del_parms = del_parms.merge(['query', 'bool', 'qtype', 'contains', '_adv']);
391                                             add_parms.import({query => ctx.naive_query_scrub(ctx.user_query)});
392                                         END; %]
393
394
395
396                                         <!--Place Hold Button -->
397                                        
398                                         <a role="button" href="[% mkurl(ctx.opac_root _ '/place_hold', add_parms, del_parms) %]"
399                                             [% html_text_attr('title', l('Place Hold on [_1]', attrs.title)) %]
400                                             class="btn btn-action" rel="nofollow" vocab="">
401                                             <i class="fas fa-check" aria-hidden="true"></i>
402                                             <span class="result_place_hold">[% l('Place Hold') %]</span>
403                                         </a>
404                                        
405                                         [%- END -%]
406
407                                         <!-- eBook Buttons -->
408                                         [%- IF ebook_api.enabled == 'true' && args.ebook %]
409                                       
410                                             <a href="[% mkurl(ctx.opac_root _ '/myopac/ebook_checkout',
411                                                 {title => args.ebook.ebook_id, vendor => args.ebook.vendor, action => 'checkout'},
412                                                 ['query','tag','subfield','term','_special','sort','page']) %]"
413                                                 [% html_text_attr('title', l('Check Out [_1]', attrs.title)) %]
414                                                     class="btn btn-action" role="button" rel="nofollow" vocab=""><i class="fas fa-atlas" aria-hidden="true"></i> <span class="result_place_hold">[% l('Check Out E-Item') %]</span></a>
415                                        
416                                        
417                                             <a href="[% mkurl(ctx.opac_root _ '/myopac/ebook_place_hold',
418                                                 {title => args.ebook.ebook_id, vendor => args.ebook.vendor, action => 'place_hold'},
419                                                 ['query','tag','subfield','term','_special','sort','page']) %]"
420                                                 [% html_text_attr('title', l('Place Hold on [_1]', attrs.title)) %]
421                                                     class="btn btn-action" role="button" rel="nofollow" vocab=""><i class="fas fa-book-reader" aria-hidden="true"></i> <span class="result_place_hold">[% l('Place Hold on E-Item') %]</span></a>
422                                        
423                                         [%- END -%]
424
425                                         <!--Basket and My Lists Buttons -->
426                                         [% IF !ctx.is_meta %]
427                                                 [% IF !ctx.is_staff %]
428                                                 [%
429                                                     addhref = mkurl(ctx.opac_root _ '/mylist/add',
430                                                             {record => rec.id, anchor => 'record_' _ rec.id}, 1);
431                                                     delhref = mkurl(ctx.opac_root _ '/mylist/delete',
432                                                             {record => rec.id, anchor => 'record_' _ rec.id}, 1);
433                                                 %]
434                                                 
435                                                 <a href="[% addhref %]" id="mylist_add_[% rec.id %]"
436                                                     data-recid="[% rec.id %]" data-action="add"
437                                                     role="button" class="mylist_action btn btn-action [% IF ctx.mylist.grep('^' _ rec.id _ '$').size %]hidden[% END %]"
438                                                     [% SET esc_title = attrs.title | html -%]
439                                                     title="[% l("Add [_1] to basket", esc_title) %]" rel="nofollow" vocab="">
440                                                     <i class="fas fa-shopping-basket" aria-hidden="true"></i>
441                                                     [% l("Add to basket") %]
442                                                 </a>
443
444                                                 <a href="[% delhref %]" id="mylist_delete_[% rec.id %]"
445                                                     data-recid="[% rec.id %]" data-action="delete" role="button"
446                                                     class="mylist_action btn btn-action [% IF !ctx.mylist.grep('^' _ rec.id _ '$').size %]hidden[% END %]"
447                                                     title="[% l("Remove [_1] from basket", esc_title) %]" rel="nofollow" vocab="">
448                                                     <i class="fas fa-minus-circle" aria-hidden="true"></i>
449                                                     [% l("Remove from basket") %]
450                                                 </a>
451                                                 
452                                                 [%  IF ctx.user;
453                                                     INCLUDE "opac/parts/bookbag_actions.tt2";
454                                                     END;
455                                                 %]
456                                                 [% END %]
457                                         [% END %]
458
459                                         <!--Added Content - Content Cafe -->
460                                         [% IF ENV.OILS_CONTENT_CAFE_USER %]
461                                         [% ident = attrs.isbn_clean || attrs.upc %]
462                                          
463                                                 <a target='_blank'
464                                                     [% html_text_attr('title', l('Reviews and More for [_1]', attrs.title)) %]
465                                                     href="[% ctx.ext_proto %]://contentcafe2.btol.com/ContentCafeClient/ContentCafe.aspx?UserID=[%-
466                                                         ENV.OILS_CONTENT_CAFE_USER %]&amp;Password=[%-
467                                                         ENV.OILS_CONTENT_CAFE_PASS %]&amp;ItemKey=[% ident | uri %]&amp;Options=Y" rel="nofollow" vocab="">
468                                                     <i class="fas fa-star" aria-hidden="true"></i>
469                                                     <span class="results_reviews">[% l('Reviews &amp; More') %]</span>
470                                                 </a>
471                                             
472                                         [% END %]
473                                         </div>
474                                         </div>
475                                     </div>
476                                 </div>
477                             </div></div>
478
479                 [%- IF ENV.OILS_CHILIFRESH_ACCOUNT %]
480
481                         <span class="chili_review" id="isbn_[% attrs.isbn_clean | html %]"> </span>
482
483                         <div id="chili_review_[% attrs.isbn_clean | html %]" style="display: none;" align="center"></div>
484
485                 [%- END %]
486                     [% END %]
487
488     </div>
489
490
491
492 <div class="facet_sidebar_hidden" id="facet_sidebar">
493     [%- IF ctx.is_staff %]
494     <h3 class="sr-only">[% l('Saved Searches') %]</h3>
495         [% INCLUDE "opac/parts/staff_saved_searches.tt2" %]
496     [%-  END %]
497     <h3 class="sr-only">[% l('Search Results Facets') %]</h3>
498     <h3 class="sr-only">[% l('Search Results List') %]</h3>
499 </div>
500 </div>
501
502 </div>
503 <div class="col-12">
504 <div class="result_footer_nav1">
505     [% ctx.results_count_header %]
506 </div>
507 </div>
508 <div class="d-xl-none d-block">
509 [% INCLUDE 'opac/parts/result/facets.tt2' %]
510 </div>
511 <script>
512 resultBlock = document.getElementById('result_block');
513 resultButton = document.getElementById('return_to_hits');
514 facetSidebar = document.getElementById('facet_sidebar');
515 facetButton =  document.getElementById('refine_hits');
516 function getFacety() {
517     resultBlock.setAttribute('class', 'result_block_hidden');
518     resultButton.setAttribute('class', 'results_header_btns result_block_visible');
519     facetSidebar.setAttribute('class', 'facet_sidebar_visible');
520     facetButton.setAttribute('class', 'result_block_hidden');
521     window.location.hash = 'return_to_hits';
522 }
523 function getResulty() {
524     resultBlock.setAttribute('class', 'result_block_visible');
525     resultButton.setAttribute('class', 'result_block_hidden');
526     facetSidebar.setAttribute('class', 'facet_sidebar_hidden');
527     facetButton.setAttribute('class', 'results_header_btns result_block_visible');
528     window.location.hash = 'refine_hits';
529 }
530 </script>