Bugzilla – Attachment 60854 Details for
Bug 18150
CanItemBeReserved doesn't work with (IndependentBranches AND ! canreservefromotherbranches)
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[SIGNED OFF] Bug 18150 - CanItemBeReserved doesn't work with (IndependentBranches AND ! canreservefromotherbranches)
SIGNED-OFF-Bug-18150---CanItemBeReserved-doesnt-wo.patch (text/plain), 1.53 KB, created by
Christopher Brannon
on 2017-03-06 23:39:12 UTC
(
hide
)
Description:
[SIGNED OFF] Bug 18150 - CanItemBeReserved doesn't work with (IndependentBranches AND ! canreservefromotherbranches)
Filename:
MIME Type:
Creator:
Christopher Brannon
Created:
2017-03-06 23:39:12 UTC
Size:
1.53 KB
patch
obsolete
>From eb05a63faf867e7af0de300f5b59740b17c4ea9c Mon Sep 17 00:00:00 2001 >From: Nicolas Legrand <nicolas.legrand@bulac.fr> >Date: Wed, 22 Feb 2017 10:11:18 +0100 >Subject: [PATCH] [SIGNED OFF] Bug 18150 - CanItemBeReserved doesn't work with > (IndependentBranches AND ! canreservefromotherbranches) > >The variable $item used to be a hash, but at the end of the function, >it's a Koha object. As $item->{homebranch} doesn't yield anything and >should be $item->homebranch. It prevents people using different >branches without holds between branches from placing a hold on an item >they should be able to place hold on. > >Test plan: > >1. Before patch > > a. with IndependantBranches off > b. try to place hold on an item you should be able to place hold on > c. it should work > d. put IndependantBranches on and canreservefromotherbranches off > e. shouldn't work > >2. after patches redo steps from (1) and everything should be working >fine. > >Signed-off-by: Your Full Name <your_email> >--- > C4/Reserves.pm | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/C4/Reserves.pm b/C4/Reserves.pm >index c078af1..8c4175d 100644 >--- a/C4/Reserves.pm >+++ b/C4/Reserves.pm >@@ -581,7 +581,7 @@ sub CanItemBeReserved { > if ( C4::Context->preference('IndependentBranches') > and !C4::Context->preference('canreservefromotherbranches') ) > { >- my $itembranch = $item->{homebranch}; >+ my $itembranch = $item->homebranch; > if ( $itembranch ne $borrower->{branchcode} ) { > return 'cannotReserveFromOtherBranches'; > } >-- >2.1.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 18150
:
60542
|
60853
|
60854
|
60901