简体   繁体   English

iOS重复推送通知

[英]iOS Repeat Push Notifications

I have an existing app that receives push notifications. 我有一个可以接收推送通知的应用程序。 I've been requested to implement a feature where the user must acknowledge the push notification. 我被要求实现一项功能,用户必须在其中确认推送通知。 If the user does not acknowledge the notification, then they will be alerted again after a set time, until they finally do acknowledge it. 如果用户不确认该通知,则将在设置的时间后再次提醒他们,直到他们最终确认。

So far, the only solution I've come up with is: 到目前为止,我想出的唯一解决方案是:

We send a notification from our server to APNS. 我们从服务器发送通知到APNS。 When the user opens the app after receiving a notification, the app will then send an acknowledgement back to the server. 当用户在收到通知后打开应用程序时,该应用程序会将确认发送回服务器。 If the server does not receive an acknowledgement from the device within X minutes, it will automatically send another notification. 如果服务器在X分钟内未收到来自设备的确认,它将自动发送另一个通知。

Is there a better way of implementing this kind of feature, where I'm not relying on sending acknowledgments back to the server? 有没有更好的方法来实现这种功能,而我又不依赖于将确认发送回服务器?

创建用于推送通知的“接受/拒绝”操作并将该信息保存在服务器上,以便我们区分接受的信息和其他信息

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM