城市飞艇Phonegap插件未在iOS应用程序上注册设备令牌

城市飞艇Phonegap插件未在iOS应用程序上注册设备令牌,ios,cordova,urbanairship.com,Ios,Cordova,Urbanairship.com,我正在开发一个应用程序,使用Phonegap和城市飞艇插件。我已经连接并配置了教程中提到的所有内容,但应用程序仍然没有向UA注册令牌 这是我的应用程序日志: 2013-05-15 18:20:10.791 MyApp[37284:907] Multi-tasking -> Device: YES, App: YES 2013-05-15 18:20:10.917 MyApp[37284:907] [I] +[UAirship takeOff:] [Line 215] App Key: ap

我正在开发一个应用程序,使用Phonegap和城市飞艇插件。我已经连接并配置了教程中提到的所有内容,但应用程序仍然没有向UA注册令牌

这是我的应用程序日志:

2013-05-15 18:20:10.791 MyApp[37284:907] Multi-tasking -> Device: YES, App: YES
2013-05-15 18:20:10.917 MyApp[37284:907] [I] +[UAirship takeOff:] [Line 215] App Key: app_key
2013-05-15 18:20:10.918 MyApp[37284:907] [I] +[UAirship takeOff:] [Line 216] App Secret: app_secret
2013-05-15 18:20:10.920 MyApp[37284:907] [I] +[UAirship takeOff:] [Line 217] Server: https://device-api.urbanairship.com
2013-05-15 18:20:10.965 MyApp[37284:907] [D] -[UAirship configureUserAgent] [Line 362] Setting User-Agent for UA requests to MyApp 1.0 (iPhone; iPhone OS 6.1.3; UALib 1.4.0; p3R6RpCWSB2EZ_z9CmbBGg; ru_RU)
2013-05-15 18:20:11.001 MyApp[37284:907] [D] void PrintReachabilityFlags(SCNetworkReachabilityFlags, const char *) [Line 79] Reachability Flag Status: -R -----l- networkStatusForFlags
2013-05-15 18:20:11.032 MyApp[37284:907] [D] -[UAUser migrateUser] [Line 168] Migrating User Info: {
     UAUserRecoveryKey = 0;
     UAUserRecoveryKeySent = 0;
     UAUserTagsKey =      (
     );
     UAUserUrlKey = "https://device-api.urbanairship.com/api/user/mRBbpmi2R_SeZad_R2WSxg/";
}
2013-05-15 18:20:11.078 MyApp[37284:907] [D] -[UAUser loadUser] [Line 249] User Info: {
     UAUserRecoveryKey = 0;
     UAUserRecoveryKeySent = 0;
     UAUserTagsKey =      (
     );
     UAUserUrlKey = "https://device-api.urbanairship.com/api/user/mRBbpmi2R_SeZad_R2WSxg/";
}
2013-05-15 18:20:11.087 MyApp[37284:907] [CDVTimer][pushnotificationplugin] 175.806999ms
2013-05-15 18:20:11.091 MyApp[37284:907] [CDVTimer][TotalPluginStartup] 180.313051ms
2013-05-15 18:20:11.263 MyApp[37284:907] [D] -[UAPush applicationDidBecomeActive] [Line 555] Checking registration status after foreground notification
2013-05-15 18:20:11.265 MyApp[37284:907] [D] -[UAPush applicationDidBecomeActive] [Line 561] Checking registration on app foreground disabled on app initialization
2013-05-15 18:20:11.706 MyApp[37284:907] [D] -[UAUser listenForDeviceTokenReg] [Line 931] ListenForDeviceTokenReg
2013-05-15 18:20:11.874 MyApp[37284:907] Resetting plugins due to page load.
2013-05-15 18:20:12.512 MyApp[37284:907] DEPRECATION NOTICE: The Connection ReachableViaWWAN return value of '2g' is deprecated as of Cordova version 2.6.0 and will be changed to 'cellular' in a future release. 
2013-05-15 18:20:13.875 MyApp[37284:907] Finished load of: file:///var/mobile/Applications/F5AA9FE8-7DCD-40A8-825B-8E0F5D12368B/MyApp.app/www/index.html
2013-05-15 18:20:15.489 MyApp[37284:907] [D] -[UAPush updateRegistration] [Line 589] Checking registration state
2013-05-15 18:20:15.506 MyApp[37284:907] [D] -[UAPush updateRegistration] [Line 609] Device token is nil. Registration will be attempted at a later time
2013-05-15 18:20:26.090 MyApp[37284:907] [D] +[UAKeychainUtils getDeviceID] [Line 275] Retrieved device id info from keychain.
2013-05-15 18:20:26.092 MyApp[37284:907] [D] +[UAKeychainUtils getDeviceID] [Line 279] Device ID result is not nil.
2013-05-15 18:20:26.094 MyApp[37284:907] [D] +[UAKeychainUtils getDeviceID] [Line 288] Loaded Device ID: 55ADD1F9-C71E-4604-8EB1-EB9888194468
2013-05-15 18:20:26.095 MyApp[37284:907] [D] +[UAKeychainUtils getDeviceID] [Line 289] Loaded Model Name: iPhone3,1
2013-05-15 18:20:26.477 MyApp[37284:907] [D] -[UAAnalytics requestDidSucceed:response:responseData:] [Line 461] Analytics data sent successfully. Status: 200

我的index.html文件中还有push.enablePush()。我使用的是Xcode 4.6.2和Phonegap 2.7.0。

问题在于:我没有像iOS示例中那样制作所有内容:

我想有一个registerForNotificationTypes,它可以为iOS注册通知(Android没有这样的方法)


因此,将这一行添加到代码中就解决了问题。

嘿,格林,你能解决这个问题吗?我也在同一条船上。我一直在读到,在我完成推送证书后,我必须创建我的资源调配配置文件。检查,完成了。现在,我没有别的地方可去了。如此迷失。。。在这件事上花了这么多小时。任何建议都很好,谢谢。嗨,西卡1。请看下面我的答案(刚刚添加)。希望有帮助