View | Details | Raw Unified | Return to bug 18421
Collapse All | Expand All

(-)a/installer/data/mysql/atomicupdate/bug_18421_add_coce_intranet.perl (+24 lines)
Line 0 Link Here
1
#! /usr/bin/perl
2
3
use Modern::Perl;
4
use C4::Context;
5
6
my $dbh=C4::Context->dbh;
7
8
################
9
# IntranetCoce #
10
################
11
12
# validate systempreferences.Coce and save the config for OpacCoce
13
my $current_coce_pref = C4::Context->preference('Coce') || 0;
14
15
# add two new systempreferences in order to have distinct behavior between intranet and OPAC
16
$dbh->do("INSERT IGNORE INTO systempreferences (variable,value,options,explanation,type) VALUES
17
        ('IntranetCoce','0', NULL, 'If on, enables cover retrieval from the configured Coce server in the staff intranet', 'YesNo'),
18
        ('OpacCoce','$current_coce_pref', NULL, 'If on, enables cover retrieval from the configured Coce server in the OPAC', 'YesNo')
19
        ;") or die "Error applying Bug 18421: error inserting new values into database: ". $dbh->errstr . "\n";
20
21
$dbh->do("DELETE IGNORE FROM systempreferences WHERE variable = 'Coce';")
22
    or die "Error applying Bug 18421: error deleting the old syspref 'Coce': ". $dbh->errstr . "\n";
23
24
print "Upgrade to XX.XX done (Bug 18421: Add Coce image cache to the Intranet)\n";
(-)a/installer/data/mysql/sysprefs.sql (-1 / +2 lines)
Lines 108-114 INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` Link Here
108
('CircControl','ItemHomeLibrary','PickupLibrary|PatronLibrary|ItemHomeLibrary','Specify the agency that controls the circulation and fines policy','Choice'),
108
('CircControl','ItemHomeLibrary','PickupLibrary|PatronLibrary|ItemHomeLibrary','Specify the agency that controls the circulation and fines policy','Choice'),
109
('CircSidebar','0',NULL,'Activate or deactivate the navigation sidebar on all Circulation pages','YesNo'),
109
('CircSidebar','0',NULL,'Activate or deactivate the navigation sidebar on all Circulation pages','YesNo'),
110
('ClaimsBccCopy','0','','Bcc the ClaimAcquisition and ClaimIssues alerts','YesNo'),
110
('ClaimsBccCopy','0','','Bcc the ClaimAcquisition and ClaimIssues alerts','YesNo'),
111
('Coce','0', NULL, 'If on, enables cover retrieval from the configured Coce server', 'YesNo'),
112
('CoceHost', '', NULL, 'Coce server URL', 'Free'),
111
('CoceHost', '', NULL, 'Coce server URL', 'Free'),
113
('CoceProviders', '', 'aws,gb,ol', 'Coce providers', 'multiple'),
112
('CoceProviders', '', 'aws,gb,ol', 'Coce providers', 'multiple'),
114
('COinSinOPACResults','1','','If ON, use COinS in OPAC search results page.  NOTE: this can slow down search response time significantly','YesNo'),
113
('COinSinOPACResults','1','','If ON, use COinS in OPAC search results page.  NOTE: this can slow down search response time significantly','YesNo'),
Lines 217-222 INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` Link Here
217
('IntranetBiblioDefaultView','normal','normal|marc|isbd|labeled_marc','Choose the default detail view in the staff interface; choose between normal, labeled_marc, marc or isbd','Choice'),
216
('IntranetBiblioDefaultView','normal','normal|marc|isbd|labeled_marc','Choose the default detail view in the staff interface; choose between normal, labeled_marc, marc or isbd','Choice'),
218
('intranetbookbag','1','','If ON, enables display of Cart feature in the intranet','YesNo'),
217
('intranetbookbag','1','','If ON, enables display of Cart feature in the intranet','YesNo'),
219
('IntranetCirculationHomeHTML', '', NULL, 'Show the following HTML in a div on the bottom of the reports home page', 'Free'),
218
('IntranetCirculationHomeHTML', '', NULL, 'Show the following HTML in a div on the bottom of the reports home page', 'Free'),
219
('IntranetCoce','0', NULL, 'If on, enables cover retrieval from the configured Coce server in the staff intranet', 'YesNo'),
220
('intranetcolorstylesheet','','50','Define the color stylesheet to use in the Staff Client','free'),
220
('intranetcolorstylesheet','','50','Define the color stylesheet to use in the Staff Client','free'),
221
('IntranetFavicon','','','Enter a complete URL to an image to replace the default Koha favicon on the Staff client','free'),
221
('IntranetFavicon','','','Enter a complete URL to an image to replace the default Koha favicon on the Staff client','free'),
222
('IntranetmainUserblock','','70|10','Add a block of HTML that will display on the intranet home page','Textarea'),
222
('IntranetmainUserblock','','70|10','Add a block of HTML that will display on the intranet home page','Textarea'),
Lines 323-328 INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` Link Here
323
('OpacBrowseResults','1',NULL,'Disable/enable browsing and paging search results from the OPAC detail page.','YesNo'),
323
('OpacBrowseResults','1',NULL,'Disable/enable browsing and paging search results from the OPAC detail page.','YesNo'),
324
('OpacCloud','0',NULL,'If ON, enables subject cloud on OPAC','YesNo'),
324
('OpacCloud','0',NULL,'If ON, enables subject cloud on OPAC','YesNo'),
325
('OpacAdditionalStylesheet','','','Define an auxiliary stylesheet for OPAC use, to override specified settings from the primary opac.css stylesheet. Enter the filename (if the file is in the server\'s css directory) or a complete URL beginning with http (if the file lives on a remote server).','free'),
325
('OpacAdditionalStylesheet','','','Define an auxiliary stylesheet for OPAC use, to override specified settings from the primary opac.css stylesheet. Enter the filename (if the file is in the server\'s css directory) or a complete URL beginning with http (if the file lives on a remote server).','free'),
326
('OpacCoce','0', NULL, 'If on, enables cover retrieval from the configured Coce server in the OPAC', 'YesNo'),
326
('OpacCustomSearch','','70|10','Replace the search box on the OPAC with the provided HTML','Textarea'),
327
('OpacCustomSearch','','70|10','Replace the search box on the OPAC with the provided HTML','Textarea'),
327
('opaccredits','','70|10','Define HTML Credits at the bottom of the OPAC page','Textarea'),
328
('opaccredits','','70|10','Define HTML Credits at the bottom of the OPAC page','Textarea'),
328
('OPACdefaultSortField','relevance','relevance|popularity|call_number|pubdate|acqdate|title|author','Specify the default field used for sorting','Choice'),
329
('OPACdefaultSortField','relevance','relevance|popularity|call_number|pubdate|acqdate|title|author','Specify the default field used for sorting','Choice'),
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/enhanced_content.pref (-2 / +8 lines)
Lines 374-384 Enhanced Content: Link Here
374
            - with OverDrive.
374
            - with OverDrive.
375
    Coce Cover images cache:
375
    Coce Cover images cache:
376
        -
376
        -
377
            - pref: Coce
377
            - pref: OpacCoce
378
              choices:
378
              choices:
379
                  yes: Enable
379
                  yes: Enable
380
                  no: "Don't enable"
380
                  no: "Don't enable"
381
            - a Coce image cache service.
381
            - a Coce image cache service in the OPAC.
382
        -
383
            - pref: IntranetCoce
384
              choices:
385
                  yes: Enable
386
                  no: "Don't enable"
387
            - a Coce image cache service in the staff intranet.
382
        -
388
        -
383
            - Coce server URL
389
            - Coce server URL
384
            - pref: CoceHost
390
            - pref: CoceHost
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt (-3 / +34 lines)
Lines 58-70 Link Here
58
    <div id="yui-main">
58
    <div id="yui-main">
59
    <div class="yui-b">
59
    <div class="yui-b">
60
60
61
[%
62
    IntranetCoce    = Koha.Preference('IntranetCoce')
63
    CoceProviders   = Koha.Preference('CoceProviders')
64
    CoceHost        = Koha.Preference('CoceHost')
65
%]
66
61
[% INCLUDE 'cat-toolbar.inc' %]
67
[% INCLUDE 'cat-toolbar.inc' %]
62
    [% IF ( ocoins ) %]
68
    [% IF ( ocoins ) %]
63
        <!-- COinS / OpenURL -->
69
        <!-- COinS / OpenURL -->
64
        <span class="Z3988" title="[% ocoins %]"></span>
70
        <span class="Z3988" title="[% ocoins %]"></span>
65
    [% END %]
71
    [% END %]
66
72
67
    [% IF ( AmazonCoverImages  || LocalCoverImages ) %]
73
    [% IF ( AmazonCoverImages  || LocalCoverImages || IntranetCoce ) %]
68
        [% IF ( XSLTDetailsDisplay ) %]
74
        [% IF ( XSLTDetailsDisplay ) %]
69
            <div class="yui-gc">
75
            <div class="yui-gc">
70
            <div id="catalogue_detail_biblio" class="yui-u first">
76
            <div id="catalogue_detail_biblio" class="yui-u first">
Lines 125-131 Link Here
125
            </span>
131
            </span>
126
        [% END %]
132
        [% END %]
127
133
128
        [% IF ( AmazonCoverImages  || LocalCoverImages ) %]
134
        [% IF ( AmazonCoverImages  || LocalCoverImages || IntranetCoce ) %]
129
        </div><div class="yui-u" id="bookcoverimg">
135
        </div><div class="yui-u" id="bookcoverimg">
130
        [% IF ( LocalCoverImages ) %]
136
        [% IF ( LocalCoverImages ) %]
131
            <div title="[% biblionumber |url %]" class="[% biblionumber %]" id="local-thumbnail-preview"></div>
137
            <div title="[% biblionumber |url %]" class="[% biblionumber %]" id="local-thumbnail-preview"></div>
Lines 136-141 Link Here
136
                <img src="https://images-na.ssl-images-amazon.com/images/P/[% normalized_isbn %].01.MZZZZZZZ.jpg" alt="" />
142
                <img src="https://images-na.ssl-images-amazon.com/images/P/[% normalized_isbn %].01.MZZZZZZZ.jpg" alt="" />
137
        </a></div>
143
        </a></div>
138
        [% END %]
144
        [% END %]
145
        [% IF ( IntranetCoce && CoceProviders ) %]
146
          [% coce_id = normalized_ean || normalized_isbn %]
147
            <a class="p1" href="/cgi-bin/koha/catalogue/[% DetailPage %]?biblionumber=[% biblionumber |url %]">
148
          [% IF ( coce_id ) %]
149
            <span style="block" title="[% biblionumber |url %]" class="[% coce_id %]" id="coce-thumbnail-preview"></span>
150
          [% ELSE %]
151
            <span class="no-image">No cover image available</span>
152
          [% END %]
153
            </a>
154
        [% END %]
139
        [% END %]
155
        [% END %]
140
    [% ELSE %]
156
    [% ELSE %]
141
157
Lines 199-205 Link Here
199
        </ul>
215
        </ul>
200
        </div>
216
        </div>
201
       
217
       
202
    [% IF ( AmazonCoverImages  || LocalCoverImages ) %]
218
    [% IF ( AmazonCoverImages  || LocalCoverImages || IntranetCoce ) %]
203
        <div class="yui-u" id="bookcoverimg">
219
        <div class="yui-u" id="bookcoverimg">
204
        [% IF ( LocalCoverImages ) %]
220
        [% IF ( LocalCoverImages ) %]
205
            <div title="[% biblionumber |url %]" class="[% biblionumber %]" id="local-thumbnail-preview"></div>
221
            <div title="[% biblionumber |url %]" class="[% biblionumber %]" id="local-thumbnail-preview"></div>
Lines 211-216 Link Here
211
            </a>
227
            </a>
212
        </div>
228
        </div>
213
        [% END %]
229
        [% END %]
230
        [% IF ( IntranetCoce && CoceProviders ) %]
231
          [% coce_id = normalized_ean || normalized_isbn %]
232
            <a class="p1" href="/cgi-bin/koha/catalogue/[% DetailPage %]?biblionumber=[% biblionumber |url %]">
233
          [% IF ( coce_id ) %]
234
            <span style="block" title="[% biblionumber |url %]" class="[% coce_id %]" id="coce-thumbnail-preview"></span>
235
          [% ELSE %]
236
            <span class="no-image">No cover image available</span>
237
          [% END %]
238
            </a>
239
        [% END %]
214
        </div>
240
        </div>
215
    [% END %]
241
    [% END %]
216
        
242
        
Lines 848-853 Link Here
848
    [% INCLUDE 'catalog-strings.inc' %]
874
    [% INCLUDE 'catalog-strings.inc' %]
849
    <script type="text/javascript" src="[% interface %]/[% theme %]/js/catalog_[% KOHA_VERSION %].js"></script>
875
    <script type="text/javascript" src="[% interface %]/[% theme %]/js/catalog_[% KOHA_VERSION %].js"></script>
850
    [% INCLUDE 'greybox.inc' %]
876
    [% INCLUDE 'greybox.inc' %]
877
    <script type="text/javascript" src="[% interface %]/prog/js/coce_[% KOHA_VERSION %].js"></script>
851
    <script type="text/javascript">
878
    <script type="text/javascript">
852
        // http://www.oreillynet.com/pub/a/javascript/2003/10/21/amazonhacks.html
879
        // http://www.oreillynet.com/pub/a/javascript/2003/10/21/amazonhacks.html
853
        function verify_images() {
880
        function verify_images() {
Lines 1003-1008 Link Here
1003
            [% IF LocalCoverImages %]
1030
            [% IF LocalCoverImages %]
1004
                KOHA.LocalCover.GetCoverFromBibnumber(true);
1031
                KOHA.LocalCover.GetCoverFromBibnumber(true);
1005
            [% END %]
1032
            [% END %]
1033
            [% IF ( IntranetCoce && CoceProviders ) %]
1034
                KOHA.coce.getURL('[% CoceHost %]', '[% CoceProviders %]');
1035
            [% END %]
1036
1006
            $("body").on("click",".previewMARC", function(e){
1037
            $("body").on("click",".previewMARC", function(e){
1007
                e.preventDefault();
1038
                e.preventDefault();
1008
                var page = $(this).attr("href");
1039
                var page = $(this).attr("href");
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/results.tt (-2 / +24 lines)
Lines 20-25 Link Here
20
[% INCLUDE 'header.inc' %]
20
[% INCLUDE 'header.inc' %]
21
[% INCLUDE 'cat-search.inc' %]
21
[% INCLUDE 'cat-search.inc' %]
22
22
23
[%
24
    IntranetCoce    = Koha.Preference('IntranetCoce')
25
    CoceProviders   = Koha.Preference('CoceProviders')
26
    CoceHost        = Koha.Preference('CoceHost')
27
%]
28
23
<div id="breadcrumbs">
29
<div id="breadcrumbs">
24
         <a href="/cgi-bin/koha/mainpage.pl">Home</a>
30
         <a href="/cgi-bin/koha/mainpage.pl">Home</a>
25
&rsaquo; <a href="/cgi-bin/koha/catalogue/search.pl">Catalog</a>
31
&rsaquo; <a href="/cgi-bin/koha/catalogue/search.pl">Catalog</a>
Lines 351-357 Link Here
351
                    <!-- TABLE RESULTS START -->
357
                    <!-- TABLE RESULTS START -->
352
                <table>
358
                <table>
353
                    <tr>
359
                    <tr>
354
                        [% IF ( AmazonCoverImages || LocalCoverImages ) %]<th>&nbsp;</th>[% END %]
360
                        [% IF ( AmazonCoverImages || LocalCoverImages || IntranetCoce ) %]<th>&nbsp;</th>[% END %]
355
                        <th colspan="2">Results</th>
361
                        <th colspan="2">Results</th>
356
                        <th>Location</th>
362
                        <th>Location</th>
357
                    </tr>
363
                    </tr>
Lines 359-365 Link Here
359
                        [% SET MaxSearchResultsItemsPerRecordStatusCheck = Koha.Preference('MaxSearchResultsItemsPerRecordStatusCheck') %]
365
                        [% SET MaxSearchResultsItemsPerRecordStatusCheck = Koha.Preference('MaxSearchResultsItemsPerRecordStatusCheck') %]
360
                        [% FOREACH SEARCH_RESULT IN SEARCH_RESULTS %]
366
                        [% FOREACH SEARCH_RESULT IN SEARCH_RESULTS %]
361
                            <tr>
367
                            <tr>
362
                            [% IF ( AmazonCoverImages || LocalCoverImages ) %]
368
                            [% IF ( AmazonCoverImages || LocalCoverImages || IntranetCoce ) %]
363
                                <td>
369
                                <td>
364
                                    [% IF ( LocalCoverImages) %]
370
                                    [% IF ( LocalCoverImages) %]
365
                                        <a class="p1" href="/cgi-bin/koha/catalogue/[% DetailPage %]?biblionumber=[% SEARCH_RESULT.biblionumber |url %]">
371
                                        <a class="p1" href="/cgi-bin/koha/catalogue/[% DetailPage %]?biblionumber=[% SEARCH_RESULT.biblionumber |url %]">
Lines 376-381 Link Here
376
                                        [% END %]
382
                                        [% END %]
377
                                        </a>
383
                                        </a>
378
                                    [% END %]
384
                                    [% END %]
385
                                    [% IF ( IntranetCoce && CoceProviders ) %]
386
                                      [% coce_id = SEARCH_RESULT.normalized_ean || SEARCH_RESULT.normalized_isbn %]
387
                                        <a class="p1" href="/cgi-bin/koha/catalogue/[% DetailPage %]?biblionumber=[% SEARCH_RESULT.biblionumber |url %]">
388
                                      [% IF ( coce_id ) %]
389
                                        <span style="block" title="[% SEARCH_RESULT.biblionumber |url %]" class="[% coce_id %]" id="coce-thumbnail[% loop.count %]"></span>
390
                                      [% ELSE %]
391
                                        <span class="no-image">No cover image available</span>
392
                                      [% END %]
393
                                        </a>
394
                                    [% END %]
395
379
                                </td>
396
                                </td>
380
                            [% END %]
397
                            [% END %]
381
                            <td>
398
                            <td>
Lines 625-630 Link Here
625
    <script type="text/javascript" src="[% interface %]/js/browser_[% KOHA_VERSION %].js"></script>
642
    <script type="text/javascript" src="[% interface %]/js/browser_[% KOHA_VERSION %].js"></script>
626
    <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery.fixFloat_[% KOHA_VERSION %].js"></script>
643
    <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery.fixFloat_[% KOHA_VERSION %].js"></script>
627
    <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery.checkboxes.min_[% KOHA_VERSION %].js"></script>
644
    <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery.checkboxes.min_[% KOHA_VERSION %].js"></script>
645
    <script type="text/javascript" src="[% interface %]/prog/js/coce_[% KOHA_VERSION %].js"></script>
628
    <script type="text/javascript">
646
    <script type="text/javascript">
629
        var MSG_NO_ITEM_SELECTED = _("Nothing is selected.");
647
        var MSG_NO_ITEM_SELECTED = _("Nothing is selected.");
630
        var MSG_NON_RESERVES_SELECTED = _("One or more selected items cannot be placed on hold.");
648
        var MSG_NON_RESERVES_SELECTED = _("One or more selected items cannot be placed on hold.");
Lines 750-755 Link Here
750
                KOHA.LocalCover.LoadResultsCovers();
768
                KOHA.LocalCover.LoadResultsCovers();
751
            [% END %]
769
            [% END %]
752
770
771
            [% IF ( IntranetCoce && CoceProviders ) %]
772
                KOHA.coce.getURL('[% CoceHost %]', '[% CoceProviders %]');
773
            [% END %]
774
753
            $("#select_all").on("click",function(e){
775
            $("#select_all").on("click",function(e){
754
                e.preventDefault();
776
                e.preventDefault();
755
                selectAll();
777
                selectAll();
(-)a/koha-tmpl/intranet-tmpl/prog/js/coce.js (+43 lines)
Line 0 Link Here
1
if (KOHA === undefined || !KOHA) { var KOHA = {}; }
2
3
4
/**
5
 * A namespace for Coce cover images cache
6
 */
7
KOHA.coce = {
8
9
  /**
10
   * Search all:
11
   *    <div title="biblionumber" id="isbn" class="coce-thumbnail"></div>
12
   * or
13
   *    <div title="biblionumber" id="isbn" class="coce-thumbnail-preview"></div>
14
   * and run a search with all collected isbns to coce cover service.
15
   * The result is asynchronously returned, and used to append <img>.
16
   */
17
  getURL: function(host,provider,newWindow) {
18
    var ids = [];
19
    $("[id^=coce-thumbnail]").each(function(i) {
20
        var id = $(this).attr("class"); // id=isbn
21
        if ( id !== '' ) { ids.push(id); }
22
    });
23
    if (ids.length == 0) return;
24
    ids = ids.join(',');
25
    var coceURL = host + '/cover?id=' + ids + '&provider=' + provider;
26
    $.ajax({
27
      url: coceURL,
28
      dataType: 'jsonp',
29
      success: function(urlPerID){
30
        for (var id in urlPerID) {
31
          var url = urlPerID[id];
32
          $("[id^=coce-thumbnail]."+id).each(function() {
33
            var img = document.createElement("img");
34
            img.src = url;
35
            img.title = url; //FIXME: to delete
36
            $(this).html(img);
37
         });
38
        }
39
      }
40
    });
41
  }
42
43
};
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-bottom.inc (-1 / +1 lines)
Lines 193-199 $.widget.bridge('uitooltip', $.ui.tooltip); Link Here
193
        //]]>
193
        //]]>
194
    </script>
194
    </script>
195
[% END %]
195
[% END %]
196
[% IF ( Koha.Preference('Coce') && Koha.Preference('CoceProviders') ) %]
196
[% IF ( Koha.Preference('OpacCoce') && Koha.Preference('CoceProviders') ) %]
197
    <script type="text/javascript" src="[% interface %]/[% theme %]/js/coce_[% KOHA_VERSION %].js"></script>
197
    <script type="text/javascript" src="[% interface %]/[% theme %]/js/coce_[% KOHA_VERSION %].js"></script>
198
    <script type="text/javascript">
198
    <script type="text/javascript">
199
        //<![CDATA[
199
        //<![CDATA[
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/shelfbrowser.inc (-1 / +1 lines)
Lines 53-59 Link Here
53
                                        <span class="no-image">No cover image available</span>
53
                                        <span class="no-image">No cover image available</span>
54
                                    [% END %]
54
                                    [% END %]
55
                                [% END %]
55
                                [% END %]
56
                                [% IF ( Koha.Preference('Coce') && Koha.Preference('CoceProviders') ) %]
56
                                [% IF ( Koha.Preference('OpacCoce') && Koha.Preference('CoceProviders') ) %]
57
                                  [% coce_id = item.browser_normalized_ean || item.browser_normalized_isbn %]
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>
58
                                  <div title="[% item.biblionumber |url %]" class="[% coce_id %]" id="coce-thumbnail-preview-[% coce_id %]"></div>
59
                                [% END %]
59
                                [% END %]
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt (-4 / +4 lines)
Lines 85-91 Link Here
85
                    [% IF ( GoogleJackets ) %]
85
                    [% IF ( GoogleJackets ) %]
86
                        <div title="[% biblio.biblionumber %]" class="[% normalized_isbn %]" id="gbs-thumbnail-preview"></div>
86
                        <div title="[% biblio.biblionumber %]" class="[% normalized_isbn %]" id="gbs-thumbnail-preview"></div>
87
                    [% END %]
87
                    [% END %]
88
                    [% IF ( Koha.Preference('Coce') && Koha.Preference('CoceProviders') ) %]
88
                    [% IF ( Koha.Preference('OpacCoce') && Koha.Preference('CoceProviders') ) %]
89
                      [% coce_id = normalized_ean || normalized_isbn %]
89
                      [% coce_id = normalized_ean || normalized_isbn %]
90
                      <div style="block" title="[% biblio.biblionumber %]" class="[% coce_id %]" id="coce-thumbnail-preview"></div>
90
                      <div style="block" title="[% biblio.biblionumber %]" class="[% coce_id %]" id="coce-thumbnail-preview"></div>
91
                    [% END %]
91
                    [% END %]
Lines 1541-1547 Link Here
1541
    [% IF ( GoogleJackets ) %]
1541
    [% IF ( GoogleJackets ) %]
1542
        KOHA.Google.GetCoverFromIsbn([% covernewwindow %]);
1542
        KOHA.Google.GetCoverFromIsbn([% covernewwindow %]);
1543
    [% END %]
1543
    [% END %]
1544
    [% IF ( Koha.Preference('Coce') && Koha.Preference('CoceProviders') ) %]
1544
    [% IF ( Koha.Preference('OpacCoce') && Koha.Preference('CoceProviders') ) %]
1545
        KOHA.coce.getURL('[% Koha.Preference('CoceHost') %]', '[% Koha.Preference('CoceProviders') %]',[% covernewwindow %]);
1545
        KOHA.coce.getURL('[% Koha.Preference('CoceHost') %]', '[% Koha.Preference('CoceProviders') %]',[% covernewwindow %]);
1546
    [% END %]
1546
    [% END %]
1547
1547
Lines 1616-1622 Link Here
1616
                    [% IF ( GoogleJackets ) %]
1616
                    [% IF ( GoogleJackets ) %]
1617
                      KOHA.Google.GetCoverFromIsbn([% covernewwindow %]);
1617
                      KOHA.Google.GetCoverFromIsbn([% covernewwindow %]);
1618
                    [% END %]
1618
                    [% END %]
1619
                    [% IF ( Koha.Preference('Coce') && Koha.Preference('CoceProviders') ) %]
1619
                    [% IF ( Koha.Preference('OpacCoce') && Koha.Preference('CoceProviders') ) %]
1620
                      KOHA.coce.getURL('[% Koha.Preference('CoceHost') %]', '[% Koha.Preference('CoceProviders') %]',[% covernewwindow %]);
1620
                      KOHA.coce.getURL('[% Koha.Preference('CoceHost') %]', '[% Koha.Preference('CoceProviders') %]',[% covernewwindow %]);
1621
                    [% END %]
1621
                    [% END %]
1622
                    [% IF OpenLibraryCovers %]
1622
                    [% IF OpenLibraryCovers %]
Lines 1642-1648 Link Here
1642
                    [% IF ( GoogleJackets ) %]
1642
                    [% IF ( GoogleJackets ) %]
1643
                      KOHA.Google.GetCoverFromIsbn([% covernewwindow %]);
1643
                      KOHA.Google.GetCoverFromIsbn([% covernewwindow %]);
1644
                    [% END %]
1644
                    [% END %]
1645
                    [% IF ( Koha.Preference('Coce') && Koha.Preference('CoceProviders') ) %]
1645
                    [% IF ( Koha.Preference('OpacCoce') && Koha.Preference('CoceProviders') ) %]
1646
                      KOHA.coce.getURL('[% Koha.Preference('CoceHost') %]', '[% Koha.Preference('CoceProviders') %]',[% covernewwindow %]);
1646
                      KOHA.coce.getURL('[% Koha.Preference('CoceHost') %]', '[% Koha.Preference('CoceProviders') %]',[% covernewwindow %]);
1647
                    [% END %]
1647
                    [% END %]
1648
                    [% IF OpenLibraryCovers %]
1648
                    [% IF OpenLibraryCovers %]
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-results.tt (-3 / +2 lines)
Lines 255-261 Link Here
255
                                                            [% END %]
255
                                                            [% END %]
256
                                                        [% END %]
256
                                                        [% END %]
257
257
258
                                                        [% IF ( Koha.Preference('Coce') && Koha.Preference('CoceProviders') ) %]
258
                                                        [% IF ( Koha.Preference('OpacCoce') && Koha.Preference('CoceProviders') ) %]
259
                                                          [% coce_id = SEARCH_RESULT.normalized_ean || SEARCH_RESULT.normalized_isbn %]
259
                                                          [% coce_id = SEARCH_RESULT.normalized_ean || SEARCH_RESULT.normalized_isbn %]
260
                                                          [% IF ( coce_id ) %]
260
                                                          [% IF ( coce_id ) %]
261
                                                            <span style="block" title="[% SEARCH_RESULT.biblionumber |url %]" class="[% coce_id %]" id="coce-thumbnail[% loop.count %]"></span>
261
                                                            <span style="block" title="[% SEARCH_RESULT.biblionumber |url %]" class="[% coce_id %]" id="coce-thumbnail[% loop.count %]"></span>
Lines 973-979 $(document).ready(function(){ Link Here
973
[% IF OpenLibraryCovers %]KOHA.OpenLibrary.GetCoverFromIsbn();[% END %]
973
[% IF OpenLibraryCovers %]KOHA.OpenLibrary.GetCoverFromIsbn();[% END %]
974
[% IF OPACLocalCoverImages %]KOHA.LocalCover.GetCoverFromBibnumber(false);[% END %]
974
[% IF OPACLocalCoverImages %]KOHA.LocalCover.GetCoverFromBibnumber(false);[% END %]
975
[% IF ( GoogleJackets ) %]KOHA.Google.GetCoverFromIsbn();[% END %]
975
[% IF ( GoogleJackets ) %]KOHA.Google.GetCoverFromIsbn();[% END %]
976
[% IF ( Koha.Preference('Coce') && Koha.Preference('CoceProviders') ) %]
976
[% IF ( Koha.Preference('OpacCoce') && Koha.Preference('CoceProviders') ) %]
977
    KOHA.coce.getURL('[% Koha.Preference('CoceHost') %]', '[% Koha.Preference('CoceProviders') %]');
977
    KOHA.coce.getURL('[% Koha.Preference('CoceHost') %]', '[% Koha.Preference('CoceProviders') %]');
978
[% END %]
978
[% END %]
979
979
980
- 

Return to bug 18421