Bug 21543

Summary: Advanced Notice cron will try to send advance phone notices in the Talking Tech Sending Notices File
Product: Koha Reporter: Margaret Hade <margaret>
Component: NoticesAssignee: Bugs List <koha-bugs>
Status: NEW --- QA Contact: Testopia <testopia>
Severity: normal    
Priority: P5 - low    
Version: 17.11   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:

Description Margaret Hade 2018-10-10 18:50:20 UTC
The Advanced Notice (misc/cronjobs/advance_notices.pl) will try to send "advance notice of item due" phone notices which shouldn't be processed except by the Talking Tech Sending Notices File (misc/cronjobs/thirdparty/TalkingTech_itiva_outbound.pl)

In this case/to replicate:

1) A library is set up to use Advanced Notices and Talking Tech Sending/Receiving Notices File crons.
2) They want patrons to get advanced notice emails 7 days per week, but only get phone notices 5 days per week. 
3) When Advanced Notices cron runs on those other two days it will try to send the "advance notice of item due phone notices" to Talking Tech, which fails because the i-tiva server is not making calls on that day. 
4) The notices that Advanced Notice cron erroneously processed are forever stuck in pending status in the message queue. 

Can Advanced Notice cron be updated to not touch notices that are slated for processing by the Talking Tech Sending Notices File cron? 

TLDR: advance_notices.pl generates phone notices, these should only be generated by the talking tech crons. To recreate enable advanced messaging, set phone for advance notice for a patron and checkout an item that will trigger the notice, run advance_notices.pl, check the message queue and see a phone notice is pending.