Apple Push notifications. Trying something else. again

This commit is contained in:
Martin Donnelly 2016-04-29 11:21:39 +01:00
parent db6cc3bdc3
commit 1e7740f9be

5
app.js
View File

@ -269,6 +269,11 @@ app.post('/api/v1/register/ios', function(req, res) {
logger.info('Sending the same notification each of the devices with one call to pushNotification.'); logger.info('Sending the same notification each of the devices with one call to pushNotification.');
var note = new apn.notification(); var note = new apn.notification();
note.setAlertText('Hello, from node-apn!'); note.setAlertText('Hello, from node-apn!');
note.setAlertTitle('Smart Office');
note.setBadge(1);
note.setSound('dong.aiff');
note.badge = 1; note.badge = 1;
apnService.pushNotification(note, iosTokens); apnService.pushNotification(note, iosTokens);