Showing
32 changed files
with
142 additions
and
218 deletions
No preview for this file type
... | @@ -7,7 +7,7 @@ | ... | @@ -7,7 +7,7 @@ |
7 | objects = { | 7 | objects = { |
8 | 8 | ||
9 | /* Begin PBXBuildFile section */ | 9 | /* Begin PBXBuildFile section */ |
10 | - 26B975C020AD7A66001E5EF9 /* XiongDiSDK.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 26B975BF20AD7A66001E5EF9 /* XiongDiSDK.framework */; }; | 10 | + 2691DA4620BB9E6400FEF5C3 /* HMHomeSDK.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2691DA4520BB9E6300FEF5C3 /* HMHomeSDK.framework */; }; |
11 | 8425EC1A1F0E3CBD00B0D868 /* PoolSdk.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8425EC191F0E3CBD00B0D868 /* PoolSdk.framework */; }; | 11 | 8425EC1A1F0E3CBD00B0D868 /* PoolSdk.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8425EC191F0E3CBD00B0D868 /* PoolSdk.framework */; }; |
12 | 845D18221C8D778400F27EB9 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 845D181B1C8D778400F27EB9 /* Images.xcassets */; }; | 12 | 845D18221C8D778400F27EB9 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 845D181B1C8D778400F27EB9 /* Images.xcassets */; }; |
13 | 846BD2241EE9342700E89A1D /* pool_setting in Resources */ = {isa = PBXBuildFile; fileRef = 846BD21F1EE9342700E89A1D /* pool_setting */; }; | 13 | 846BD2241EE9342700E89A1D /* pool_setting in Resources */ = {isa = PBXBuildFile; fileRef = 846BD21F1EE9342700E89A1D /* pool_setting */; }; |
... | @@ -60,7 +60,7 @@ | ... | @@ -60,7 +60,7 @@ |
60 | /* End PBXCopyFilesBuildPhase section */ | 60 | /* End PBXCopyFilesBuildPhase section */ |
61 | 61 | ||
62 | /* Begin PBXFileReference section */ | 62 | /* Begin PBXFileReference section */ |
63 | - 26B975BF20AD7A66001E5EF9 /* XiongDiSDK.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = XiongDiSDK.framework; sourceTree = "<group>"; }; | 63 | + 2691DA4520BB9E6300FEF5C3 /* HMHomeSDK.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = HMHomeSDK.framework; sourceTree = "<group>"; }; |
64 | 8425EC191F0E3CBD00B0D868 /* PoolSdk.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = PoolSdk.framework; sourceTree = "<group>"; }; | 64 | 8425EC191F0E3CBD00B0D868 /* PoolSdk.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = PoolSdk.framework; sourceTree = "<group>"; }; |
65 | 845D181B1C8D778400F27EB9 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = poolsdk_file/poolsdk/Images.xcassets; sourceTree = "<group>"; }; | 65 | 845D181B1C8D778400F27EB9 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = poolsdk_file/poolsdk/Images.xcassets; sourceTree = "<group>"; }; |
66 | 845D181C1C8D778400F27EB9 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = poolsdk_file/poolsdk/Info.plist; sourceTree = "<group>"; }; | 66 | 845D181C1C8D778400F27EB9 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = poolsdk_file/poolsdk/Info.plist; sourceTree = "<group>"; }; |
... | @@ -106,7 +106,7 @@ | ... | @@ -106,7 +106,7 @@ |
106 | 8484E5161EE7E36800B402D1 /* SystemConfiguration.framework in Frameworks */, | 106 | 8484E5161EE7E36800B402D1 /* SystemConfiguration.framework in Frameworks */, |
107 | 8484E4FC1EE7E1D800B402D1 /* libsqlite3.dylib in Frameworks */, | 107 | 8484E4FC1EE7E1D800B402D1 /* libsqlite3.dylib in Frameworks */, |
108 | 8484E5121EE7E2B800B402D1 /* libz.1.dylib in Frameworks */, | 108 | 8484E5121EE7E2B800B402D1 /* libz.1.dylib in Frameworks */, |
109 | - 26B975C020AD7A66001E5EF9 /* XiongDiSDK.framework in Frameworks */, | 109 | + 2691DA4620BB9E6400FEF5C3 /* HMHomeSDK.framework in Frameworks */, |
110 | 8484E5101EE7E29A00B402D1 /* libc++.1.dylib in Frameworks */, | 110 | 8484E5101EE7E29A00B402D1 /* libc++.1.dylib in Frameworks */, |
111 | 8484E5001EE7E20C00B402D1 /* CFNetwork.framework in Frameworks */, | 111 | 8484E5001EE7E20C00B402D1 /* CFNetwork.framework in Frameworks */, |
112 | 8484E5061EE7E24A00B402D1 /* CoreMotion.framework in Frameworks */, | 112 | 8484E5061EE7E24A00B402D1 /* CoreMotion.framework in Frameworks */, |
... | @@ -144,7 +144,7 @@ | ... | @@ -144,7 +144,7 @@ |
144 | 8476DF641C4DD71D00EC42BA /* poolsdk */ = { | 144 | 8476DF641C4DD71D00EC42BA /* poolsdk */ = { |
145 | isa = PBXGroup; | 145 | isa = PBXGroup; |
146 | children = ( | 146 | children = ( |
147 | - 26B975BF20AD7A66001E5EF9 /* XiongDiSDK.framework */, | 147 | + 2691DA4520BB9E6300FEF5C3 /* HMHomeSDK.framework */, |
148 | 84A090AC1F174E21003D23FB /* TrackingIO.h */, | 148 | 84A090AC1F174E21003D23FB /* TrackingIO.h */, |
149 | 84A090AA1F160A69003D23FB /* TrackingIO.a */, | 149 | 84A090AA1F160A69003D23FB /* TrackingIO.a */, |
150 | 846BD21F1EE9342700E89A1D /* pool_setting */, | 150 | 846BD21F1EE9342700E89A1D /* pool_setting */, | ... | ... |
No preview for this file type
PoolSdk_Demo/HMHomeSDK.framework/HMHomeSDK
0 → 100644
No preview for this file type
1 | #import <UIKit/UIKit.h> | 1 | #import <UIKit/UIKit.h> |
2 | -#import "XiongDiLoginInfo.h" | 2 | +#import "HMUser.h" |
3 | #import <JavaScriptCore/JavaScriptCore.h> | 3 | #import <JavaScriptCore/JavaScriptCore.h> |
4 | 4 | ||
5 | -@interface XiongDiViewController : UIViewController<UIWebViewDelegate,UIAlertViewDelegate> | 5 | +@interface HMHome : UIViewController<UIWebViewDelegate,UIAlertViewDelegate> |
6 | { | 6 | { |
7 | UIWebView *webView_; | 7 | UIWebView *webView_; |
8 | UIActivityIndicatorView *activityIndicator; | 8 | UIActivityIndicatorView *activityIndicator; |
9 | } | 9 | } |
10 | 10 | ||
11 | - | ||
12 | -//@property(assign) int webViewWidth; | ||
13 | -//@property(assign) int webViewHeight; | ||
14 | -//@property(assign) int screenwidth; | ||
15 | -//@property(assign) int screenHeight; | ||
16 | - | ||
17 | @property(assign) BOOL hasCorner; | 11 | @property(assign) BOOL hasCorner; |
18 | 12 | ||
19 | --(void)setXiongDiView:(int)webViewWidth :(int) webViewHeight :(int) screenwidth :(int) screenHeight; | 13 | +-(void)settingHMZoneView:(int)webViewWidth :(int) webViewHeight :(int) screenwidth :(int) screenHeight; |
20 | -- (void)initXiongDiWebView; | 14 | +- (void)initHMZoneWebView; |
21 | - (void)loadWebPageWithString:(NSString *)url; | 15 | - (void)loadWebPageWithString:(NSString *)url; |
22 | - (void)loadWebPageWithJs:(NSString *)content; | 16 | - (void)loadWebPageWithJs:(NSString *)content; |
23 | - (void)postNotification:(NSString *)name : (NSString *)code; | 17 | - (void)postNotification:(NSString *)name : (NSString *)code; | ... | ... |
1 | +#import <UIKit/UIKit.h> | ||
2 | +#import "StoreKit/StoreKit.h" | ||
3 | + | ||
4 | +@interface HMHomeManager : NSObject | ||
5 | +{ | ||
6 | + NSString* HMAPPID_; | ||
7 | + NSString* HMAPPKEY_; | ||
8 | + | ||
9 | + NSString* inviterCode_; | ||
10 | +} | ||
11 | + | ||
12 | +@property bool banana; | ||
13 | + | ||
14 | ++ (HMHomeManager *)getInstance; | ||
15 | +- (void)initHMZoneSDK; | ||
16 | + | ||
17 | +- (void)startHMZoneLogin:(NSString *)HMAPPID : (NSString *)HMAPPKEY : (UIViewController *)controller; | ||
18 | + | ||
19 | +- (void)setBabyStyleName:(NSString*)styleName; | ||
20 | + | ||
21 | +- (void)startHMZoneAlisha: (NSString *)fwqid : (NSString *)nickName : (NSNumber *)amount : (NSString *)callBack : (UIViewController *)controller; | ||
22 | + | ||
23 | +- (void)startWithHMZoneAlisha:(UIViewController*)controll products:(NSString*)products amount:(NSString*)amount productName:(NSString*)productName DdhID:(NSString*) DdhID; | ||
24 | + | ||
25 | + | ||
26 | + | ||
27 | +@end |
1 | #import <Foundation/Foundation.h> | 1 | #import <Foundation/Foundation.h> |
2 | 2 | ||
3 | -@interface XiongDiLoginInfo : NSObject //用户uid | 3 | +@interface HMUser : NSObject |
4 | { | 4 | { |
5 | // | 5 | // |
6 | NSString *openId; | 6 | NSString *openId; |
7 | -//token | ||
8 | NSString *token; | 7 | NSString *token; |
9 | -//时间戳 | ||
10 | NSString *timestamp; | 8 | NSString *timestamp; |
11 | 9 | ||
12 | } | 10 | } |
... | @@ -14,5 +12,5 @@ NSString *timestamp; | ... | @@ -14,5 +12,5 @@ NSString *timestamp; |
14 | @property(retain,nonatomic) NSString *openId; | 12 | @property(retain,nonatomic) NSString *openId; |
15 | @property(retain,nonatomic) NSString *token; | 13 | @property(retain,nonatomic) NSString *token; |
16 | @property(retain,nonatomic) NSString *timestamp; | 14 | @property(retain,nonatomic) NSString *timestamp; |
17 | -+ (XiongDiLoginInfo *)getInstance; | 15 | ++ (HMUser *)getInstance; |
18 | @end | 16 | @end | ... | ... |
No preview for this file type
No preview for this file type
1 | -#import <Foundation/Foundation.h> | ||
2 | - | ||
3 | -extern NSString * const XiongDiExitNotification; /**< 退出 */ | ||
4 | -extern NSString * const XiongDiLoginNotification; /**< 登录完成的通知*/ | ||
5 | -extern NSString * const XiongDiErrorNotification; /**< 出错 */ | ||
6 | - | ||
7 | - | ||
8 | -@interface XiongDiNotifications : NSObject | ||
9 | - | ||
10 | -@end |
1 | -#import <UIKit/UIKit.h> | ||
2 | -#import "StoreKit/StoreKit.h" | ||
3 | - | ||
4 | -@interface XiongDiSDKMgr : NSObject | ||
5 | -{ | ||
6 | - NSString* appId_; | ||
7 | - NSString* appKey_; | ||
8 | - | ||
9 | - NSString* inviterCode_; | ||
10 | -} | ||
11 | - | ||
12 | -@property bool banana; | ||
13 | - | ||
14 | -+ (XiongDiSDKMgr *)getInstance; | ||
15 | -- (void)initXiongDiSDK; | ||
16 | - | ||
17 | -- (void)startXiongDiLogin:(NSString *)appId : (NSString *)appKey : (UIViewController *)controller; | ||
18 | - | ||
19 | -- (void)setCoolStyleName:(NSString*)styleName; | ||
20 | - | ||
21 | -- (void)startXiongDiDelia: (NSString *)serverId : (NSString *)nickName : (NSNumber *)amount : (NSString *)callBack : (UIViewController *)controller; | ||
22 | - | ||
23 | -- (void)startWithXiongDiDelia:(UIViewController*)controll products:(NSString*)products amount:(NSString*)amount productName:(NSString*)productName queryId:(NSString*) queryId; | ||
24 | - | ||
25 | - | ||
26 | - | ||
27 | -@end |
No preview for this file type
... | @@ -17,7 +17,7 @@ | ... | @@ -17,7 +17,7 @@ |
17 | <key>CFBundlePackageType</key> | 17 | <key>CFBundlePackageType</key> |
18 | <string>APPL</string> | 18 | <string>APPL</string> |
19 | <key>CFBundleShortVersionString</key> | 19 | <key>CFBundleShortVersionString</key> |
20 | - <string>1.1.408</string> | 20 | + <string>1.1.407</string> |
21 | <key>CFBundleSignature</key> | 21 | <key>CFBundleSignature</key> |
22 | <string>????</string> | 22 | <string>????</string> |
23 | <key>CFBundleURLTypes</key> | 23 | <key>CFBundleURLTypes</key> | ... | ... |
1 | - | ||
2 | -// | ||
3 | -// PPInterface.h | ||
4 | -// PoolSdk | ||
5 | -// | ||
6 | -// Created by winFan on 11/23/15. | ||
7 | -// Copyright (c) 2015 winFan. All rights reserved. | ||
8 | -// | ||
9 | - | ||
10 | #import <PoolSdk/PoolSdk2.h> | 1 | #import <PoolSdk/PoolSdk2.h> |
11 | @interface SDKInterface : Interface | 2 | @interface SDKInterface : Interface |
12 | 3 | ||
13 | - | ||
14 | @end | 4 | @end | ... | ... |
1 | -// | ||
2 | -// UnionInterface.m | ||
3 | -// PoolSdk | ||
4 | -// | ||
5 | -// Created by winFan on 11/23/15. | ||
6 | -// Copyright (c) 2015 winFan. All rights reserved. | ||
7 | -// | ||
8 | #include "SDKInterface.h" | 1 | #include "SDKInterface.h" |
9 | #import <UIKit/UIKit.h> | 2 | #import <UIKit/UIKit.h> |
10 | 3 | ||
11 | -#import "XiongDiSDK/XiongDiSDKMgr.h" | 4 | +#import "HMHomeSDK/HMHomeManager.h" |
12 | -#import "XiongDiSDK/XiongDiNotifications.h" | 5 | +#import "HMHomeSDK/HMNotifications.h" |
13 | -#import "XiongDiSDK/XiongDiLoginInfo.h" | 6 | +#import "HMHomeSDK/HMUser.h" |
14 | #import "TrackingIO.h" | 7 | #import "TrackingIO.h" |
15 | 8 | ||
16 | -//SDK | ||
17 | - | ||
18 | - | ||
19 | @implementation SDKInterface : Interface | 9 | @implementation SDKInterface : Interface |
20 | 10 | ||
21 | - | ||
22 | int mExchange; | 11 | int mExchange; |
23 | NSString *sdkAppId; | 12 | NSString *sdkAppId; |
24 | NSString *sdkAppKey; | 13 | NSString *sdkAppKey; |
25 | 14 | ||
26 | - | ||
27 | -/** | ||
28 | - 初始化SDK | ||
29 | - */ | ||
30 | - (void)SDKinit:(UIViewController *) control | 15 | - (void)SDKinit:(UIViewController *) control |
31 | { | 16 | { |
32 | - //必须继承 | 17 | + |
33 | [super SDKinit:control]; | 18 | [super SDKinit:control]; |
34 | 19 | ||
35 | [PoolConfig getInstance]; | 20 | [PoolConfig getInstance]; |
36 | - [[XiongDiSDKMgr getInstance]initXiongDiSDK]; | 21 | + [[HMHomeManager getInstance]initHMZoneSDK]; |
37 | - [[XiongDiSDKMgr getInstance]setCoolStyleName:@"sdk"]; | 22 | + [[HMHomeManager getInstance]setBabyStyleName:@"sdk"]; |
38 | - [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(receiveLoginMessage:) name:XiongDiLoginNotification object:nil]; | 23 | + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(receiveLoginMessage:) name:HMZoneLoginNotification object:nil]; |
39 | - [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(XiongDiToolCallBack:) name:@"XiongDiToolCallBack" object:nil]; | 24 | + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(HMZoneToolCallBack:) name:@"HMZoneToolCallBack" object:nil]; |
40 | 25 | ||
41 | [[PoolChecker getInstance] sendNotice:PoolSDKNotificationInitSDK notiName:@"InitSuccess" statusCode:POOLSDK_NO_ERROR description:@"initSuccess" extendData:nil]; | 26 | [[PoolChecker getInstance] sendNotice:PoolSDKNotificationInitSDK notiName:@"InitSuccess" statusCode:POOLSDK_NO_ERROR description:@"initSuccess" extendData:nil]; |
42 | 27 | ||
... | @@ -45,10 +30,6 @@ NSString *sdkAppKey; | ... | @@ -45,10 +30,6 @@ NSString *sdkAppKey; |
45 | channelId = @"unknown"; | 30 | channelId = @"unknown"; |
46 | } | 31 | } |
47 | [TrackingIO initWithappKey:[[PoolConfig getInstance] getValueByKey:@"renyunAppKey"] withChannelId:channelId]; | 32 | [TrackingIO initWithappKey:[[PoolConfig getInstance] getValueByKey:@"renyunAppKey"] withChannelId:channelId]; |
48 | - | ||
49 | - //APPID APPKEY | ||
50 | - sdkAppId = [[PoolConfig getInstance] getValueByKey:@"APP_ID"]; | ||
51 | - sdkAppKey =[[PoolConfig getInstance] getValueByKey:@"APP_KEY"]; | ||
52 | } | 33 | } |
53 | 34 | ||
54 | /** | 35 | /** |
... | @@ -56,12 +37,10 @@ NSString *sdkAppKey; | ... | @@ -56,12 +37,10 @@ NSString *sdkAppKey; |
56 | */ | 37 | */ |
57 | - (void)SDKloginSDK | 38 | - (void)SDKloginSDK |
58 | { | 39 | { |
59 | - NSLog(@"调用了LoginSDK"); | 40 | + //APPID APPKEY |
60 | - //NSString *appId = [[PoolConfig getInstance] getValueByKey:@"APP_ID"]; | 41 | + sdkAppId = [[PoolConfig getInstance] getValueByKey:@"APP_ID"]; |
61 | - //NSString *appKey =[[PoolConfig getInstance] getValueByKey:@"APP_KEY"]; | 42 | + sdkAppKey =[[PoolConfig getInstance] getValueByKey:@"APP_KEY"]; |
62 | - NSLog(@"%@",sdkAppId); | 43 | + [[HMHomeManager getInstance]startHMZoneLogin:sdkAppId :sdkAppKey :self.controller]; |
63 | - NSLog(@"%@",sdkAppId); | ||
64 | - [[XiongDiSDKMgr getInstance]startXiongDiLogin:sdkAppId :sdkAppKey :self.controller]; | ||
65 | 44 | ||
66 | } | 45 | } |
67 | 46 | ||
... | @@ -72,9 +51,9 @@ NSString *sdkAppKey; | ... | @@ -72,9 +51,9 @@ NSString *sdkAppKey; |
72 | { | 51 | { |
73 | NSLog(@"loginchek"); | 52 | NSLog(@"loginchek"); |
74 | PoolLoginInfo *loginInfo = [PoolLoginInfo alloc]; | 53 | PoolLoginInfo *loginInfo = [PoolLoginInfo alloc]; |
75 | - loginInfo.openId = [[XiongDiLoginInfo getInstance]openId]; | 54 | + loginInfo.openId = [[HMUser getInstance]openId]; |
76 | - loginInfo.sign = [[XiongDiLoginInfo getInstance] token]; | 55 | + loginInfo.sign = [[HMUser getInstance] token]; |
77 | - loginInfo.timestamp = [XiongDiLoginInfo getInstance].timestamp; | 56 | + loginInfo.timestamp = [HMUser getInstance].timestamp; |
78 | 57 | ||
79 | dispatch_async(dispatch_get_global_queue(0, 0), ^{ | 58 | dispatch_async(dispatch_get_global_queue(0, 0), ^{ |
80 | [[PoolChecker getInstance] startCheck:loginInfo]; | 59 | [[PoolChecker getInstance] startCheck:loginInfo]; |
... | @@ -98,11 +77,11 @@ NSString *sdkAppKey; | ... | @@ -98,11 +77,11 @@ NSString *sdkAppKey; |
98 | 苹果支付结果回调 | 77 | 苹果支付结果回调 |
99 | */ | 78 | */ |
100 | 79 | ||
101 | -- (void)XiongDiToolCallBack:(NSNotification *)notification | 80 | +- (void)HMZoneToolCallBack:(NSNotification *)notification |
102 | { | 81 | { |
103 | NSDictionary* payResultDic = notification.object; | 82 | NSDictionary* payResultDic = notification.object; |
104 | 83 | ||
105 | - NSString* receiptStr = [payResultDic objectForKey:@"XiongDiToolResult"]; | 84 | + NSString* receiptStr = [payResultDic objectForKey:@"HMZoneToolResult"]; |
106 | NSString* queryId = [payResultDic objectForKey:@"query_id"]; | 85 | NSString* queryId = [payResultDic objectForKey:@"query_id"]; |
107 | 86 | ||
108 | NSDictionary* receiptDic = [NSDictionary dictionaryWithObjectsAndKeys:receiptStr,@"receipt",queryId,@"query_id", nil]; | 87 | NSDictionary* receiptDic = [NSDictionary dictionaryWithObjectsAndKeys:receiptStr,@"receipt",queryId,@"query_id", nil]; |
... | @@ -195,7 +174,7 @@ NSString *sdkAppKey; | ... | @@ -195,7 +174,7 @@ NSString *sdkAppKey; |
195 | 174 | ||
196 | NSLog(@"orderDic%@",queryIdArray); | 175 | NSLog(@"orderDic%@",queryIdArray); |
197 | NSUserDefaults* userDefaults = [NSUserDefaults standardUserDefaults]; | 176 | NSUserDefaults* userDefaults = [NSUserDefaults standardUserDefaults]; |
198 | - NSMutableArray* failQueryIdArray = [[NSMutableArray alloc]initWithCapacity:10];//补单失败的queryid集合 | 177 | + NSMutableArray* failQueryIdArray = [[NSMutableArray alloc]initWithCapacity:10]; |
199 | 178 | ||
200 | if(queryIdArray){ | 179 | if(queryIdArray){ |
201 | for (NSString* queryId in queryIdArray) { | 180 | for (NSString* queryId in queryIdArray) { |
... | @@ -236,10 +215,10 @@ NSString *sdkAppKey; | ... | @@ -236,10 +215,10 @@ NSString *sdkAppKey; |
236 | NSString *other = [payInfo other]; | 215 | NSString *other = [payInfo other]; |
237 | 216 | ||
238 | if (other && [other length] > 0) { | 217 | if (other && [other length] > 0) { |
239 | - [[XiongDiSDKMgr getInstance] startXiongDiDelia:serverId :roleName :amount :[payInfo queryId] :self.controller]; | 218 | + [[HMHomeManager getInstance] startHMZoneAlisha:serverId :roleName :amount :[payInfo queryId] :self.controller]; |
240 | }else{ | 219 | }else{ |
241 | NSString* products = [payInfo products]; | 220 | NSString* products = [payInfo products]; |
242 | - [[XiongDiSDKMgr getInstance] startWithXiongDiDelia:self.controller products:products amount:[payInfo postAmount] productName:[payInfo productName] queryId:queryId]; | 221 | + [[HMHomeManager getInstance] startWithHMZoneAlisha:self.controller products:products amount:[payInfo postAmount] productName:[payInfo productName] DdhID:queryId]; |
243 | } | 222 | } |
244 | } | 223 | } |
245 | 224 | ... | ... |
1 | 新接入请参考对接文档和demo<br> | 1 | 新接入请参考对接文档和demo<br> |
2 | 2 | ||
3 | -2018-05-23:<br> | 3 | +2018-05-28:<br> |
4 | -已接入快速更新方法:<br> | 4 | +已接入快速更新方法<br> |
5 | -1、 删除HaibaoSDK.framework<br> | 5 | +1、删除XingDiSDK.framework 删除HaibaoSDK.framework<br> |
6 | -2、 引入XiongDiSDK.framework<br> | 6 | +2、引入HMHomeSDK.framework<br> |
7 | -3、 替换SDKInterface.h和SDKInterface.m文件<br> | 7 | +3、替换SDKInterface.h和SDKInterface.m文件<br> |
8 | 4、 替换PoolSdk.framework<br> | 8 | 4、 替换PoolSdk.framework<br> |
9 | 5、 支付接口[[PoolSdk shareSDK] payWithPaymentInfo:orderInfo];修改为[[PoolSdk shareSDK] gzyazfWithGzyazfmentInfo:orderInfo];<br> | 9 | 5、 支付接口[[PoolSdk shareSDK] payWithPaymentInfo:orderInfo];修改为[[PoolSdk shareSDK] gzyazfWithGzyazfmentInfo:orderInfo];<br> |
10 | 6、 回调PoolSDKNotificationPay 修改为 PoolSDKNotificationGzyazf<br> | 10 | 6、 回调PoolSDKNotificationPay 修改为 PoolSDKNotificationGzyazf<br> | ... | ... |
No preview for this file type
No preview for this file type
1 | #import <UIKit/UIKit.h> | 1 | #import <UIKit/UIKit.h> |
2 | -#import "XiongDiLoginInfo.h" | 2 | +#import "HMUser.h" |
3 | #import <JavaScriptCore/JavaScriptCore.h> | 3 | #import <JavaScriptCore/JavaScriptCore.h> |
4 | 4 | ||
5 | -@interface XiongDiViewController : UIViewController<UIWebViewDelegate,UIAlertViewDelegate> | 5 | +@interface HMHome : UIViewController<UIWebViewDelegate,UIAlertViewDelegate> |
6 | { | 6 | { |
7 | UIWebView *webView_; | 7 | UIWebView *webView_; |
8 | UIActivityIndicatorView *activityIndicator; | 8 | UIActivityIndicatorView *activityIndicator; |
9 | } | 9 | } |
10 | 10 | ||
11 | - | ||
12 | -//@property(assign) int webViewWidth; | ||
13 | -//@property(assign) int webViewHeight; | ||
14 | -//@property(assign) int screenwidth; | ||
15 | -//@property(assign) int screenHeight; | ||
16 | - | ||
17 | @property(assign) BOOL hasCorner; | 11 | @property(assign) BOOL hasCorner; |
18 | 12 | ||
19 | --(void)setXiongDiView:(int)webViewWidth :(int) webViewHeight :(int) screenwidth :(int) screenHeight; | 13 | +-(void)settingHMZoneView:(int)webViewWidth :(int) webViewHeight :(int) screenwidth :(int) screenHeight; |
20 | -- (void)initXiongDiWebView; | 14 | +- (void)initHMZoneWebView; |
21 | - (void)loadWebPageWithString:(NSString *)url; | 15 | - (void)loadWebPageWithString:(NSString *)url; |
22 | - (void)loadWebPageWithJs:(NSString *)content; | 16 | - (void)loadWebPageWithJs:(NSString *)content; |
23 | - (void)postNotification:(NSString *)name : (NSString *)code; | 17 | - (void)postNotification:(NSString *)name : (NSString *)code; | ... | ... |
1 | +#import <UIKit/UIKit.h> | ||
2 | +#import "StoreKit/StoreKit.h" | ||
3 | + | ||
4 | +@interface HMHomeManager : NSObject | ||
5 | +{ | ||
6 | + NSString* HMAPPID_; | ||
7 | + NSString* HMAPPKEY_; | ||
8 | + | ||
9 | + NSString* inviterCode_; | ||
10 | +} | ||
11 | + | ||
12 | +@property bool banana; | ||
13 | + | ||
14 | ++ (HMHomeManager *)getInstance; | ||
15 | +- (void)initHMZoneSDK; | ||
16 | + | ||
17 | +- (void)startHMZoneLogin:(NSString *)HMAPPID : (NSString *)HMAPPKEY : (UIViewController *)controller; | ||
18 | + | ||
19 | +- (void)setBabyStyleName:(NSString*)styleName; | ||
20 | + | ||
21 | +- (void)startHMZoneAlisha: (NSString *)fwqid : (NSString *)nickName : (NSNumber *)amount : (NSString *)callBack : (UIViewController *)controller; | ||
22 | + | ||
23 | +- (void)startWithHMZoneAlisha:(UIViewController*)controll products:(NSString*)products amount:(NSString*)amount productName:(NSString*)productName DdhID:(NSString*) DdhID; | ||
24 | + | ||
25 | + | ||
26 | + | ||
27 | +@end |
1 | #import <Foundation/Foundation.h> | 1 | #import <Foundation/Foundation.h> |
2 | 2 | ||
3 | -@interface XiongDiLoginInfo : NSObject //用户uid | 3 | +@interface HMUser : NSObject |
4 | { | 4 | { |
5 | // | 5 | // |
6 | NSString *openId; | 6 | NSString *openId; |
7 | -//token | ||
8 | NSString *token; | 7 | NSString *token; |
9 | -//时间戳 | ||
10 | NSString *timestamp; | 8 | NSString *timestamp; |
11 | 9 | ||
12 | } | 10 | } |
... | @@ -14,5 +12,5 @@ NSString *timestamp; | ... | @@ -14,5 +12,5 @@ NSString *timestamp; |
14 | @property(retain,nonatomic) NSString *openId; | 12 | @property(retain,nonatomic) NSString *openId; |
15 | @property(retain,nonatomic) NSString *token; | 13 | @property(retain,nonatomic) NSString *token; |
16 | @property(retain,nonatomic) NSString *timestamp; | 14 | @property(retain,nonatomic) NSString *timestamp; |
17 | -+ (XiongDiLoginInfo *)getInstance; | 15 | ++ (HMUser *)getInstance; |
18 | @end | 16 | @end | ... | ... |
No preview for this file type
1 | - | ||
2 | -// | ||
3 | -// PPInterface.h | ||
4 | -// PoolSdk | ||
5 | -// | ||
6 | -// Created by winFan on 11/23/15. | ||
7 | -// Copyright (c) 2015 winFan. All rights reserved. | ||
8 | -// | ||
9 | - | ||
10 | #import <PoolSdk/PoolSdk2.h> | 1 | #import <PoolSdk/PoolSdk2.h> |
11 | @interface SDKInterface : Interface | 2 | @interface SDKInterface : Interface |
12 | 3 | ||
13 | - | ||
14 | @end | 4 | @end | ... | ... |
1 | -// | ||
2 | -// UnionInterface.m | ||
3 | -// PoolSdk | ||
4 | -// | ||
5 | -// Created by winFan on 11/23/15. | ||
6 | -// Copyright (c) 2015 winFan. All rights reserved. | ||
7 | -// | ||
8 | #include "SDKInterface.h" | 1 | #include "SDKInterface.h" |
9 | #import <UIKit/UIKit.h> | 2 | #import <UIKit/UIKit.h> |
10 | 3 | ||
11 | -#import "XiongDiSDK/XiongDiSDKMgr.h" | 4 | +#import "HMHomeSDK/HMHomeManager.h" |
12 | -#import "XiongDiSDK/XiongDiNotifications.h" | 5 | +#import "HMHomeSDK/HMNotifications.h" |
13 | -#import "XiongDiSDK/XiongDiLoginInfo.h" | 6 | +#import "HMHomeSDK/HMUser.h" |
14 | #import "TrackingIO.h" | 7 | #import "TrackingIO.h" |
15 | 8 | ||
16 | -//SDK | ||
17 | - | ||
18 | - | ||
19 | @implementation SDKInterface : Interface | 9 | @implementation SDKInterface : Interface |
20 | 10 | ||
21 | - | ||
22 | int mExchange; | 11 | int mExchange; |
23 | NSString *sdkAppId; | 12 | NSString *sdkAppId; |
24 | NSString *sdkAppKey; | 13 | NSString *sdkAppKey; |
25 | 14 | ||
26 | - | ||
27 | -/** | ||
28 | - 初始化SDK | ||
29 | - */ | ||
30 | - (void)SDKinit:(UIViewController *) control | 15 | - (void)SDKinit:(UIViewController *) control |
31 | { | 16 | { |
32 | - //必须继承 | 17 | + |
33 | [super SDKinit:control]; | 18 | [super SDKinit:control]; |
34 | 19 | ||
35 | [PoolConfig getInstance]; | 20 | [PoolConfig getInstance]; |
36 | - [[XiongDiSDKMgr getInstance]initXiongDiSDK]; | 21 | + [[HMHomeManager getInstance]initHMZoneSDK]; |
37 | - [[XiongDiSDKMgr getInstance]setCoolStyleName:@"sdk"]; | 22 | + [[HMHomeManager getInstance]setBabyStyleName:@"sdk"]; |
38 | - [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(receiveLoginMessage:) name:XiongDiLoginNotification object:nil]; | 23 | + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(receiveLoginMessage:) name:HMZoneLoginNotification object:nil]; |
39 | - [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(XiongDiToolCallBack:) name:@"XiongDiToolCallBack" object:nil]; | 24 | + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(HMZoneToolCallBack:) name:@"HMZoneToolCallBack" object:nil]; |
40 | 25 | ||
41 | [[PoolChecker getInstance] sendNotice:PoolSDKNotificationInitSDK notiName:@"InitSuccess" statusCode:POOLSDK_NO_ERROR description:@"initSuccess" extendData:nil]; | 26 | [[PoolChecker getInstance] sendNotice:PoolSDKNotificationInitSDK notiName:@"InitSuccess" statusCode:POOLSDK_NO_ERROR description:@"initSuccess" extendData:nil]; |
42 | 27 | ||
... | @@ -45,10 +30,6 @@ NSString *sdkAppKey; | ... | @@ -45,10 +30,6 @@ NSString *sdkAppKey; |
45 | channelId = @"unknown"; | 30 | channelId = @"unknown"; |
46 | } | 31 | } |
47 | [TrackingIO initWithappKey:[[PoolConfig getInstance] getValueByKey:@"renyunAppKey"] withChannelId:channelId]; | 32 | [TrackingIO initWithappKey:[[PoolConfig getInstance] getValueByKey:@"renyunAppKey"] withChannelId:channelId]; |
48 | - | ||
49 | - //APPID APPKEY | ||
50 | - sdkAppId = [[PoolConfig getInstance] getValueByKey:@"APP_ID"]; | ||
51 | - sdkAppKey =[[PoolConfig getInstance] getValueByKey:@"APP_KEY"]; | ||
52 | } | 33 | } |
53 | 34 | ||
54 | /** | 35 | /** |
... | @@ -56,12 +37,10 @@ NSString *sdkAppKey; | ... | @@ -56,12 +37,10 @@ NSString *sdkAppKey; |
56 | */ | 37 | */ |
57 | - (void)SDKloginSDK | 38 | - (void)SDKloginSDK |
58 | { | 39 | { |
59 | - NSLog(@"调用了LoginSDK"); | 40 | + //APPID APPKEY |
60 | - //NSString *appId = [[PoolConfig getInstance] getValueByKey:@"APP_ID"]; | 41 | + sdkAppId = [[PoolConfig getInstance] getValueByKey:@"APP_ID"]; |
61 | - //NSString *appKey =[[PoolConfig getInstance] getValueByKey:@"APP_KEY"]; | 42 | + sdkAppKey =[[PoolConfig getInstance] getValueByKey:@"APP_KEY"]; |
62 | - NSLog(@"%@",sdkAppId); | 43 | + [[HMHomeManager getInstance]startHMZoneLogin:sdkAppId :sdkAppKey :self.controller]; |
63 | - NSLog(@"%@",sdkAppId); | ||
64 | - [[XiongDiSDKMgr getInstance]startXiongDiLogin:sdkAppId :sdkAppKey :self.controller]; | ||
65 | 44 | ||
66 | } | 45 | } |
67 | 46 | ||
... | @@ -72,9 +51,9 @@ NSString *sdkAppKey; | ... | @@ -72,9 +51,9 @@ NSString *sdkAppKey; |
72 | { | 51 | { |
73 | NSLog(@"loginchek"); | 52 | NSLog(@"loginchek"); |
74 | PoolLoginInfo *loginInfo = [PoolLoginInfo alloc]; | 53 | PoolLoginInfo *loginInfo = [PoolLoginInfo alloc]; |
75 | - loginInfo.openId = [[XiongDiLoginInfo getInstance]openId]; | 54 | + loginInfo.openId = [[HMUser getInstance]openId]; |
76 | - loginInfo.sign = [[XiongDiLoginInfo getInstance] token]; | 55 | + loginInfo.sign = [[HMUser getInstance] token]; |
77 | - loginInfo.timestamp = [XiongDiLoginInfo getInstance].timestamp; | 56 | + loginInfo.timestamp = [HMUser getInstance].timestamp; |
78 | 57 | ||
79 | dispatch_async(dispatch_get_global_queue(0, 0), ^{ | 58 | dispatch_async(dispatch_get_global_queue(0, 0), ^{ |
80 | [[PoolChecker getInstance] startCheck:loginInfo]; | 59 | [[PoolChecker getInstance] startCheck:loginInfo]; |
... | @@ -98,11 +77,11 @@ NSString *sdkAppKey; | ... | @@ -98,11 +77,11 @@ NSString *sdkAppKey; |
98 | 苹果支付结果回调 | 77 | 苹果支付结果回调 |
99 | */ | 78 | */ |
100 | 79 | ||
101 | -- (void)XiongDiToolCallBack:(NSNotification *)notification | 80 | +- (void)HMZoneToolCallBack:(NSNotification *)notification |
102 | { | 81 | { |
103 | NSDictionary* payResultDic = notification.object; | 82 | NSDictionary* payResultDic = notification.object; |
104 | 83 | ||
105 | - NSString* receiptStr = [payResultDic objectForKey:@"XiongDiToolResult"]; | 84 | + NSString* receiptStr = [payResultDic objectForKey:@"HMZoneToolResult"]; |
106 | NSString* queryId = [payResultDic objectForKey:@"query_id"]; | 85 | NSString* queryId = [payResultDic objectForKey:@"query_id"]; |
107 | 86 | ||
108 | NSDictionary* receiptDic = [NSDictionary dictionaryWithObjectsAndKeys:receiptStr,@"receipt",queryId,@"query_id", nil]; | 87 | NSDictionary* receiptDic = [NSDictionary dictionaryWithObjectsAndKeys:receiptStr,@"receipt",queryId,@"query_id", nil]; |
... | @@ -195,7 +174,7 @@ NSString *sdkAppKey; | ... | @@ -195,7 +174,7 @@ NSString *sdkAppKey; |
195 | 174 | ||
196 | NSLog(@"orderDic%@",queryIdArray); | 175 | NSLog(@"orderDic%@",queryIdArray); |
197 | NSUserDefaults* userDefaults = [NSUserDefaults standardUserDefaults]; | 176 | NSUserDefaults* userDefaults = [NSUserDefaults standardUserDefaults]; |
198 | - NSMutableArray* failQueryIdArray = [[NSMutableArray alloc]initWithCapacity:10];//补单失败的queryid集合 | 177 | + NSMutableArray* failQueryIdArray = [[NSMutableArray alloc]initWithCapacity:10]; |
199 | 178 | ||
200 | if(queryIdArray){ | 179 | if(queryIdArray){ |
201 | for (NSString* queryId in queryIdArray) { | 180 | for (NSString* queryId in queryIdArray) { |
... | @@ -236,10 +215,10 @@ NSString *sdkAppKey; | ... | @@ -236,10 +215,10 @@ NSString *sdkAppKey; |
236 | NSString *other = [payInfo other]; | 215 | NSString *other = [payInfo other]; |
237 | 216 | ||
238 | if (other && [other length] > 0) { | 217 | if (other && [other length] > 0) { |
239 | - [[XiongDiSDKMgr getInstance] startXiongDiDelia:serverId :roleName :amount :[payInfo queryId] :self.controller]; | 218 | + [[HMHomeManager getInstance] startHMZoneAlisha:serverId :roleName :amount :[payInfo queryId] :self.controller]; |
240 | }else{ | 219 | }else{ |
241 | NSString* products = [payInfo products]; | 220 | NSString* products = [payInfo products]; |
242 | - [[XiongDiSDKMgr getInstance] startWithXiongDiDelia:self.controller products:products amount:[payInfo postAmount] productName:[payInfo productName] queryId:queryId]; | 221 | + [[HMHomeManager getInstance] startWithHMZoneAlisha:self.controller products:products amount:[payInfo postAmount] productName:[payInfo productName] DdhID:queryId]; |
243 | } | 222 | } |
244 | } | 223 | } |
245 | 224 | ... | ... |
No preview for this file type
1 | -#import <Foundation/Foundation.h> | ||
2 | - | ||
3 | -extern NSString * const XiongDiExitNotification; /**< 退出 */ | ||
4 | -extern NSString * const XiongDiLoginNotification; /**< 登录完成的通知*/ | ||
5 | -extern NSString * const XiongDiErrorNotification; /**< 出错 */ | ||
6 | - | ||
7 | - | ||
8 | -@interface XiongDiNotifications : NSObject | ||
9 | - | ||
10 | -@end |
1 | -#import <UIKit/UIKit.h> | ||
2 | -#import "StoreKit/StoreKit.h" | ||
3 | - | ||
4 | -@interface XiongDiSDKMgr : NSObject | ||
5 | -{ | ||
6 | - NSString* appId_; | ||
7 | - NSString* appKey_; | ||
8 | - | ||
9 | - NSString* inviterCode_; | ||
10 | -} | ||
11 | - | ||
12 | -@property bool banana; | ||
13 | - | ||
14 | -+ (XiongDiSDKMgr *)getInstance; | ||
15 | -- (void)initXiongDiSDK; | ||
16 | - | ||
17 | -- (void)startXiongDiLogin:(NSString *)appId : (NSString *)appKey : (UIViewController *)controller; | ||
18 | - | ||
19 | -- (void)setCoolStyleName:(NSString*)styleName; | ||
20 | - | ||
21 | -- (void)startXiongDiDelia: (NSString *)serverId : (NSString *)nickName : (NSNumber *)amount : (NSString *)callBack : (UIViewController *)controller; | ||
22 | - | ||
23 | -- (void)startWithXiongDiDelia:(UIViewController*)controll products:(NSString*)products amount:(NSString*)amount productName:(NSString*)productName queryId:(NSString*) queryId; | ||
24 | - | ||
25 | - | ||
26 | - | ||
27 | -@end |
No preview for this file type
-
Please register or login to post a comment