From bc96fe5b4185e1d52ab7050c3c63802006fa35fd Mon Sep 17 00:00:00 2001 From: Katrin Fischer Date: Mon, 4 Feb 2019 06:09:32 +0000 Subject: [PATCH] Bug 12318: Show shelving location on subscription tab in OPAC and staff MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit The shelving location can be helpful to locate an item in the library. Especially, if the library has decided not to create items for a subscription this information is currently not visible to the patron. To test: - Apply patch - Create a subscription, set location - View the subscription tab in detail and staff - Verify that the location now shows above the callnumber - Unset location in the subscription - Verify that the page still looks ok Signed-off-by: Mikaël Olangcay Brisebois Signed-off-by: Martin Renvoize Signed-off-by: Nick Clemens --- catalogue/detail.pl | 1 + koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt | 1 + koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt | 3 +++ opac/opac-detail.pl | 1 + 4 files changed, 6 insertions(+) diff --git a/catalogue/detail.pl b/catalogue/detail.pl index 154d63260a..27eb2787ce 100755 --- a/catalogue/detail.pl +++ b/catalogue/detail.pl @@ -180,6 +180,7 @@ foreach my $subscription (@subscriptions) { $cell{branchcode} = $subscription->{branchcode}; $cell{hasalert} = $subscription->{hasalert}; $cell{callnumber} = $subscription->{callnumber}; + $cell{location} = $subscription->{location}; $cell{closed} = $subscription->{closed}; #get the three latest serials. $serials_to_display = $subscription->{staffdisplaycount}; 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 c9bdb8c5a4..e555c53c42 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt @@ -657,6 +657,7 @@

At library: [% Branches.GetName(subscription.branchcode) || subscription.branchcode | html %]

[% END %] [% IF ( subscription.closed ) %]

This subscription is closed.

[% END %] + [% IF ( subscription.location ) %]

Location: [% AuthorisedValues.GetByCode( 'LOC', subscription.location ) | html %]

[% END %] [% IF ( subscription.callnumber ) %]

Callnumber: [% subscription.callnumber | html %]

[% END %] [% IF ( subscription.subscriptionnotes ) %]

[% subscription.subscriptionnotes | html | html_line_break %]

[% END %] [% IF ( subscription.missinglist ) %]

Missing issues: [% subscription.missinglist | html %]

[% END %] diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt index 4d1c98a7d1..23e175b262 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt @@ -810,6 +810,9 @@ [% IF ( subscription.closed ) %]

This subscription is closed.

[% END %] + [% IF ( subscription.location ) %] +

Location: [% AuthorisedValues.GetByCode( 'LOC', subscription.location ) | html %] + [% END %] [% IF ( subscription.callnumber ) %]

Call number: [% subscription.callnumber | html %]

[% END %] diff --git a/opac/opac-detail.pl b/opac/opac-detail.pl index 51fa3af040..751f80452e 100755 --- a/opac/opac-detail.pl +++ b/opac/opac-detail.pl @@ -594,6 +594,7 @@ foreach my $subscription (@subscriptions) { $cell{histenddate} = $subscription->{histenddate}; $cell{branchcode} = $subscription->{branchcode}; $cell{callnumber} = $subscription->{callnumber}; + $cell{location} = $subscription->{location}; $cell{closed} = $subscription->{closed}; $cell{letter} = $subscription->{letter}; $cell{biblionumber} = $subscription->{biblionumber}; -- 2.39.5