Разработвам приложение за получаване на тост известие всеки път, когато базата данни се актуализира, но искам сървърът да изпрати известието само до един конкретен потребител, а не до всички.
Има ли начин да го направя?
function update(item, user, request) {
request.execute({
success: function () {
// Write to the response and then send the notification in the background
request.respond();
push.mpns.sendToast(item.channel,
{
text1:"Sent from cloud!"
},
{
success: function(pushResponse) {
console.log("Sent push:", pushResponse);
}
});
}
});
}