Bugzilla – Attachment 150865 Details for
Bug 33653
Search for late orders can show received order lines
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 33653: Use filter_by_active instead
Bug-33653-Use-filterbyactive-instead.patch (text/plain), 1.79 KB, created by
Tomás Cohen Arazi (tcohen)
on 2023-05-09 13:39:38 UTC
(
hide
)
Description:
Bug 33653: Use filter_by_active instead
Filename:
MIME Type:
Creator:
Tomás Cohen Arazi (tcohen)
Created:
2023-05-09 13:39:38 UTC
Size:
1.79 KB
patch
obsolete
>From 7baa89c37183392e15fba171fe34ea9abbb93016 Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@theke.io> >Date: Tue, 9 May 2023 10:36:40 -0300 >Subject: [PATCH] Bug 33653: Use filter_by_active instead > >This patch makes `filter_by_lates` use the `filter_by_active` method >instead of an ad-hoc query filter. It has the advantage that it >considers standing orders too. > >No behavior change, tests should still pass. > >Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> >--- > Koha/Acquisition/Orders.pm | 7 ++----- > acqui/lateorders.pl | 2 +- > 2 files changed, 3 insertions(+), 6 deletions(-) > >diff --git a/Koha/Acquisition/Orders.pm b/Koha/Acquisition/Orders.pm >index 5240d699a5f..2438886ac80 100644 >--- a/Koha/Acquisition/Orders.pm >+++ b/Koha/Acquisition/Orders.pm >@@ -130,10 +130,7 @@ sub filter_by_lates { > && !C4::Context->IsSuperLibrarian > ? ( 'borrower.branchcode' => C4::Context->userenv->{branch} ) > : () >- ), >- >- ( orderstatus => { '-not_in' => ['cancelled', 'complete'] } ), >- >+ ) > }, > { > '+select' => [ >@@ -145,7 +142,7 @@ sub filter_by_lates { > join => { 'basketno' => 'booksellerid' }, > prefetch => {'basketno' => 'booksellerid'}, > } >- ); >+ )->filter_by_active; > } > > =head3 filter_by_active >diff --git a/acqui/lateorders.pl b/acqui/lateorders.pl >index 7ce5683ae56..6e8dbb9269e 100755 >--- a/acqui/lateorders.pl >+++ b/acqui/lateorders.pl >@@ -50,7 +50,7 @@ use C4::Output qw( output_html_with_http_headers ); > use C4::Context; > use C4::Letters qw( SendAlerts GetLetters ); > use Koha::DateUtils qw( dt_from_string ); >-use Koha::Acquisition::Orders qw( filter_by_lates ); >+use Koha::Acquisition::Orders; > use Koha::CsvProfiles; > > my $input = CGI->new; >-- >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 33653
:
150582
|
150624
|
150669
|
150686
|
150821
|
150833
|
150834
| 150865