fix(android): support static reminder notifications and ensure channel exists
Static reminders scheduled via scheduleDailyNotification() with isStaticReminder=true were being skipped because they don't have content in storage - title/body are in Intent extras. Fixed by: - DailyNotificationReceiver: Extract static reminder extras from Intent and pass to WorkManager as input data - DailyNotificationWorker: Check for static reminder flag in input data and create NotificationContent from input data instead of loading from storage - DailyNotificationWorker: Ensure notification channel exists before displaying (fixes "No Channel found" errors) Also updated prefetch timing from 5 minutes to 2 minutes before notification time in plugin code and web UI.
This commit is contained in:
@@ -1286,9 +1286,9 @@ open class DailyNotificationPlugin : Plugin() {
|
||||
reminderId = scheduleId
|
||||
)
|
||||
|
||||
// Always schedule prefetch 5 minutes before notification
|
||||
// Always schedule prefetch 2 minutes before notification
|
||||
// (URL is optional - native fetcher will be used if registered)
|
||||
val fetchTime = nextRunTime - (5 * 60 * 1000L) // 5 minutes before
|
||||
val fetchTime = nextRunTime - (2 * 60 * 1000L) // 2 minutes before
|
||||
val delayMs = fetchTime - System.currentTimeMillis()
|
||||
|
||||
if (delayMs > 0) {
|
||||
|
||||
Reference in New Issue
Block a user