展开通知图片时不渲染ios

问题描述

我使用以下代码段在我的应用中注册了一些按钮,其中包含一些类别。

                    let actionReadLater = UNNotificationAction(identifier: "Notification.Action.readLater",title: "Read Later",options: [])
                let actionShowDetails = UNNotificationAction(identifier: "Notification.Action.showDetails",title: "Show Details",options: [.foreground])
                let actionUnsubscribe = UNNotificationAction(identifier: "Notification.Action.unsubscribe",title: "Unsubscribe",options: [.destructive,.authenticationrequired])

                // Define Category
                let tutorialCategory = UNNotificationCategory(identifier: "buyAndSell",actions: [actionReadLater,actionShowDetails,actionUnsubscribe],intentIdentifiers: [],options: [])

                // Register Category
                UNUserNotificationCenter.current().setNotificationCategories([tutorialCategory])

如果我发送带有空类别名称的丰富推送,则图像正在呈现。如果我使用上面的类别名称发送丰富的推送,图像正在下载,我可以在右下角看到图像缩略图,但在展开通知后,图像没有显示,它显示空白区域并且按钮可见。请帮助我这里做错了什么。

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)