ionic-team / legacy-ionic-cloud

JavaScript Client for legacy Ionic Cloud services. See Ionic Pro for our new take on the ionic development lifecycle
Apache License 2.0
65 stars 26 forks source link

push.on('registration', callback) not firing iOS #99

Open omhybrid opened 7 years ago

omhybrid commented 7 years ago

use ionic package service for ios build

push.on('registration', callback) not firing iOS

push.on('error', function(data) { }); ==> error responce " no valid aps environment entitlement string found for application"

var pushNot = PushNotification.init( {android: {senderID: "462756420685",sound:true},ios: { alert: true, badge: true, sound: true }});

    pushNot.on('registration', function(data) {

                    alert(data.registrationId):

    });

     pushNot.on('error', function(data) {
           alert('ERROR ' + data);
       });

    pushNot.on('notification', function(data) {

    });

cordova CLI: 6.4.0 Ionic CLI Version: 2.1.12 Ionic App Lib Version: 2.1.7 ios-deploy version: Not installed ios-sim version: Not installed OS: Windows 7 Node Version: v6.9.1

Fuiste commented 7 years ago

This is likely an issue with the provisioning profile used to sign the application, and I'd first ensure that you've correctly authorized the app for APNS.

If the problem persists after regenerating your provisioning profile, I'd check with @dwieeb for more infor on the Package side of things.