Bugzilla – Attachment 78548 Details for
Bug 7534
Add an option on library level to indicate if a library can be chosen as pick-up location
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 7534: (QA follow-up) Use Koha.Preference template plugin to fetch the pref's value
Bug-7534-QA-follow-up-Use-KohaPreference-template-.patch (text/plain), 3.20 KB, created by
Jonathan Druart
on 2018-09-10 20:46:01 UTC
(
hide
)
Description:
Bug 7534: (QA follow-up) Use Koha.Preference template plugin to fetch the pref's value
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2018-09-10 20:46:01 UTC
Size:
3.20 KB
patch
obsolete
>From 2430acd7851ae4b2121a6a9bd01ad5e4f1f8d880 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Mon, 10 Sep 2018 13:45:32 -0700 >Subject: [PATCH] Bug 7534: (QA follow-up) Use Koha.Preference template plugin > to fetch the pref's value > >Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >--- > koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt | 4 ++-- > opac/opac-reserve.pl | 7 +------ > 2 files changed, 3 insertions(+), 8 deletions(-) > >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt >index d1bf7ee78a..aca8342f30 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt >@@ -221,7 +221,7 @@ > > > [% UNLESS ( singleBranchMode ) %] >- [% IF ( bibitemloo.holdable && choose_branch ) %] >+ [% IF ( bibitemloo.holdable && Koha.Preference('OPACAllowUserToChooseBranch')) %] > <li class="branch"> > <label for="branch_[% bibitemloo.biblionumber | html %]">Pick up location:</label> > [% UNLESS ( bibitemloo.holdable ) %] >@@ -248,7 +248,7 @@ > [% END %] > [% END # / UNLESS bibitemloo.holdable %] > </li> >- [% END # / IF bibitemloo.holdable && choose_branch %] >+ [% END # / IF bibitemloo.holdable && Koha.Preference('OPACAllowUserToChooseBranch') %] > [% END # / UNLESS singleBranchMode %] > </ul> > >diff --git a/opac/opac-reserve.pl b/opac/opac-reserve.pl >index 684e57d1c3..153a1be6a7 100755 >--- a/opac/opac-reserve.pl >+++ b/opac/opac-reserve.pl >@@ -140,11 +140,6 @@ if (($#biblionumbers < 0) && (! $query->param('place_reserve'))) { > my $branch = $query->param('branch') || $patron->branchcode || C4::Context->userenv->{branch} || '' ; > $template->param( branch => $branch ); > >-# Is the person allowed to choose their branch >-my $OPACChooseBranch = (C4::Context->preference("OPACAllowUserToChooseBranch")) ? 1 : 0; >- >-$template->param( choose_branch => $OPACChooseBranch); >- > # > # > # Build hashes of the requested biblio(item)s and items. >@@ -240,7 +235,7 @@ if ( $query->param('place_reserve') ) { > my $canreserve = 0; > > my $singleBranchMode = Koha::Libraries->search->count == 1; >- if ( $singleBranchMode || !$OPACChooseBranch ) >+ if ( $singleBranchMode || ! C4::Context->preference("OPACAllowUserToChooseBranch") ) > { # single branch mode or disabled user choosing > $branch = $patron->branchcode; > } >-- >2.11.0
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 7534
:
60014
|
60015
|
60016
|
60017
|
60018
|
60022
|
60023
|
60781
|
60794
|
60795
|
60796
|
60797
|
60798
|
60799
|
60878
|
60879
|
60880
|
60881
|
60882
|
60883
|
61044
|
61045
|
61046
|
61047
|
61273
|
61274
|
61275
|
61276
|
61277
|
61278
|
61279
|
61280
|
77847
|
77848
|
77849
|
77850
|
77851
|
77852
|
77853
|
77854
|
77855
|
77856
|
78160
|
78161
|
78162
|
78163
|
78164
|
78165
|
78166
|
78167
|
78168
|
78169
|
78170
|
78171
|
78477
|
78478
|
78479
|
78480
|
78481
|
78482
|
78483
|
78484
|
78485
|
78486
|
78487
|
78488
|
78489
|
78495
|
78540
| 78548 |
84852