Bugzilla – Attachment 77423 Details for
Bug 21075
AutoUnsuspendHolds should unsuspend holds <= today
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 21075: AutoUnsuspendHolds should unsuspend holds <= today
Bug-21075-AutoUnsuspendHolds-should-unsuspend-hold.patch (text/plain), 1.44 KB, created by
Katrin Fischer
on 2018-08-02 11:27:56 UTC
(
hide
)
Description:
Bug 21075: AutoUnsuspendHolds should unsuspend holds <= today
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2018-08-02 11:27:56 UTC
Size:
1.44 KB
patch
obsolete
>From c2783ce02fdc4e35db2f2ded1e447b4c86bdef3f Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Fri, 13 Jul 2018 14:45:55 +0000 >Subject: [PATCH] Bug 21075: AutoUnsuspendHolds should unsuspend holds <= today > >To recreate: > 1 - Place a hold in your system > 2 - Set that hold (or all holds) to expire today > update reserves set suspend_until=CONCAT( CURDATE()," 00:00:00"); > 3 - Run misc/cronjobs/holds/auto_unsuspend_holds.p > 4 - Note the hold is sitll suspended > 5 - Visit /cgi-bin/koha/reserve/request.pl for the book with the hold > 6 - Note the suspend date is tomorrow (and cannot be set to today] > 7 - Click update holds - the date in db is now set to tomorrow > 8 - Reset to today > 9 - Apply patch >10 - Run the cron again >11 - Visit the page and note hold is unsuspended > >Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> >--- > C4/Reserves.pm | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/C4/Reserves.pm b/C4/Reserves.pm >index 359fd98..ab901c8 100644 >--- a/C4/Reserves.pm >+++ b/C4/Reserves.pm >@@ -804,7 +804,7 @@ Unsuspends all suspended reserves with a suspend_until date from before today. > sub AutoUnsuspendReserves { > my $today = dt_from_string(); > >- my @holds = Koha::Holds->search( { suspend_until => { '<' => $today->ymd() } } ); >+ my @holds = Koha::Holds->search( { suspend_until => { '<=' => $today->ymd() } } ); > > map { $_->suspend(0)->suspend_until(undef)->store() } @holds; > } >-- >2.1.4
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 21075
:
76953
|
76954
|
76960
| 77423 |
77424