Bugzilla – Attachment 135546 Details for
Bug 30876
recalls/recalls_to_pull.pl introduces an incorrect use of ->search in list context
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 30876: Use Koha::Biblio
Bug-30876-Use-KohaBiblio.patch (text/plain), 1.53 KB, created by
Tomás Cohen Arazi (tcohen)
on 2022-06-01 13:29:53 UTC
(
hide
)
Description:
Bug 30876: Use Koha::Biblio
Filename:
MIME Type:
Creator:
Tomás Cohen Arazi (tcohen)
Created:
2022-06-01 13:29:53 UTC
Size:
1.53 KB
patch
obsolete
>From 5644e97fe3b385d7fc9f99840bf7a19add4927ef Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Wed, 1 Jun 2022 13:59:09 +0200 >Subject: [PATCH] Bug 30876: Use Koha::Biblio > >Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >--- > recalls/recalls_to_pull.pl | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > >diff --git a/recalls/recalls_to_pull.pl b/recalls/recalls_to_pull.pl >index e2f7d0e15a..06a14c5ea3 100755 >--- a/recalls/recalls_to_pull.pl >+++ b/recalls/recalls_to_pull.pl >@@ -57,6 +57,7 @@ if ( $op eq 'list' ) { > $seen_bib{$recall->biblio_id}++; > > # get recall data about this biblio >+ my $biblio = Koha::Biblios->find($recall->biblio_id); > my @this_bib_recalls = Koha::Recalls->search({ biblio_id => $recall->biblio_id, status => [ 'requested','overdue','in_transit' ] }, { order_by => { -asc => 'created_date' } })->as_list; > my $recalls_count = scalar @this_bib_recalls; > my @unique_patrons = do { my %seen; grep { !$seen{$_->patron_id}++ } @this_bib_recalls }; >@@ -71,7 +72,7 @@ if ( $op eq 'list' ) { > my @locations; > my @libraries; > >- my @items = Koha::Items->search({ biblio_id => $recall->biblio_id })->as_list; >+ my @items = $biblio->items->as_list; > foreach my $item ( @items ) { > if ( $item->can_be_waiting_recall and !$item->checkout ) { > # if item can be pulled to fulfill recall, collect item data >-- >2.34.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 30876
:
135534
|
135535
|
135536
| 135546 |
135547