When HoldsLog is set to "Log," holds that are manually unsuspended by staff or patrons are logged in action_logs, but holds unsuspended by auto_unsuspend_holds.pl are not.
This has the side-effect of having holds resuming by the auto_unsuspend_holds.pl script not logging.
Created attachment 84999 [details] [review] Bug 21765: Regression tests
Created attachment 85000 [details] [review] Bug 21765: Make AutoUnsuspendReserves call Koha::Hold->resume This patch makes the mentioned method use the biult-in method for resuming a suspended hold, instead of manually setting the specific attributes using the accessors. The side effect for this is that HoldsLog is now honoured. This patchset also refactors the tests a bit so they rely on the exposed methods and thus don't rely on specific implementation details (like suspended hold means a date in suspended_until plus suspended=1). To test: - Apply the regression tests patch - Run: $ kshell k$ prove t/db_dependent/Reserves/AutoUnsuspendReserves.t => FAIL: It fails loudly because things are done manually - Apply this patch - Run: k$ prove t/db_dependent/Reserves/AutoUnsuspendReserves.t => SUCCESS: Tests pass!
Created attachment 85007 [details] [review] Bug 21765: Regression tests Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Created attachment 85008 [details] [review] Bug 21765: Make AutoUnsuspendReserves call Koha::Hold->resume This patch makes the mentioned method use the biult-in method for resuming a suspended hold, instead of manually setting the specific attributes using the accessors. The side effect for this is that HoldsLog is now honoured. This patchset also refactors the tests a bit so they rely on the exposed methods and thus don't rely on specific implementation details (like suspended hold means a date in suspended_until plus suspended=1). To test: - Apply the regression tests patch - Run: $ kshell k$ prove t/db_dependent/Reserves/AutoUnsuspendReserves.t => FAIL: It fails loudly because things are done manually - Apply this patch - Run: k$ prove t/db_dependent/Reserves/AutoUnsuspendReserves.t => SUCCESS: Tests pass! Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Created attachment 85386 [details] [review] Bug 21765: Regression tests Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Created attachment 85387 [details] [review] Bug 21765: Make AutoUnsuspendReserves call Koha::Hold->resume This patch makes the mentioned method use the biult-in method for resuming a suspended hold, instead of manually setting the specific attributes using the accessors. The side effect for this is that HoldsLog is now honoured. This patchset also refactors the tests a bit so they rely on the exposed methods and thus don't rely on specific implementation details (like suspended hold means a date in suspended_until plus suspended=1). To test: - Apply the regression tests patch - Run: $ kshell k$ prove t/db_dependent/Reserves/AutoUnsuspendReserves.t => FAIL: It fails loudly because things are done manually - Apply this patch - Run: k$ prove t/db_dependent/Reserves/AutoUnsuspendReserves.t => SUCCESS: Tests pass! Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Awesome work all! Pushed to master for 19.05
Pushed to 18.11.x for 18.11.04 - I considered the lack of an action log in this case a bug the overriding factor here and so switch back from 'enhancement' to 'bug'.
Pushed to 18.05.x for 18.05.11