我要在整合谷歌加號來我app.But我想使用谷歌SDK不使用可可豆莢,如果任何人都用這個的iOS SDK,請給我的步驟登錄並獲取用戶的詳細信息,因爲我沒有得到適當的文件。我使用谷歌登錄在該委託方法SDK 4.0.1谷歌通過我的iOS應用程序登錄
沒有得到調用。
我用以下結構:
- (void)viewDidLoad {
[super viewDidLoad];
[GIDSignIn sharedInstance].clientID = @"842331483294-ofk2cbhhfjoga35u1575t4hbq9ek87ii.apps.googleusercontent.com";
[GIDSignIn sharedInstance].delegate = self;
[GIDSignIn sharedInstance].uiDelegate = self;
// Do any additional setup after loading the view, typically from a nib.
}
- (void)signIn:(GIDSignIn *)signIn
didSignInForUser:(GIDGoogleUser *)user
withError:(NSError *)error {
// Perform any operations on signed in user here.
NSString *userId = user.userID; // For client-side use only!
NSString *idToken = user.authentication.idToken; // Safe to send to the server
NSString *fullName = user.profile.name;
NSString *givenName = user.profile.givenName;
NSString *familyName = user.profile.familyName;
NSString *email = user.profile.email;
}
- (void)signIn:(GIDSignIn *)signIn
didDisconnectWithUser:(GIDGoogleUser *)user
withError:(NSError *)error {
// Perform any operations when the user disconnects from app here.
// ...
}
- (void)signInWillDispatch:(GIDSignIn *)signIn error:(NSError *)error {
}
但任何這種委託方法是沒有得到調用。
任何幫助將不勝感激。 謝謝
你配置谷歌開發者信息中心您的應用程序? –
這個問題是否發生在ios 10? – KKRocks
是, 在火力控制檯我的項目是Android管理,以便在iOS設備上也將是同一個項目,但只有iOS應用應該管理我已經配置我的應用程序,但使用火力控制檯,並且我已經做 – puja