Hi,
We have written a javaScript on my Login Page which runs on "PUSH NOTIFICATION " event and performs
codevar msg = data.aps.alert; /code
This event works fine when the APP is running but when the APP is killed and a PUSH is received codevar msg = data.aps.alert; /code is not fetching payload(Push Notification Event was not triggered, testing using alert() in Push Notification Event).
However, if I receive push notification and open the APP, and then send it back to background, and then open the App again, push notification event is triggered. So the scenario of iOS as follows when the App is killed:
Push notification received, tap on it, it opens the App. However push notification event is not triggered (alert on the event is not running).
I send the App to the background, open another App, or go to iOS home page, and nothing occurs.
After a while, or immediately, I bring the App up again, 'Push notification' is triggered and the alert is displayed.
As we are using push notification event to redirect the navigation into various pages, this is causing us problem. We cannot read the notification payload to identify to which page the App will be redirected.
The problem is only with iOS, Android works fine.