Bugzilla – Attachment 32197 Details for
Bug 11126
Make the holds system optionally give precedence to local holds
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 11126: qa follow-up
Bug-11126-qa-follow-up.patch (text/plain), 2.21 KB, created by
Jonathan Druart
on 2014-10-10 19:13:41 UTC
(
hide
)
Description:
Bug 11126: qa follow-up
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2014-10-10 19:13:41 UTC
Size:
2.21 KB
patch
obsolete
>From f3528370467521216acd41e9a357f4838b3ae6af Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@biblibre.com> >Date: Fri, 10 Oct 2014 20:53:50 +0200 >Subject: [PATCH] Bug 11126: qa follow-up > >- use Modern::Perl; >- fix a typo >- remove an old comment > >Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> >--- > C4/Reserves.pm | 5 +---- > t/db_dependent/Holds/LocalHoldsPriority.t | 5 ++--- > 2 files changed, 3 insertions(+), 7 deletions(-) > >diff --git a/C4/Reserves.pm b/C4/Reserves.pm >index c4fe7c0..032e044 100644 >--- a/C4/Reserves.pm >+++ b/C4/Reserves.pm >@@ -976,13 +976,10 @@ sub CheckReserves { > if ( $res->{'itemnumber'} == $itemnumber && $res->{'priority'} == 0) { > return ( "Waiting", $res, \@reserves ); # Found it > } else { >- # Lazy fetch for borrower and item. We only need to know about the patron and item >- # each and every time if we are using LocalHoldsPriority. This is a great place to >- # leverage the inherent lazy fetching of DBIx::Class. > my $borrowerinfo; > my $iteminfo; >- > my $local_hold_match; >+ > if ($LocalHoldsPriority) { > $borrowerinfo = C4::Members::GetMember( borrowernumber => $res->{'borrowernumber'} ); > $iteminfo = C4::Items::GetItem($itemnumber); >diff --git a/t/db_dependent/Holds/LocalHoldsPriority.t b/t/db_dependent/Holds/LocalHoldsPriority.t >index 2e092b2..d46ba8b 100755 >--- a/t/db_dependent/Holds/LocalHoldsPriority.t >+++ b/t/db_dependent/Holds/LocalHoldsPriority.t >@@ -1,7 +1,6 @@ > #!/usr/bin/perl > >-use strict; >-use warnings; >+use Modern::Perl; > > use t::lib::Mocks; > use C4::Context; >@@ -83,7 +82,7 @@ my ($status, $reserve, $all_reserves); > > t::lib::Mocks::mock_preference( 'LocalHoldsPriority', 0 ); > ($status, $reserve, $all_reserves) = CheckReserves($itemnumber); >-ok( $reserve->{borrowernumber} eq $borrowernumbers[0], "Recieved expected results with LocalHoldsPriority disabled" ); >+ok( $reserve->{borrowernumber} eq $borrowernumbers[0], "Received expected results with LocalHoldsPriority disabled" ); > > t::lib::Mocks::mock_preference( 'LocalHoldsPriority', 1 ); > >-- >2.1.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 11126
:
22328
|
22329
|
22543
|
22778
|
22784
|
24195
|
25589
|
28145
|
28146
|
28181
|
28182
|
30215
|
30216
|
32189
|
32191
|
32192
|
32193
|
32195
|
32196
| 32197