thudugala/Plugin.LocalNotification

NotificationReceived event not executing for repeatType: NotificationRepeat.Daily

Opened this issue · 2 comments

NotificationReceived event doesn't seem to be triggering when repeatType: NotificationRepeat.Daily is set (highted in red). I am able to see the daily alarm in adb shell dumpsys alarm, set to run around 1am. It is just that it doesn't seem to be going in the private void Current_NotificationActionReceived(NotificationEventArgs e) to setup further alarms for the day. The method runs for same day request as highligted in green even if the App is closed.

image

image

@programmerboy did the app restart before the notification?
and
is

<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" /> 

added

@thudugala NO, the App didn't restart and yes I have added that permission. Basically instead of setting bulk alarms for next few days, it is a recursive loop (for every day repeatType: NotificationRepeat.Daily) which will run around 1am and set the 4-5 alarms for that day. In my actual Android application, the logic I have is a extends BroadcastReceiver class, which on onReceive sets the alarm for the day, and also sets the alarm for next day and the cycle repeats.

Since above code is not running as intended. The current workaround I have is to set bulk alarms for X number of days, and then ask users to open App after X number of days to repeat the logic.