It would be nice if the longoverdue script took a list of branch codes as a value so that each library could have different settings for long overdue. Or nicer still if it was just built in to Koha's staff GUI.
+1 -- But would that be limiting based on the patron branch, the item branch, the issuing branch? The branch specified by circcontrol?
I would love to have the longoverdue script be granular to the issuing branch. It makes sense to me if a patron borrows materials from our branch, they need to follow our loan rules...including if an item is longoverdue and will get billed. This would be a great place to start I think.
It would be great if this is added to circ & fine. Consortium's with a number of defined items could set this up per library making life easier on the individual libraries. This would be fantastic for stand alone libraries as well. Please, please, please someone take this on! :~D
Bug 31157 created a system preference to determine which library's rules to follow when generating overdue notices and restrictions. I think it'd make sense to create a comparable system preference for long overdue notices. It wouldn't be *wrong* to make long overdues just follow the syspref for overdues, but it does feel like someone's going to come up with a compelling need for the distinction sooner or later.
Created attachment 162070 [details] [review] Add branch and skip-branch options to cronjobs/longoverdue.pl Test plan: 1. apply patch 2. identify two books at different branches the same number of days overdue. 3. run the longoverdue.pl script specifying one of the branches in the --branch command line parameter. 4. observe that the book at the specified branch has been or would be affected by the script while the other book is not.
Michael, great to see a patch here! Is this ready for testing?
Yes. Sorry, I forgot to change the status to Needs Signoff. I'll set that now.
Thanks Michael, this looks good and works as described. You just need to fix your commit message and perltidy.
Created attachment 162250 [details] [review] Bug 9596: Add branch and skip-branch options to cronjobs/longoverdue.pl [ Tidied and commit message fixed ] This script doesn't seem to be included in cron files by default. This change is to allow script parameters to effect only certain branches. This allows the script to be added multiple times to a cron file with different settings for different branches. Test plan: 1. apply patch 2. identify two books at different branches the same number of days overdue. 3. run the longoverdue.pl script specifying one of the branches in the --branch command line parameter. i.e. koha-shell -c 'misc/cronjobs/longoverdue.pl --branch branch_code --lost 60=2 --maxdays=61 --confirm' instance_name 4. observe that the book at the specified branch has been or would be affected by the script while the other book is not.