Closed Mrkhagol closed 10 years ago
Any suggestions or ideas?
what i am doing is setting up a reminder which gives out notification and then I select it and it takes me to the app screen where I am placing this feature. By the way this is android 4.4.2..I have even included device that you have in dependencies section..anyways..So when the app opens up I see the alert I place in the ontrigger function. Now, the same thing doesn't take place in ios 7..the app opens up but I don't the alert javascript message that is placed in ontrigger function..
window.plugin.notification.local.add({ id: 1, // is converted to a string title: 'Reminder test', message: 'this is your reminder', repeat: 'daily', date: _60_seconds_from_now });
window.plugin.notification.local.ontrigger = function (id, state, json) { alert("Hello"); };
so that's why I was asking for demo to see if you had set up anything similar and maybe i could find what I missed..
I think the behavior is related to the mobile OS and how apps works while they are in background.
On Android there is not so much difference between foreground and background state. But on iOS the app will be suspended while in backgrounds. Thats why the plugin does not receive the outrigger event.
You can install https://github.com/katzer/cordova-plugin-background-mode as a solution.
Sounds similar to #84
so I put this in my config.xml
and I get this
Yes, the plugin is not available by PGB.
I have submitted the plugin. Hope it can help you.
Hey there..your plugin is great and thanks for sharing.
But would you happen to have a demo example of how it all fits together. ??