Bugzilla – Attachment 117823 Details for
Bug 27851
Add Koha::Old::Checkouts->filter_by_todays_checkins method
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 27851: Use filter_by_todays_checkins in printslip.pl
Bug-27851-Use-filterbytodayscheckins-in-printslipp.patch (text/plain), 1.70 KB, created by
Katrin Fischer
on 2021-03-05 11:42:16 UTC
(
hide
)
Description:
Bug 27851: Use filter_by_todays_checkins in printslip.pl
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2021-03-05 11:42:16 UTC
Size:
1.70 KB
patch
obsolete
>From f31b5a678784be84e5481ede3c991ff1bf67990e Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Fri, 5 Mar 2021 11:44:42 +0100 >Subject: [PATCH] Bug 27851: Use filter_by_todays_checkins in printslip.pl > >Test plan: >No regression from bug 12224 test plan > >Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> >--- > members/printslip.pl | 17 +++-------------- > 1 file changed, 3 insertions(+), 14 deletions(-) > >diff --git a/members/printslip.pl b/members/printslip.pl >index c89765b65f..2d80f9c09d 100755 >--- a/members/printslip.pl >+++ b/members/printslip.pl >@@ -84,22 +84,11 @@ if ( $print eq 'checkinslip' ) { > my $checkinslip_branch = $session->param('branch') ? $session->param('branch') : $branch; > > # get today's checkins >- my $dtf = Koha::Database->new->schema->storage->datetime_parser; >- my $today = dt_from_string; >- my $today_start = $today->clone->set( hour => 0, minute => 0, second => 0 ); >- my $today_end = $today->clone->set( hour => 23, minute => 59, second => 0 ); >- $today_start = $dtf->format_datetime( $today_start ); >- $today_end = $dtf->format_datetime( $today_end ); >- my @todays_checkins = $patron->old_checkouts->search({ >- returndate => { >- '>=' => $today_start, >- '<=' => $today_end, >- }, >- branchcode => $checkinslip_branch, >- }); >+ my @itemnumbers = $patron->old_checkouts->search( { branchcode => $checkinslip_branch } ) >+ ->filter_by_todays_checkins->get_column('itemnumber'); > > my %loops = ( >- old_issues => [ map { $_->itemnumber } @todays_checkins ], >+ old_issues => \@itemnumbers, > ); > > my $letter = C4::Letters::GetPreparedLetter( >-- >2.11.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 27851
:
117800
|
117801
|
117802
|
117803
|
117822
|
117823
|
117824
|
117825
|
117826
|
117827
|
117828
|
117836
|
117837
|
117838
|
117839