-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
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
data parameter return undefined in click event #1151
Comments
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/parse Hope that helps! |
This was also reported here #1138. @SammyIsra has the same solution as we used :) Rob |
This should be in the docs =) |
Can this be closed now? Rob |
I believe so, yes. |
Only you can close it 😃 Rob |
Hello I have a similar problem but with ionic 2. I have this variable public clickNotification: boolean = false; Which must be changed to true when clicking on the notification: And the console displays undefined |
Your issue seems to bear no resemblance to the OP issue. I suggest you fill out the template in #1188 and raise a new issue and lets close this down. Rob |
@rwillett I cannot close this |
You are correct, I should have referred to @hguldal, Apologies. |
cordova.plugins.notification.local.schedule({
id: Math.floor((Math.random() * 1000000) + 1),
title:'title',
text:'text',
data:{value:'key'}
});
cordova.plugins.notification.local.on("click", function (notification) {
alert(notification.data.value); //print undefined
});
notification.data.value return undefined why ?
The text was updated successfully, but these errors were encountered: