簡體   English   中英

返回到應用程序時會打開FCM推送通知,而不是在iOS的狀態欄中顯示

[英]FCM push notifications opens when returning to app instead of showing in the status bar in iOS

當進入前台時,如何使通知顯示在狀態欄中,而不是在應用程序中排隊和接收?

我已經使用APN設置了FCM帳戶,啟用了推送通知,后台獲取和遠程通知。

我已經在android上完成了相當於預期的效果。

我的訊息如下:

{
  "notification": {
    "body": "this is a body",
    "title": "this is a title", 
    "content_available": true
  }, 
  "priority": "high", 
  "data": {
    "click_action": "FLUTTER_NOTIFICATION_CLICK", 
    "id": "1", 
    "status": "done"
  }, 
  "to": "TOKEN"
}'

我想念什么?

僅當應用程序不在前台時,才會顯示通知。 如果要在前台顯示它們,則應為此實現自定義UI。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM