Owen Leonard
3bd3ec4805
This patch modifies the biblio-title include so that it can be used to link to the bibliographic record using the default biblio view. On pages where the biblio-title include was wrapped in an anchor tag, a link parameter is added: [% INCLUDE 'biblio-title.inc' link=> 1 %] To test, apply the patch and view the following pages in the OPAC to confirm that titles are displayed correctly and that the link to the bibliographic record is correct: - Log in to the OPAC: On the "your summary" page, check checkouts, overdues, holds, and article requests. - Check the "your holds history" page. - Locate a bibliographic record and click "Save to your lists." In the popup, the title should be displayed correctly without a link. - Place a hold, and check the hold confirmation page. - Check the "Recent comments" page. - Locate a record which has a local cover image attached, and view the image. Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
124 lines
5.6 KiB
Text
124 lines
5.6 KiB
Text
[% USE Koha %]
|
|
[% USE AdditionalContents %]
|
|
[% SET OpacNav = AdditionalContents.get( location => "OpacNav", lang => lang, library => logged_in_user.branchcode || default_branch, blocktitle => 0 ) %]
|
|
[% SET OpacNavBottom = AdditionalContents.get( location => "OpacNavBottom", lang => lang, library => logged_in_user.branchcode || default_branch, blocktitle => 0 ) %]
|
|
[% INCLUDE 'doc-head-open.inc' %]
|
|
<title>Images for: [% INCLUDE 'biblio-title-head.inc' %] › [% IF ( LibraryNameTitle ) %][% LibraryNameTitle | html %][% ELSE %]Koha online[% END %] catalog</title>
|
|
[% INCLUDE 'doc-head-close.inc' %]
|
|
[% BLOCK cssinclude %]
|
|
<style>
|
|
#largeCoverImg {
|
|
border : 1px solid #CCCCCC;
|
|
display : block;
|
|
margin : auto;
|
|
padding : 1em;
|
|
}
|
|
#thumbnails {
|
|
text-align : center;
|
|
}
|
|
#thumbnails a img {
|
|
border : 2px solid #8EB3E7;
|
|
}
|
|
img.thumbnail {
|
|
display : block;
|
|
float : none;
|
|
margin : .3em 0;
|
|
padding : .5em;
|
|
}
|
|
|
|
#thumbnails a img.selected {
|
|
border-color: black;
|
|
cursor : default;
|
|
opacity:0.4;
|
|
filter:alpha(opacity=40); /* For IE8 and earlier */
|
|
}
|
|
</style>
|
|
[% END %]
|
|
</head>
|
|
[% INCLUDE 'bodytag.inc' bodyid='opac-imageviewer' %]
|
|
[% INCLUDE 'masthead.inc' %]
|
|
|
|
<div class="main">
|
|
<nav id="breadcrumbs" aria-label="Breadcrumb" class="breadcrumbs">
|
|
<ol class="breadcrumb">
|
|
<li class="breadcrumb-item">
|
|
<a href="/cgi-bin/koha/opac-main.pl">Home</a>
|
|
</li>
|
|
<li class="breadcrumb-item">
|
|
[% INCLUDE 'biblio-title.inc' %]
|
|
</li>
|
|
<li class="breadcrumb-item active">
|
|
<a href="#" aria-current="page">Images</a>
|
|
</li>
|
|
</ol>
|
|
</nav> <!-- /#breadcrumbs -->
|
|
|
|
<div class="container-fluid">
|
|
<div class="row">
|
|
[% IF ( OpacNav || OpacNavBottom ) %]
|
|
<div class="col-lg-2">
|
|
<div id="navigation">
|
|
[% INCLUDE 'navigation.inc' %]
|
|
</div>
|
|
</div>
|
|
<div class="col-10 order-first order-md-first order-lg-2">
|
|
[% ELSE %]
|
|
<div class="col order-first order-md-first order-lg-2">
|
|
[% END %]
|
|
|
|
<div class="row">
|
|
<div class="col-lg-9 maincontent">
|
|
<h1 class="title">Images for [% INCLUDE 'biblio-title.inc' link=> 1 %] [% biblio.author | html %]
|
|
</h1>
|
|
</div> <!-- / col-lg-9 -->
|
|
</div> <!-- / .row -->
|
|
|
|
<div class="row">
|
|
<div class="col-lg-9">
|
|
<div id="imageviewer">
|
|
<div id="largeCover">
|
|
<img id="largeCoverImg" alt="" src="/cgi-bin/koha/opac-image.pl?imagenumber=[% imagenumber | url %]" />
|
|
</div>
|
|
</div> <!-- / #imageviewer -->
|
|
</div> <!-- / .span12 -->
|
|
|
|
[% IF OPACLocalCoverImages == 1 %]
|
|
[% IF images.count %]
|
|
<div class="col-lg-3">
|
|
<div id="thumbnails">
|
|
[% FOREACH image IN images %]
|
|
<a href="/cgi-bin/koha/opac-imageviewer.pl?biblionumber=[% biblionumber | url %]&imagenumber=[% image.imagenumber| uri %]" onclick="showCover([% image.imagenumber| html %]); return false;">
|
|
[% IF loop.first %]
|
|
<img class="thumbnail selected" id="[% image.imagenumber| html %]" src="/cgi-bin/koha/opac-image.pl?imagenumber=[% image.imagenumber | html %]&thumbnail=1" alt="Thumbnail"/>
|
|
[% ELSE %]
|
|
<img class="thumbnail" id="[% image.imagenumber | html %]" src="/cgi-bin/koha/opac-image.pl?imagenumber=[% image.imagenumber | html %]&thumbnail=1" alt="Thumbnail"/>
|
|
[% END %]
|
|
</a>
|
|
[% END %]
|
|
</div> <!-- /#thumbnails -->
|
|
</div> <!-- /.col-lg-3 -->
|
|
[% END %]
|
|
[% ELSE %]
|
|
Unfortunately, images are not enabled for this catalog at this time.
|
|
[% END %]
|
|
</div> <!-- / .row -->
|
|
</div> <!-- / .col-lg-10/12 -->
|
|
</div> <!-- / .row -->
|
|
</div> <!-- / .container-fluid -->
|
|
</div> <!-- / .main -->
|
|
|
|
[% INCLUDE 'opac-bottom.inc' %]
|
|
[% BLOCK jsinclude %]
|
|
<script>
|
|
$(document).ready(function(){
|
|
$("#largeCoverImg").attr("src","[% interface | html %]/[% theme | html %]/images/loading.gif");
|
|
showCover([% imagenumber | html %]);
|
|
});
|
|
|
|
function showCover(img) {
|
|
$('.thumbnail').attr('class', 'thumbnail');
|
|
$('#largeCoverImg').attr('src', '/cgi-bin/koha/opac-image.pl?imagenumber=' + img);
|
|
$('#' + img + '.thumbnail').attr('class', 'thumbnail selected');
|
|
}
|
|
</script>
|
|
[% END %]
|