We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Scheduled notification is working when Android app is open or in the background but not when the app has been closed. Working as intended on iOS.
cordova -v
cordova platform ls
Schedule notification should fire after 10 seconds of device being ready, even when the app is closed immediately (before the 10 seconds is up)
`var app = { initialize: function() { "use strict"; document.addEventListener('deviceready', this.onDeviceReady.bind(this), false); },
onDeviceReady: function() { "use strict"; this.receivedEvent('deviceready'); },
receivedEvent: function(id) { "use strict"; $(".listening").css("display","none"); $(".received").css("display","block");
cordova.plugins.notification.local.requestPermission(function (granted) { var soon = new Date(); soon.addSeconds(10); cordova.plugins.notification.local.schedule({ id: 1, title: 'My first notification', text: 'Thats pretty easy...', //smallIcon: 'res://logo.png', vibrate:true, lockscreen:true, foreground: true, badge:1, trigger: {at: soon} }); });
} }; Date.prototype.addSeconds = function(d) {"use strict"; this.setTime(this.getTime() + (d*1000)); return this; };`
Trying to get simple notification working when app is closed.
Include iOS / Android logs
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Scheduled notification is working when Android app is open or in the background but not when the app has been closed. Working as intended on iOS.
Your Environment
cordova -v
): 9.0.0cordova platform ls
): android 8.1.0Expected Behavior
Schedule notification should fire after 10 seconds of device being ready, even when the app is closed immediately (before the 10 seconds is up)
Actual Behavior
Scheduled notification is working when Android app is open or in the background but not when the app has been closed. Working as intended on iOS.
Steps to Reproduce
`var app = {
initialize: function() {
"use strict";
document.addEventListener('deviceready', this.onDeviceReady.bind(this), false);
},
onDeviceReady: function() {
"use strict";
this.receivedEvent('deviceready');
},
receivedEvent: function(id) {
"use strict";
$(".listening").css("display","none");
$(".received").css("display","block");
}
};
Date.prototype.addSeconds = function(d) {"use strict"; this.setTime(this.getTime() + (d*1000)); return this; };`
Context
Trying to get simple notification working when app is closed.
Debug logs
Include iOS / Android logs
The text was updated successfully, but these errors were encountered: