enable notifications?

19 views
Skip to first unread message

John Strickler

unread,
Nov 21, 2018, 12:38:57 PM11/21/18
to ResearchStack
It looks like notifications are built into the skin framework. Do these come from the scheduleString for various surveys in the tasks_and_schedules.json? I'm building an app using the SampleApp and MoleMapper for reference, but I have yet to get it to fire a notification. I'm using the Genymotion emulator. Can someone walk me through the steps to get notifications working?

John Strickler

unread,
Nov 28, 2018, 2:39:30 PM11/28/18
to ResearchStack
I think I have this mostly figured out. When a survey is completed BridgeDataProvider.uploadTaskResult() is called. This creates a TaskNotification record, and a broadcast for TaskAlertReceiver.ALERT_CREATE is sent. Broadcast for TaskAlertReceiver.ALERT_CREATE_ALL is also sent from the SplashActivity (app startup) and the DeviceBootReceiver (phone startup). The TaskAlertReceiver reads the TaskNotification records and creates an alarm based on the cron schedule which broadcasts to the TaskNotificationReceiver which creates a notification.
Reply all
Reply to author
Forward
0 new messages