Bug 14607: Baker & Taylor cover images should be accessible by UPC as well as ISBN
[koha.git] / koha-tmpl / opac-tmpl / bootstrap / en / includes / shelfbrowser.inc
1 [% BLOCK shelfbrowser %]
2     [% IF OpenOPACShelfBrowser %]
3         <div id="shelfbrowser">
4             <h5 style="text-align: center;">
5                 [% IF ( starting_homebranch ) %]Browsing [% starting_homebranch %] Shelves[% END %]
6                 [% IF ( starting_location ) %], Shelving location: [% starting_location %][% END %]
7                 [% IF ( starting_ccode ) %], Collection code: [% starting_ccode %][% END %]
8                 <a style="font-size: 75%;" href="/cgi-bin/koha/opac-detail.pl?biblionumber=[% biblionumber %]" class="close_shelf" >Close shelf browser</a>
9             </h5>
10
11             <table class="table">
12                 <tr>
13                     <td rowspan="2">
14                       [% IF shelfbrowser_prev_item %]
15                         <div id="browser_previous">
16                             <a href="/cgi-bin/koha/opac-detail.pl?biblionumber=[% shelfbrowser_prev_item.biblionumber %]&amp;shelfbrowse_itemnumber=[% shelfbrowser_prev_item.itemnumber %]#shelfbrowser" data-prev-itemnumber="[% shelfbrowser_prev_item.itemnumber %]">Previous</a>
17                         </div>
18                       [% END %]
19                     </td>
20
21                     [% FOREACH item IN shelfbrowser_items %]
22                         <td>
23                             <a href="/cgi-bin/koha/opac-detail.pl?biblionumber=[% item.biblionumber %]&amp;shelfbrowse_itemnumber=[% item.itemnumber %]#shelfbrowser">
24                                 [% IF ( OPACLocalCoverImages ) %]
25                                     <div title="[% item.biblionumber |url %]" class="[% item.biblionumber %] thumbnail-shelfbrowser" id="local-thumbnail-shelf-[% item.biblionumber %]"></div>
26                                 [% END %]
27                                 [% IF ( OPACAmazonCoverImages ) %]
28                                     [% IF ( item.browser_normalized_isbn ) %]
29                                         <img src="http://images.amazon.com/images/P/[% item.browser_normalized_isbn %].01._AA75_PU_PU-5_.jpg" alt="" />
30                                     [% ELSE %]
31                                         <span class="no-image">No cover image available</span>
32                                     [% END %]
33                                 [% END %]
34
35                                 [% IF ( SyndeticsEnabled ) %]
36                                     [% IF ( SyndeticsCoverImages ) %]
37                                         [% IF ( content_identifier_exists ) %]
38                                             [% IF ( using_https ) %]
39                                                 <img src="https://secure.syndetics.com/index.aspx?isbn=[% item.browser_normalized_isbn %]/SC.GIF&amp;client=[% SyndeticsClientCode %][% IF ( item.browser_normalized_upc ) %]&amp;upc=[% item.browser_normalized_upc %][% END %][% IF ( item.browser_normalized_oclc ) %]&amp;oclc=[% item.browser_normalized_oclc %][% END %]&amp;type=xw10" alt="" />
40                                             [% ELSE %]
41                                                 <img src="http://www.syndetics.com/index.aspx?isbn=[% item.browser_normalized_isbn %]/SC.GIF&amp;client=[% SyndeticsClientCode %][% IF ( item.browser_normalized_upc ) %]&amp;upc=[% item.browser_normalized_upc %][% END %][% IF ( item.browser_normalized_oclc ) %]&amp;oclc=[% item.browser_normalized_oclc %][% END %]&amp;type=xw10" alt="" />
42                                             [% END %]
43                                         [% ELSE %]
44                                             <span class="no-image">No cover image available</span>
45                                         [% END %]
46                                     [% END %]
47                                 [% END %]
48
49                                 [% IF ( GoogleJackets ) %]
50                                     [% IF ( item.browser_normalized_isbn ) %]
51                                         <div style="block" title="[% item.biblionumber |url %]" class="[% item.browser_normalized_isbn %]" id="gbs-thumbnail-preview[% loop.count %]"></div>
52                                     [% ELSE %]
53                                         <span class="no-image">No cover image available</span>
54                                     [% END %]
55                                 [% END %]
56                                 [% IF ( Koha.Preference('Coce') && Koha.Preference('CoceProviders') ) %]
57                                   [% coce_id = item.browser_normalized_ean || item.browser_normalized_isbn %]
58                                   <div title="[% item.biblionumber |url %]" class="[% coce_id %]" id="coce-thumbnail-preview-[% coce_id %]"></div>
59                                 [% END %]
60                                 [% IF ( BakerTaylorEnabled ) %]
61                                     [% bt_id = ( item.browser_normalized_upc || item.browser_normalized_upc ) %]
62                                     [% IF ( bt_id ) %]
63                                         <img alt="See Baker &amp; Taylor" src="[% BakerTaylorImageURL |html %][% bt_id %]" />
64                                     [% ELSE %]
65                                         <span class="no-image">No cover image available</span>
66                                     [% END %]
67                                 [% END %]
68                             </a>
69                         </td>
70                     [% END %]
71                     <td rowspan="2">
72                         [% IF shelfbrowser_next_item %]
73                             <div id="browser_next">
74                                 <a href="/cgi-bin/koha/opac-detail.pl?biblionumber=[% shelfbrowser_next_item.biblionumber %]&amp;shelfbrowse_itemnumber=[% shelfbrowser_next_item.itemnumber %]#shelfbrowser" data-next-itemnumber="[% shelfbrowser_next_item.itemnumber %]">Next</a>
75                             </div>
76                         [% END %]
77                     </td>
78                 </tr>
79
80                 <tr>
81                     [% FOREACH item IN shelfbrowser_items %]
82                         <td class="top">
83                             [% item.itemcallnumber %]
84                             <a href="/cgi-bin/koha/opac-detail.pl?biblionumber=[% item.biblionumber %]&amp;shelfbrowse_itemnumber=[% item.itemnumber %]#shelfbrowser">[% item.title |html %]</a>
85                         </td>
86                     [% END %]
87                 </tr>
88             </table>
89         </div>
90     [% END # /IF OpenOPACShelfBrowser %]
91 [% END # end of shelfbrowser block %]