From 4dbc20916402589e0fd8d8473b6b8c46cf351e79 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9rick?= Date: Fri, 21 Mar 2014 11:39:13 -0400 Subject: [PATCH] Show local cover image in the intranet biblio details page. Also, fix useless "No cover image" block when using Amazon and local cover images at the same time. http://bugs.koha-community.org/show_bug.cgi?id=11982 --- .../prog/en/modules/catalogue/detail.tt | 34 +++++++++++++++++--- koha-tmpl/opac-tmpl/ccsr/en/js/localcovers.js | 1 + koha-tmpl/opac-tmpl/prog/en/js/localcovers.js | 1 + 3 files changed, 32 insertions(+), 4 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt index e10d95f..e3ca17a 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt @@ -175,6 +175,9 @@ function verify_images() { [% IF ( LocalCoverImages && ! localimages.0 ) %] showNoImageMessage(); [% END %] + [% IF LocalCoverImages %] + KOHA.LocalCover.GetCoverFromBibnumber(true); + [% END %] }); [% IF ( AmazonCoverImages ) %]$(window).load(function() { @@ -366,8 +369,18 @@ function verify_images() { MARC Preview: Show [% IF ( holdcount ) %]Holds: [% holdcount %][% ELSE %][% END %] - [% IF ( AmazonCoverImages ) %]
- [% END %] + [% IF ( ( AmazonEnabled && AmazonCoverImages ) || LocalCoverImages ) %] +
+ [% IF ( LocalCoverImages ) %]
[% END %] + [% IF ( AmazonEnabled ) %][% IF ( AmazonCoverImages ) %][% END %][% END %] + [% END %] [% ELSE %]

[% title |html %]

@@ -430,8 +443,21 @@ function verify_images() {
-[% IF ( AmazonCoverImages ) %]
-
[% END %] + [% IF ( ( AmazonEnabled && AmazonCoverImages ) || LocalCoverImages ) %] +
+ [% IF ( LocalCoverImages ) %]
[% END %] + [% IF ( AmazonEnabled ) %][% IF ( AmazonCoverImages ) %] + [% END %][% END %] +
+ [% END %]