Skip to content
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

disable alerts #173

Closed
ghost opened this issue Jan 31, 2017 · 3 comments
Closed

disable alerts #173

ghost opened this issue Jan 31, 2017 · 3 comments

Comments

@ghost
Copy link

ghost commented Jan 31, 2017

I want to cancel the alert when the application is open. Have only external alarms.

My code:

OneSignal.configure({ onIdsAvailable: function (device) { getUserId(device.userId); }, onNotificationReceived: function (notification) { permissions = { alert: false, badge: true, sound: true }; OneSignal.requestPermissions(permissions); }, onNotificationOpened: function(message, data, isActive) { console.log("MS TYPE", message.notification.payload.additionalData.type); switch(message.notification.payload.additionalData.type) { case '1': Actions.messenger(); break; case '2': Actions.overview(); break; } } });

@avishayil
Copy link
Contributor

Hey @kamish770 , is this on iOS or Android?

@ghost
Copy link
Author

ghost commented Feb 1, 2017

ios

@avishayil
Copy link
Contributor

Please see #157 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant