Last active
October 21, 2015 13:58
-
-
Save natanrolnik/8bc3631cb4d4b534ea5c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Parse.Cloud.afterSave("LaneResult", function(request) { | |
var query = new Parse.Query(Parse.Installation); | |
var text = "New event from " + request.object.get("App") + ": " + request.object.get("EventType"); | |
Parse.Push.send({ | |
where: query, // Set our Installation query | |
data: { | |
alert: text, | |
sound: "register.aiff" | |
} | |
}, { | |
success: function() { | |
// Push was successful | |
}, | |
error: function(error) { | |
// Handle error | |
} | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment