Bug 28553: Patrons can be set to receive auto_renew notices as SMS, but Koha does...
authorKyle M Hall <kyle@bywatersolutions.com>
Mon, 18 Jul 2022 16:37:48 +0000 (12:37 -0400)
committerTomas Cohen Arazi <tomascohen@theke.io>
Fri, 16 Sep 2022 13:30:40 +0000 (10:30 -0300)
commitfef29151e0dd6287f8e4e49effc9d9666bf87582
tree7152c44a7e31da512bb654dbf2c9bedd762ffc1f
parent4481817701f0789f407f8bdfdcaeeb49c5239e5e
Bug 28553: Patrons can be set to receive auto_renew notices as SMS, but Koha does not generate them

Following bug 18532, one can set a patron's messaging prefs to deliver an auto-renew notice via SMS.
However, the auto_renewals cron only knows how to generate email notices. We should not allow the selection of non-functional transport types.

Test Plan:
 1 - Set pref AutoRenewalNotices - 'according to patron messaging preferences'
 2 - Set circ rule with:
    Loan period: 5 days
    No renewal before: 5
    AutoRenewal: Yes
    Renewals allowed: 5
 3 - Set SMS Send driver to Email
 4 - Find a patron and set them to receive auto renewal notices via SMS and no other transport
 5 - Provide a proivder and sms number for the patron
 6 - Checkout an item to the patron, set due date to yesterday
 7 - Run auto renewals:
    perl misc/cronjobs/automatic_renewals.pl -v --send-notices -c
 8 - Item renewed, no message sent
 9 - Check in item, checkout again due yesterday
10 - Apply patch
11 - Browse to Tools->notices and slips
12 - Edit AUTO_RENEWALS and AUTO_RENEWALS_DIGEST to copy email template to sms and add a title
13 - perl misc/cronjobs/automatic_renewals.pl -v --send-notices -c
14 - Item renewed, confirm patron has a notice in their account
15 - Check the digest option, check in item, checkout again as due, repeat cronjob and note digest notic
16 - sign off

https://bugs.koha-community.org/show_bug.cgi?id=30355

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
misc/cronjobs/automatic_renewals.pl