Change State when User Selects Notification from i

2019-02-15 11:39发布

问题:

I'm attempting to open an iOS/Ionic/Cordova app at a specific message/state (given an ID), when a user clicks on a message push notification in the notification center. Is there a way to tell, using Cordova, if the app has been opened through the notification center?

回答1:

From the docs, the callback is the point of entry for your notification. Any calls you make (or variables you set) inside the callback will only be possible if the app has been opened through the notification center