Hi ,
I am able to get push notification by api and able to navigate when i am getting popup . But issue is that when notification is on notification tray then i am not able to show popup bez on click there is no event , My code is
this.fcm.onNotification().subscribe(response => {
console.log(response);
if(response.wasTapped) {
alert(“Received in background”); …
now i google it and then i get some response for “click_action”:“hello.html”, put in api payload json . but how to integrate it in json because on click on notification when it is in notification tray then first popup should show .
Anuj14
That was not correct way to add click action So Please add this line only in your json payload
"click_action":“FCM_PLUGIN_ACTIVITY”,
It will work.
Like:
“notification”: {
“title”: “Status Update”,
“body”: “Status of the request has been updated by Punjab Restaurant1”,
“sound”: “default”,
“click_action”:“FCM_PLUGIN_ACTIVITY”,
},