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

[Bug]: incoming notification but no floating notification #609

Closed
2 of 3 tasks
ayyuby26 opened this issue Nov 2, 2022 · 5 comments
Closed
2 of 3 tasks

[Bug]: incoming notification but no floating notification #609

ayyuby26 opened this issue Nov 2, 2022 · 5 comments

Comments

@ayyuby26
Copy link

ayyuby26 commented Nov 2, 2022

What happened?

in version 3.4.2 the notification came in but only the notification sound, the floating notification didn't come in, but when I checked the notification list, the notification was there, I found this in the official onesignal video tutorial at 4:20 minutes

onesignal official video tutorial: https://youtu.be/5klspCULQe4?t=260

Steps to reproduce?

1. install v3.4.2 depedency
2. launch the app android
3. send notification
4. incoming notification but no floating notification

What did you expect to happen?

incoming and floating notifications

OneSignal Flutter SDK version

3.4.2

Which platform(s) are affected?

  • iOS
  • Android

Relevant log output

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct
@ayyuby26 ayyuby26 changed the title [Bug]: [Bug]: incoming notification but no floating notification Nov 2, 2022
@chrisvidal
Copy link

having the same question

@chrisvidal
Copy link

check your code that handles the event setNotificationWillShowInForegroundHandler

in the code that I copied/pasted from the website, there was this line that is blocking the badge. just comment it.

event.complete(null);

@TareqAmenahDev
Copy link

Same issue here

@Sahad2701
Copy link

Hello @ayyuby26,

To resolve this issue on Android, you can create an Android Notification Channel where you can define the importance of notifications. By defining a high priority, you will receive sound and popup notifications as well. If you are using an API, you need to define that channel ID in Notification API as key ‘android_channel_id’ and value as ‘your_android_channel_id’, which you can obtain from your OneSignal Dashboard by going to Settings > Messaging > Android Notification Channels.

Full documentation link : https://documentation.onesignal.com/docs/android-notification-categories

Screenshot 2023-10-28 at 8 51 31 PM Screenshot 2023-10-28 at 8 56 39 PM

I hope this will solve your issue.

@Sahad2701
Copy link

Closes #609

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

5 participants