Vijay Prakash Desetty
Vijay Prakash Desetty

Reputation: 55

Parse Configuration in Android with Smartface App Studio

I am trying to config Parse plug-in into my android app with Smartface App Studio. I followed the link http://www.smartface.io/developer/guides/advanced/push-notification-on-parse-services/#before450 with Smartface App Studio 4.5 version. But, the device is not getting registered with parse and even not getting any fail message.

Can any one help on this. Thanks in advance.

Upvotes: 0

Views: 61

Answers (1)

You are using Smartface 450, so the document you should check is this one below: http://www.smartface.io/developer/guides/advanced/push-notification-on-parse-services/#after450

You can use the below code on Global.Smartface.js in order to see if it registered or not:

alert("Registration is successful : \n" + Parse.getToken("Landroid/app/Activity;"));

And in Page1.onShow, you can use parse methods as below:

Parse.onRegistrationFail = function () {
    alert("Parse Registration failed");
};
// if the application is open and receives notification
Parse.onParsePushReceive = function () {
    alert("app opened : \n\n" + Parse.getData());
};
//if the application is closed and get opened by a parse notification
if (Parse.openedByParseNotification()) {
    alert("app opened by a notification : \n\n" + Parse.getData());
}

Upvotes: 0

Related Questions