Bug 31969: Use filter_by_last_update
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Wed, 23 Nov 2022 08:53:31 +0000 (09:53 +0100)
committerTomas Cohen Arazi <tomascohen@theke.io>
Fri, 25 Nov 2022 12:40:09 +0000 (09:40 -0300)
commit404c88fe87b27e4b4578e0bb6df2252a0bad9ed1
tree0dd56a70e8a5f390029601e40fc3ed5910785108
parent11918dcb72ad18d5bf6b7c95b7ed2976f521a459
Bug 31969: Use filter_by_last_update

This script has a pattern to delete rows depending on a given
date/number of days, we should use the filter_by_last_update
Koha::Objects method.
No need for another method and tests, everything is already tested
there.

This patch also suggests to rename the reference to "background" and
"bg" with "jobs", which seems more appropriate and not an abbreviation

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Koha/BackgroundJobs.pm
misc/cronjobs/cleanup_database.pl
t/db_dependent/Koha/BackgroundJobs.t