No sound, no notification, only listed in notifications PT2
See original GitHub issueHi Eddy! Sorry for coming back on this issue, but unfortunately it seems to be back…
Although the issue here seems to be kinda “strange” I’ll try to provide as many details as I can:
Occurs on: Samsung Galaxy S5 [Android 6.0.1] Issue details: when the application receives a new notification, it just puts it in the notifications bar, as described in the #61. Even if the application is in foreground, no sound is played when the notification comes (and I’m talking about the default sound, no customizations made), and neither is shown the classic “notification dialog” at the top of the screen.
The notifications does arrive even when the app is killed, but still, with no sound and no visual dialog and even if the app is in background, but with the same parts missing.
Instead on my daily phone (OnePlus 5T) with [Android 8.1.0] works like a charm. Only when the app is in foreground
But if in background, or killed, no notifications are listed. And no sounds are played. Well… sometimes. That’s why I said that it was strange…
If it can help I list here my package json deps and versions of TNS:
{
"nativescript": {
"id": "com.tns.debug.app.debug",
"tns-android": {
"version": "5.1.0"
},
"tns-ios": {
"version": "5.1.0"
}
},
"description": "TNS Debug App",
"license": "SEE LICENSE IN <your-license-filename>",
"repository": "<fill-your-repository-here>",
"dependencies": {
"@angular/animations": "~7.1.0",
"@angular/common": "~7.1.0",
"@angular/compiler": "~7.1.0",
"@angular/core": "~7.1.0",
"@angular/forms": "~7.1.0",
"@angular/http": "~7.1.0",
"@angular/platform-browser": "~7.1.0",
"@angular/platform-browser-dynamic": "~7.1.0",
"@angular/router": "~7.1.0",
"nativescript-angular": "~7.1.0",
"nativescript-background-geolocation-lt": "^1.9.1",
"nativescript-google-maps-sdk": "^2.6.1",
"nativescript-local-notifications": "^3.1.0",
"nativescript-plugin-firebase": "^7.6.1",
"nativescript-theme-core": "~1.0.4",
"nativescript-toast": "^1.4.6",
"nativescript-uuid": "0.0.1",
"randomstring": "^1.1.5",
"reflect-metadata": "~0.1.8",
"rxjs": "~6.3.0",
"tns-core-modules": "~5.1.0",
"zone.js": "^0.8.26"
},
"devDependencies": {
"@angular/compiler-cli": "~7.1.0",
"@nativescript/schematics": "~0.5.0",
"@ngtools/webpack": "~7.1.0",
"@types/randomstring": "^1.1.6",
"nativescript-dev-typescript": "~0.7.0",
"nativescript-dev-webpack": "~0.19.0"
},
"readme": "NativeScript Application"
}
Hope you can help me 😃
And by the way, as always, awesome work! We all greatly appreciate what you are doing ❤️
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (1 by maintainers)
Is this plugin can’t play custom mp3 audio? android
LOL this IS strange!
If you send in the notification message the following property:
Android will force play the default notification sound! 😂😂😂😂😂😂
Or a cleaner way:
Note that it will work only on Android 7 and below. For newer versions, you have to set up the notification channel too.