Bugzilla – Attachment 137946 Details for
Bug 31183
Add Koha::Item::Transfers->filter_by_current
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 31183: Use filter_by_current in Koha::Holds->get_items_that_can_fill
Bug-31183-Use-filterbycurrent-in-KohaHolds-getitem.patch (text/plain), 1.28 KB, created by
Michal Urban
on 2022-07-20 17:07:25 UTC
(
hide
)
Description:
Bug 31183: Use filter_by_current in Koha::Holds->get_items_that_can_fill
Filename:
MIME Type:
Creator:
Michal Urban
Created:
2022-07-20 17:07:25 UTC
Size:
1.28 KB
patch
obsolete
>From 663a20139fd543cfa11db20a1967594f78ddd317 Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@theke.io> >Date: Mon, 18 Jul 2022 18:39:51 -0300 >Subject: [PATCH] Bug 31183: Use filter_by_current in > Koha::Holds->get_items_that_can_fill > >This patch makes the method use the new >Koha::Item::Transfers->filter_by_current one. > >To test: >1. Run: > $ kshell > k$ prove t/db_dependent/Koha/Holds.t >=> SUCCESS: Tests pass >2. Apply this patch >3. Repeat 1 >=> SUCCESS: Tests still pass >4. Sign off :-D > >Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> >Signed-off-by: Michal Urban <michalurban177@gmail.com> >--- > Koha/Holds.pm | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) > >diff --git a/Koha/Holds.pm b/Koha/Holds.pm >index 2a117f5f66..53a6a00715 100644 >--- a/Koha/Holds.pm >+++ b/Koha/Holds.pm >@@ -120,9 +120,7 @@ sub get_items_that_can_fill { > push @bibs_or_items, 'me.itemnumber' => { in => \@itemnumbers } if @itemnumbers; > push @bibs_or_items, 'me.biblionumber' => { in => \@biblionumbers } if @biblionumbers; > >- my @branchtransfers = Koha::Item::Transfers->search( >- { datearrived => undef }, >- { >+ my @branchtransfers = Koha::Item::Transfers->filter_by_current->search({}, { > columns => ['itemnumber'], > collapse => 1, > } >-- >2.25.1
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 31183
:
137851
|
137852
|
137853
|
137944
|
137945
|
137946
|
138887
|
138888
|
138889