是否可以通过Parse.com安排每天在特定(本地)时间发送推送通知?我已经想好了如何安排当地时间,而不是每天都有这样的事情发生。
发布于 2015-11-20 20:57:51
您可以安排一个背景作业在重复运行时运行,并以编程方式触发其中的推送。
Parse.Cloud.job('sendRecurringNotification', function(request, response) {
Parse.Push.send({
channels: ['a-reminder'],
data: {
alert: 'The kitchen is closing in 25 minutes'
}
}, {
success: function() {
response.success('scheduled order reminder notification')
},
error: function(error) {
response.error('unable to schedule order reminder notification with error ' + error)
}
})
})https://stackoverflow.com/questions/28732611
复制相似问题