From aadc4b30dca24ca2f5d191231da214e56a4f8336 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. --- .../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 1e1fcd2..94d2db7 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt @@ -155,6 +155,9 @@ function verify_images() { return false; }); + [% IF LocalCoverImages %] + KOHA.LocalCover.GetCoverFromBibnumber(true); + [% END %] }); [% IF ( AmazonCoverImages ) %]$(window).load(function() { @@ -346,8 +349,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 %]

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