From 5721f183ee7f848077e9836bb96f3de90d5d6b3f Mon Sep 17 00:00:00 2001 From: Liz Rea Date: Tue, 29 May 2012 16:06:22 -0500 Subject: [PATCH] Bug 8129 - Quickslips not printing Implemented from the suggestions attached to the bug. To test: Check out a book to a patron Click print -> quick slip Slip should show only today's checkouts. Signed-off-by: Kyle M Hall Signed-off-by: Paul Poulain Signed-off-by: Chris Cormack --- C4/Members.pm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/C4/Members.pm b/C4/Members.pm index 693e0bac22..a291b76c56 100644 --- a/C4/Members.pm +++ b/C4/Members.pm @@ -2257,14 +2257,14 @@ sub IssueSlip { # return unless ( C4::Context->boolean_preference('printcirculationslips') ); - my $today = POSIX::strftime("%Y-%m-%d", localtime); + my $now = POSIX::strftime("%Y-%m-%d", localtime); my $issueslist = GetPendingIssues($borrowernumber); foreach my $it (@$issueslist){ - if ($it->{'issuedate'} eq $today) { - $it->{'today'} = 1; + if ((substr $it->{'issuedate'}, 0, 10) eq $now) { + $it->{'now'} = 1; } - elsif ($it->{'date_due'} le $today) { + elsif ((substr $it->{'date_due'}, 0, 10) le $now) { $it->{'overdue'} = 1; } @@ -2280,7 +2280,7 @@ sub IssueSlip { 'biblio' => $_, 'items' => $_, 'issues' => $_, - }, grep { $_->{'today'} } @issues ], + }, grep { $_->{'now'} } @issues ], ); } else { -- 2.39.5