Koha/koha-tmpl/intranet-tmpl/prog/en/includes
Ian Walls d29efac4f3 Talking Tech Support - Phase I
Implements support for Talking Tech I-tiva phone notification for OVERDUE, PREDUE and HOLD notifications.
Overdues respect triggers as configured for the patron's branch.
Predue and Holds notifications respect patron's messaging preference choices.
A new column for phone notification is added if the TalkingTechItivaPhoneNotification system preference is turned on

Record of phone messages being sent to patrons is added to the patron's Notices
tab; notice of success or failure can be retrieved from I-tiva.

See the TalkingTech.README for installation and set-up instructions.

Aside from the control system preference, and the necessary changes to Messaging Preferences
forms to make use of phone notifications, the bulk of the code resides in external
cronjobs.

TalkingTech_itiva_outbound.pl generates the Spec C file to send to I-tiva.  Actual transmission
of the file must be handled by the system administrator.

TalkingTech_itiva_inbound.pl processes the received Results file from I-tiva.  Getting the
file from I-tiva to Koha is the job of the system administrator, as well.

Both scripts have a --help option with full documentation.

The only necessary change to core Koha behavior is in C4::Letters::EnqueueLetter.  The return
value was changed from 0 or 1 (successful addition of letter to message_queue or not), to the actual
insert ID of the letter.  This was required by the outbound script to present a unique Transaction ID
for the notice added to the patron's record (so a 'sent' or 'failed' status could be updated).  Since
the dbh and sth are not shared, and the last_insert_id() command is table-specific, this should be thread-safe.
No changes are necessary to any parts of Koha, as all usage of EnqueueLetter currently ignores the return value.

To Test:

1. Turn on TalkingTechItivaPhoneNotification system preference
2. Verify that 'phone' is now a valid notification option for patrons on both staff and OPAC side
3. Attempt to set a 'phone' preference for PREDUE or HOLD messaging; attempt should succeed
4. Set up the patron for notices to triggers:
   a. include checked out items due in a range of days, including the value set up in their messaging preferences.
   b. place several holds, some in position, others waiting for pickup, others in transit.
   c. set the patron up to have overdues, overdue by a range of days that includes the delay values for
the patrons branch and categorycode
5. Run TalkingTech_itiva_outbound.pl --type=RESERVE --type=PREOVERDUE --type=OVERDUE --outfile=/tmp/talkingtechtest.csv

The resulting talkingtechtest.csv file should include all the items due on X days (where X is the patrons' preference),
and none of the ones due in other increments.  Similarly, overdues messages should be added for each item due by a delay
value as configured; overdues of other numbers of days should be ignore.  Holds that are waiting pick up or in transit should
have messages, those still pending should not.

Messages should be added to the patron's notices tab for each issue sent.  Verify these messages exist, and all Notices
tokens are replaced with appropriate information.

Repeat, this time with 4c making use of the default branch overdue triggers, instead of branch-specific triggers.

To test the inbound script, create a CSV with rows in the format "<<Message_id>>","<<SUCCESS or FAIL>>"
Message ID should correspond to the final column of the talkingtechtest.csv file (the transaction id) for the message.

Primary Authorship: Ian Walls
Additional modifications: Kyle M Hall

http://bugs.koha-community.org/show_bug.cgi?id=4246
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>

Tested and in use in production by two public libraries : Middletown
and Washoe. Both have given their sign off, but don't have git to
actually sign off.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-06-10 17:46:52 +02:00
..
virtualshelves/merge
acquisitions-add-to-basket.inc Bug 2780 - Capitalize strings consistently 2012-04-04 17:51:23 +02:00
acquisitions-menu.inc Bug 8040: bad name in acquisitions-menu 2012-05-24 18:09:46 +02:00
acquisitions-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
acquisitions-toolbar.inc Bug 2780 - Capitalize strings consistently 2012-04-04 17:51:23 +02:00
additem-menu.inc Bug 2780 - Capitalize strings consistently (Cataloging) 2012-04-04 17:54:40 +02:00
additem.js.inc Bug 7178: Acquisition item creation improvement 2012-03-26 11:07:23 +02:00
admin-menu.inc Bug 8195: Selected link must be bold (in admin and tools) 2012-06-09 12:31:12 +02:00
auth-finder-search.inc Bug 7747 - Replace YUI autocomplete with jQueryUI 2012-05-31 18:07:55 +02:00
authorities-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
authorities-toolbar.inc Bug 2780 - Capitalize strings consistently 2012-04-04 17:51:24 +02:00
biblio-default-view.inc
biblio-view-menu.inc Bug 1633 - Interface revisions for the staff client 2012-01-24 11:16:09 +01:00
budgetperiods-admin.inc Bug 2780 - Capitalize strings consistently (Budgets) 2012-04-04 17:51:27 +02:00
budgets-active-currency.inc
budgets-admin-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
budgets-admin-toolbar.inc Bug 2780 - Capitalize strings consistently (Budgets) 2012-04-04 17:51:27 +02:00
calendar.inc Bug 7261 System Preference to select the first day of week 2012-03-14 14:14:12 +01:00
cat-menu.inc
cat-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
cat-toolbar.inc Bug 7739 follow-up for capital cases 2012-05-11 12:20:14 +02:00
cataloging-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
cataloging-toolbar.inc Bug 2780 - Capitalize strings consistently (Cataloging) 2012-04-04 17:54:40 +02:00
checkin-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
checkouts-table-footer.inc Enh 6887: Add 'checked out from' column to issued items display tables 2011-09-21 09:44:00 +12:00
circ-menu.inc Bug 2780 - Capitalize strings consistently (Circulation) 2012-04-04 17:54:07 +02:00
circ-menu.tt Bug 2780 - Capitalize strings consistently (Circulation) 2012-04-04 17:54:07 +02:00
circ-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
circ-toolbar.inc Bug 2733 - Can't print patron account 2012-04-06 18:30:35 +02:00
cities-admin-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
contracts-admin-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
currencies-admin-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
datatables-strings.inc Bug 6836: Add jQuery dataTables plugin 2012-01-27 11:33:11 +01:00
date-format.inc Bug 5543 - Date ISO format wrong separator 2012-01-10 23:28:47 +01:00
dictionary-toolbar.inc Bug 2780 - Capitalize strings consistently (Reports) 2012-04-04 17:54:43 +02:00
doc-head-close-receipt.inc
doc-head-close.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
doc-head-open.inc Fix for Bug 6458 - incorrect parsing result in translation processing 2011-09-15 08:39:31 +12:00
error-messages.inc Bug 7731 - Library should be used instead of branch and site 2012-03-20 15:17:08 +01:00
facets.inc Bug 2780 - Capitalize strings consistently (miscellaneous) 2012-04-04 17:54:46 +02:00
favicon.ico Bug 7949 - a different favicon for the staff client 2012-05-07 23:19:56 +02:00
file-upload.inc
greybox.inc
guided-reports-view.inc Bug 2780 - Capitalize strings consistently (Reports) 2012-04-04 17:54:43 +02:00
header.inc Bug 8160 - Link to cataloging appears for users without cataloging permission 2012-06-05 16:01:42 +02:00
help-bottom.inc
help-top.inc
hold-menu.inc Bug 2780 - Capitalize strings consistently (miscellaneous) 2012-04-04 17:54:46 +02:00
home-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
installer-doc-head-close.inc
intranet-bottom.inc Bug 7644 - Invalid markup in staff client language chooser 2012-03-16 11:46:01 +01:00
labels-batches-toolbar.inc Bug 2780 - Capitalize strings consistently (Labels) 2012-04-04 17:54:33 +02:00
labels-menu.inc Bug 2780 - Capitalize strings consistently (Labels) 2012-04-04 17:54:33 +02:00
labels-new-toolbar.inc Bug 2780 - Capitalize strings consistently (Labels) 2012-04-04 17:54:33 +02:00
labels-toolbar.inc Bug 2780 - Capitalize strings consistently (Labels) 2012-04-04 17:54:33 +02:00
letters-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
mainmenu.inc Bug 2780 - Capitalize strings consistently (miscellaneous) 2012-04-04 17:54:46 +02:00
members-menu.inc Bug 2780 - Capitalize strings consistently (Patrons) 2012-04-04 17:54:37 +02:00
members-toolbar.inc Bug 2733 - Can't print patron account 2012-04-06 18:30:35 +02:00
messaging-preference-form.inc Talking Tech Support - Phase I 2012-06-10 17:46:52 +02:00
page-numbers.inc
patron-search-box.inc Bug 7747 - Replace YUI autocomplete with jQueryUI 2012-05-31 18:07:55 +02:00
patron-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
patron-title.inc Bug 6303: Display Organisation and Parent Organisation names when viewing a borrower of type organisation 2011-11-24 11:30:08 +01:00
patron-toolbar.inc Bug 2780 - Capitalize strings consistently (Patrons) 2012-04-04 17:54:37 +02:00
patroncards-batches-toolbar.inc Bug 2780 - Capitalize strings consistently (Patron cards) 2012-04-04 17:54:35 +02:00
patroncards-menu.inc Bug 2780 - Capitalize strings consistently (Patron cards) 2012-04-04 17:54:35 +02:00
patroncards-toolbar.inc Bug 2780 - Capitalize strings consistently (Patron cards) 2012-04-04 17:54:35 +02:00
patrons-admin-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
popup-bottom.inc
prefs-admin-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
prefs-menu.inc Bug 2780 - Capitalize strings consistently (Administration) 2012-04-04 17:54:41 +02:00
printers-admin-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
quotes-toolbar.inc Bug 7977: Further UI work on the QOTD editor 2012-05-24 14:14:17 +02:00
quotes-upload-toolbar.inc Bug 7977: Further UI work on the QOTD uploader 2012-05-24 14:14:15 +02:00
reports-menu.inc Bug 2780 - Capitalize strings consistently (Reports) 2012-04-04 17:54:43 +02:00
reports-toolbar.inc Bug 7668 - Improve navigation and toolbar options in guided reports 2012-03-19 18:00:15 +01:00
resort_form.inc Bug 2780 - Capitalize strings consistently (miscellaneous) 2012-04-04 17:54:46 +02:00
roadtype-admin-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
search_indexes.inc Bug 2780 - Capitalize strings consistently (miscellaneous) 2012-04-04 17:54:46 +02:00
serials-menu.inc Bug 7523: Improve checks for routing permissions 2012-02-27 18:22:01 +01:00
serials-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
serials-toolbar.inc Bug 2780 - Capitalize strings consistently (Serials) 2012-04-04 17:54:38 +02:00
stopwords-admin-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
subtypes_unimarc.inc
suggestions-add-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
sysprefs-admin-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00
table-pager.inc Bug 6842 Alternate fix, Branch transfer limits broken 2012-02-01 22:38:32 +01:00
tools-item-action.inc
tools-menu.inc Bug 8195: Selected link must be bold (in admin and tools) 2012-06-09 12:31:12 +02:00
tools-nomatch-action.inc
tools-overlay-action.inc
virtualshelves-toolbar.inc Bug 7363: allows downloading of lists in CSV format 2012-01-13 12:13:33 +01:00
z3950-admin-search.inc Bug 8143 [REVISED] Upgrade jQuery tabs to current jQueryUI version 2012-06-10 15:22:58 +02:00