-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathAppDelegate.m
More file actions
executable file
·33 lines (26 loc) · 1011 Bytes
/
AppDelegate.m
File metadata and controls
executable file
·33 lines (26 loc) · 1011 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
//
// AppDelegate.m
// JavaScriptAndObjectiveC
#import "AppDelegate.h"
#import <AlipaySDK/AlipaySDK.h>
#import "OpenShareHeader.h"
@interface AppDelegate ()
@end
@implementation AppDelegate
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
[OpenShare connectQQWithAppId:@"1105488636"];//1103194207 openshare //1105488636 test //1105057857 hzc
[OpenShare connectWeixinWithAppId:@"wx57c7b928e9b013ba"];//wxd930ea5d5a258f4f openshare wx57c7b928e9b013ba test //wxe3ede52918691e61 hzc
return YES;
}
// NOTE: 9.0以后使用新API接口
- (BOOL)application:(UIApplication *)app openURL:(NSURL *)url options:(NSDictionary<NSString*, id> *)options
{
if ([url.host isEqualToString:@"safepay"]) {
//跳转支付宝钱包进行支付,处理支付结果
[[AlipaySDK defaultService] processOrderWithPaymentResult:url standbyCallback:^(NSDictionary *resultDic) {
NSLog(@"result = %@",resultDic);
}];
}
return YES;
}
@end