https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26831
--- Comment #1 from Alex Buckley <[email protected]> --- Created attachment 112634 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=112634&action=edit Bug 26831: Add a system preference to define the number of days used for purging unaccepted list share invites in cleanup_database.pl The PurgeUnacceptedListShareInvitesOlderThan system preference value is used whenever the cleanup_database.pl cron job is called without the --list-invites parameter. If neither the system preference or the --list-invites parameter has a value then the cronjob errors out. Test plan: 1. Apply patch 2. Update database: sudo koha-shell <instancename> cd installer/data/mysql ./updatedatabase.pl 3. Confirm the default value of the PurgeUnacceptedListShareInvitesOlderThan system preference is 14 4. Run the cleanup_database.pl script without the --list-invites parameter: sudo koha-shell <instancename> cd misc/cronjobs ./cleanup_database.pl -v 5. Confirm the following text is included in the output: "Purging unaccepted list share invites older than 14 days." 6. Clear the aforementioned system preference. Run the cleanup_database.pl cron job with the --list-invites parameter defined: ./cleanup_database.pl --list-invites 10 -v 7. Confirm the following text is included in the output: "Purging unaccepted list share invites older than 10 days." 8. Input a value of 20 into the aforementioned system preference. Run the cron job with --list-invites defined: ./cleanup_database.pl --list-invites 10 -v 9. Confirm the following text is included in the output: "Purging unaccepted list share invites older than 10 days." 10. Clear the aforementioned system preference value and run the cron job without the --list-invites parameter: ./cleanup_database.pl -v 11. Confirm the following text is included in the output: "You did not specify any cleanup work for the script to do" Sponsored-by: Catalyst IT -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
