Bugzilla – Attachment 83665 Details for
Bug 18355
Add 'permanent location' alongside 'shelving location' when located on cart
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 18355: Update opac-detail.pl/tt to show both
Bug-18355-Update-opac-detailpltt-to-show-both.patch (text/plain), 4.48 KB, created by
José-Mario Monteiro-Santos
on 2019-01-04 21:33:04 UTC
(
hide
)
Description:
Bug 18355: Update opac-detail.pl/tt to show both
Filename:
MIME Type:
Creator:
José-Mario Monteiro-Santos
Created:
2019-01-04 21:33:04 UTC
Size:
4.48 KB
patch
obsolete
>From a694b244579fb54e86324ef93354972fe240dc7e Mon Sep 17 00:00:00 2001 >From: Christopher Brannon <cbrannon@cdalibrary.org> >Date: Fri, 5 Oct 2018 22:45:45 +0000 >Subject: [PATCH] Bug 18355: Update opac-detail.pl/tt to show both > >Adding dependancy of bug 21503 for templates to fully fail correctly. > >To Test this patch: > >1) Apply patch / restart_all >2) Check out an item. >3) Check item in with ReturnToShelvingCart set to Move. >4) View the item in opac-detail.pl and see the permanent location, and >the cart location in parentesis. >5) Try removing opac description from the cart and item sleving >location. Refresh opac-detail.pl. Should default to regular >description. (If not, may need patch 21503 to test.) >6) To test for code replacement if regular and opac description are >missing, you WILL need patch 21503. > >Signed-off-by: Jose-Mario <jose-mario.monteiro-santos@inLibro.com> >--- > koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt | 14 ++++++++++++-- > opac/opac-detail.pl | 3 --- > 2 files changed, 12 insertions(+), 5 deletions(-) > >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 955a2f4..8cd8dca 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt >@@ -1247,7 +1247,12 @@ > <div class="branch-info-tooltip">[% ITEM_RESULT.holding_branch_opac_info | $raw %]</div> > > [% IF ( Koha.Preference('OpacLocationOnDetail') == 'holding' || Koha.Preference('OpacLocationOnDetail') == 'both' ) %] >- <span class="shelvingloc">[% ITEM_RESULT.location_description | html %]</span> >+ <span class="shelvingloc"> >+ [% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.location', authorised_value => ITEM_RESULT.permanent_location, opac => '1' ) | html %] >+ [% IF ITEM_RESULT.location AND ITEM_RESULT.location != ITEM_RESULT.permanent_location %] >+ ([% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.location', authorised_value => ITEM_RESULT.location, opac => '1' ) | html %]) >+ [% END %] >+ </span> > [% END %] > > </td> >@@ -1272,7 +1277,12 @@ > <div class="branch-info-tooltip">[% ITEM_RESULT.home_branch_opac_info | $raw %]</div> > > [% IF ( Koha.Preference('OpacLocationOnDetail') == 'home' || Koha.Preference('OpacLocationOnDetail') == 'both' ) %] >- <span class="shelvingloc">[% ITEM_RESULT.location_description | html %]</span> >+ <span class="shelvingloc"> >+ [% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.location', authorised_value => ITEM_RESULT.permanent_location, opac => '1' ) | html %] >+ [% IF ITEM_RESULT.location AND ITEM_RESULT.location != ITEM_RESULT.permanent_location %] >+ ([% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.location', authorised_value => ITEM_RESULT.location, opac => '1' ) | html %]) >+ [% END %] >+ </span> > [% END %] > > </td> >diff --git a/opac/opac-detail.pl b/opac/opac-detail.pl >index a7c24ef..794f8c1 100755 >--- a/opac/opac-detail.pl >+++ b/opac/opac-detail.pl >@@ -694,9 +694,6 @@ if ( not $viewallitems and @items > $max_items_to_display ) { > $itm->{'ccode'} = $collections->{$ccode} if defined($ccode) && $collections && exists( $collections->{$ccode} ); > my $copynumber = $itm->{'copynumber'}; > $itm->{'copynumber'} = $copynumbers->{$copynumber} if ( defined($copynumbers) && defined($copynumber) && exists( $copynumbers->{$copynumber} ) ); >- if ( defined $itm->{'location'} ) { >- $itm->{'location_description'} = $shelflocations->{ $itm->{'location'} }; >- } > if (exists $itm->{itype} && defined($itm->{itype}) && exists $itemtypes->{ $itm->{itype} }) { > $itm->{'imageurl'} = getitemtypeimagelocation( 'opac', $itemtypes->{ $itm->{itype} }->{'imageurl'} ); > $itm->{'description'} = $itemtypes->{ $itm->{itype} }->{translated_description}; >-- >2.7.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 18355
:
61978
|
61981
|
61984
|
62999
|
66432
|
66514
|
78584
|
78908
|
78913
|
79684
|
79717
|
79786
|
80153
|
83665
|
95775
|
95879
|
95880