From 4e2b2d6bb66fd0d7e6459426bcc412a8588b4853 Mon Sep 17 00:00:00 2001 From: zhangqinghe Date: Fri, 24 Apr 2015 14:49:20 +0800 Subject: [PATCH] fix document about ios in content-avalible --- README.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/README.md b/README.md index 0fa763a..bef0a6d 100644 --- a/README.md +++ b/README.md @@ -68,6 +68,16 @@ l## JPush PhoneGap Plugin ## [[NSNotificationCenter defaultCenter] postNotificationName:kJPushPluginReceiveNotification object:userInfo]; } + - (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo fetchCompletionHandler:(void (^)(UIBackgroundFetchResult))completionHandler { + + // IOS 7 Support Required + [APService handleRemoteNotification:userInfo]; + [[NSNotificationCenter defaultCenter] postNotificationName:kJPushPluginReceiveNotification + object:userInfo]; + + completionHandler(UIBackgroundFetchResultNewData); + } + 7. 在js中调用函数,初始化jpush sdk