katzer / cordova-plugin-local-notifications

Cordova Local-Notification Plugin
Apache License 2.0
2.56k stars 1.75k forks source link

The notification is not displayed on the lock screen and the LED-indicator does not turn on. #1614

Open EvPut opened 6 years ago

EvPut commented 6 years ago

Your Environment

Notification received, but is not displayed on the lockscreen (only on top) and the LED-indicator does not turn on. Added: After installing the application on the device, Settings -> Notifications and status bar -> Application notification -> My application - the lock screen and the light indicator are disabled. After enabled, it works. How to make the default, after the installation they have been enabled?

Me code:

cordova.plugins.notification.local.schedule({
    id: 1,
    title: 'TheBestDay',
    text: 'Test message',
    trigger: {at: my_date},
    led: { color: '#FF00FF', on: 500, off: 500 },
    lockscreen: true,
    vibrate: true,
    priority: 2,
    foreground: true
});
this.localNotifications.schedule({
    id: 1,
    title: 'TheBestDay',
    text: 'Test message',
    trigger: {at: my_date},
    led: { color: '#FF00FF', on: 500, off: 500 },
    lockscreen: true,
    vibrate: true
});

Thankful in advance for the help.

Ankitkumar7 commented 6 years ago

@EvPut - Try this cordova.plugins.notification.local.setDefaults({ led: { color: '#FF00FF', on: 500, off: 500 }, });

EvPut commented 6 years ago

@Ankitkumar7, does not help, we are talking about this: ag1ug

ghost commented 5 years ago

@EvPut - Try this cordova.plugins.notification.local.setDefaults({ led: { color: '#FF00FF', on: 500, off: 500 }, });

wr to use