Cordova-plugin-local-notifications: weekday not working in Android

Created on 3 Mar 2020  路  2Comments  路  Source: katzer/cordova-plugin-local-notifications

When I try to use weekday: 1 (any number until number 7) is not working

Your Environment

  • Plugin version: 0.9.0-beta.3
  • Platform: Android
  • OS version: Android 6.0.1
  • Device manufacturer / model: Samsung Galaxy J2, SM-G532MT
  • Cordova version (cordova -v): 8.1.2
  • Cordova platform version (cordova platform ls): android 7.1.4
  • Plugin config
  • Ionic Version: 5.4.16

Expected Behavior

Should Trigger the notification of week day

Actual Behavior

Is not triggering at the week I add

Steps to Reproduce

  1. Build a debug version using local notifications plugin
  2. Open debug console log at Chrome
  3. Add code bellow (you can choose date more close to you)
    cordova.plugins.notification.local.schedule({ text: 'Testing', trigger: { every: { weekday: 2, hour: 9, minute: 12, second: 1}} });
  4. If you remove weekday: 2 will work fine, I tested adding weekdays for all days of the week does not work

Image of console on my testing.

Screen Shot 2020-03-03 at 11 06 58

As you can see in the image when I use weekday is not adding to the list of schedule

Most helpful comment

I had to get this working so I made the fix, I will open PR when I have more time.

https://github.com/jonasmedeiros/cordova-plugin-local-notifications/commit/a6cd9306946d65a5fa04db18a7a090801458b059

All 2 comments

I had to get this working so I made the fix, I will open PR when I have more time.

https://github.com/jonasmedeiros/cordova-plugin-local-notifications/commit/a6cd9306946d65a5fa04db18a7a090801458b059

Hi, I have the same problem on iOS too .. :(

Was this page helpful?
0 / 5 - 0 ratings

Related issues

daniele-sartiano picture daniele-sartiano  路  4Comments

Hirbod picture Hirbod  路  3Comments

Kasendwa picture Kasendwa  路  3Comments

jomarocas picture jomarocas  路  3Comments

Shashank2406 picture Shashank2406  路  5Comments