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

(-)a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt (+13 lines)
Lines 104-109 Link Here
104
                                [% END %]
104
                                [% END %]
105
                            [% END %]
105
                            [% END %]
106
106
107
                            [% IF ( GoogleJackets ) %]
108
                                <div class="cover-image" id="googlejacket-coverimg">
109
                                    <div title="[% img_title | html %]" class="[% normalized_isbn | html %]" id="gbs-thumbnail-preview" data-use-data-link="1"></div>
110
                                    <div class="hint">Image from Google Jackets</div>
111
                                </div>
112
                            [% END %]
113
107
                            [% IF ( Koha.Preference('OPACCoce') && Koha.Preference('CoceProviders') && normalized_isbn ) %]
114
                            [% IF ( Koha.Preference('OPACCoce') && Koha.Preference('CoceProviders') && normalized_isbn ) %]
108
                                [% coce_id = normalized_ean || normalized_isbn %]
115
                                [% coce_id = normalized_ean || normalized_isbn %]
109
                                <div class="cover-image" id="coce-coverimg">
116
                                <div class="cover-image" id="coce-coverimg">
Lines 1647-1652 Link Here
1647
                [% END %]
1654
                [% END %]
1648
            [% END %]
1655
            [% END %]
1649
1656
1657
            [% IF ( GoogleJackets ) %]
1658
                KOHA.Google.GetCoverFromIsbn([% covernewwindow | html %]);
1659
            [% END %]
1660
1650
            [% IF ( Koha.Preference('OpacCoce') && Koha.Preference('CoceProviders') ) %]
1661
            [% IF ( Koha.Preference('OpacCoce') && Koha.Preference('CoceProviders') ) %]
1651
                KOHA.coce.getURL('[% Koha.Preference('CoceHost') | html %]', '[% Koha.Preference('CoceProviders') | html %]',[% covernewwindow | html %]);
1662
                KOHA.coce.getURL('[% Koha.Preference('CoceHost') | html %]', '[% Koha.Preference('CoceProviders') | html %]',[% covernewwindow | html %]);
1652
            [% END %]
1663
            [% END %]
Lines 1690-1695 Link Here
1690
                                }
1701
                                }
1691
                            } else if( div.attr("id") == "syndetics-coverimg" ){
1702
                            } else if( div.attr("id") == "syndetics-coverimg" ){
1692
                                lightbox_descriptions.push("Image from Syndetics")
1703
                                lightbox_descriptions.push("Image from Syndetics")
1704
                            } else if( div.attr("id") == "googlejacket-coverimg" ){
1705
                                lightbox_descriptions.push(_("Image from Google Jacket (<a href='%s'>see the original image</a>)").format($(img).data('link')));
1693
                            } else if( div.attr("id") == "coce-coverimg" ){
1706
                            } else if( div.attr("id") == "coce-coverimg" ){
1694
                                // Identify which service's image is being loaded by Coce
1707
                                // Identify which service's image is being loaded by Coce
1695
                                var coce_description;
1708
                                var coce_description;
(-)a/koha-tmpl/opac-tmpl/bootstrap/js/google-jackets.js (-16 / +23 lines)
Lines 46-67 KOHA.Google = { Link Here
46
         for (id in booksInfo) {
46
         for (id in booksInfo) {
47
             var book = booksInfo[id];
47
             var book = booksInfo[id];
48
             $("[id^=gbs-thumbnail]."+book.bib_key).each(function() {
48
             $("[id^=gbs-thumbnail]."+book.bib_key).each(function() {
49
                 var a = document.createElement("a");
50
                 a.href = book.info_url;
51
                 if (typeof(book.thumbnail_url) != "undefined") {
49
                 if (typeof(book.thumbnail_url) != "undefined") {
52
                     var img = document.createElement("img");
50
                     if ( $(this).data('use-data-link') ) {
53
                     img.src = book.thumbnail_url;
51
                         var a = document.createElement("a");
54
                     $(this).empty().append(img);
52
                         a.href = book.thumbnail_url;
55
                     var re = /^gbs-thumbnail-preview/;
53
                         var img = document.createElement("img");
56
                     if ( re.exec($(this).attr("id")) ) {
54
                         img.src = book.thumbnail_url;
57
                         $(this).append(
55
                         img.setAttribute('data-link', book.info_url);
58
                             '<div class="google-books-preview">' +
56
                         a.append(img)
59
                             '<a '+target+'href="' +
57
                         $(this).empty().append(a);
60
                             book.info_url +
58
                     } else {
61
                             '"><img src="' +
59
                         var img = document.createElement("img");
62
                             'https://books.google.com/intl/en/googlebooks/images/gbs_preview_sticker1.gif' +
60
                         img.src = book.thumbnail_url;
63
                             '"></a></div>'
61
                         $(this).empty().append(img);
64
                             );
62
                         var re = /^gbs-thumbnail-preview/;
63
                         if ( re.exec($(this).attr("id")) ) {
64
                             $(this).append(
65
                                 '<div class="google-books-preview">' +
66
                                 '<a '+target+'href="' +
67
                                 book.info_url +
68
                                 '"><img src="' +
69
                                 'https://books.google.com/intl/en/googlebooks/images/gbs_preview_sticker1.gif' +
70
                                 '"></a></div>'
71
                                 );
72
                         }
65
                     }
73
                     }
66
                 } else {
74
                 } else {
67
                     var message = document.createElement("span");
75
                     var message = document.createElement("span");
68
- 

Return to bug 28180