Bug 5429 : Covers for detail page and database update

Signed-off-by: Magnus Enger <magnus@enger.priv.no>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
This commit is contained in:
Chris Cormack 2011-07-23 20:09:08 +12:00 committed by Chris Cormack
parent cbf473d592
commit c04c4265ad
2 changed files with 16 additions and 2 deletions

View file

@ -4384,6 +4384,13 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
SetVersion ($DBversion);
}
$DBversion = "3.05.00.XXX";
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
$dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpenLibraryCovers',0,'If ON Openlibrary book covers will be show',NULL,'YesNo');");
print "Upgrade to $DBversion done (Add syspref OpenLibraryCovers)\n";
SetVersion($DBversion);
}
=head1 FUNCTIONS
=head2 DropAllForeignKeys($table)

View file

@ -21,8 +21,14 @@
dateFormat: 'uk',[% END %]
widgets : ['zebra'],
sortList: [[0,0]]
});[% IF ( GoogleJackets ) %]
KOHA.Google.GetCoverFromIsbn([% covernewwindow %]);[% END %][% IF ( opacuserlogin ) %][% IF ( loggedinusername ) %][% IF ( TagsEnabled ) %]
});
[% IF ( GoogleJackets ) %]
KOHA.Google.GetCoverFromIsbn([% covernewwindow %]);
[% END %]
[% IF OpenLibraryCovers %]
KOHA.OpenLibrary.GetCoverFromIsbn();
[% END %]
[% IF ( opacuserlogin ) %][% IF ( loggedinusername ) %][% IF ( TagsEnabled ) %]
$(".tagbutton").click(KOHA.Tags.add_tag_button);[% END %][% END %][% END %]
});
@ -72,6 +78,7 @@ YAHOO.util.Event.onContentReady("furtherm", function () {
[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %][% END %]
[% IF ( GoogleJackets ) %]<div style="block" title="[% biblionumber |url %]" class="[% normalized_isbn %]" id="gbs-thumbnail-preview"></div>[% END %]
[% IF OpenLibraryCovers %]<div style="block" title="[% biblionumber |url %]" class="[% normalized_isbn %]" id="openlibrary-thumbnail-preview"></div>[% END %]
[% IF ( BakerTaylorEnabled ) %][% IF ( normalized_isbn ) %][% IF ( OPACurlOpenInNewWindow ) %]<a href="https://[% BakerTaylorBookstoreURL |html %][% normalized_isbn %]" target="_blank"><img alt="See Baker &amp; Taylor" src="[% BakerTaylorImageURL |html %][% normalized_isbn %]" /></a>[% ELSE %]<a href="https://[% BakerTaylorBookstoreURL |html %][% normalized_isbn %]"><img alt="See Baker &amp; Taylor" src="[% BakerTaylorImageURL |html %][% normalized_isbn %]" /></a>[% END %][% END %][% END %]
</div>