【发布时间】:2023-03-16 12:19:01
【问题描述】:
我尝试使用过期时间间隔发送推送,但它没有发送到服务
long weekInterval = 60*60*24*7; // 1 week
// Send push notification with expiration interval
ParsePush push1 = new ParsePush();
push1.setExpirationTime(weekInterval);
push1.setQuery(ParseInstallation.getQuery().whereEqualTo("deviceType", "android"));
push1.setMessage("Season tickets on sale until November 20th");
push1.sendInBackground();
但在服务器端的通知描述是这样的
目标:
deviceType is "android" Sending date : November 14th, 2014 at 5:42 PM Expiration : None Full target : { "deviceType": "android" } Full data : { "alert": "Season tickets on sale until November 20th" }
如您所见,过期是无
更新: 同样的行为是: setExpirationTimeInterval()
是我的错误还是服务的?
【问题讨论】:
-
我似乎也收到了应该过期的推送。我从 Cloud Code 发送。
-
我已经测试了你的代码,它对我有用。
标签: android notifications parse-platform push