Showing
62 changed files
with
328 additions
and
246 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 | - 2622C8382202B0A400BF5D56 /* SpringFestival.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2622C8372202B0A300BF5D56 /* SpringFestival.framework */; }; | 10 | + 265E0B312213FAA9008A6CB2 /* Valentine.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 265E0B302213FAA9008A6CB2 /* Valentine.framework */; }; |
11 | 269F653821B6613F006AEC88 /* HaiBaoJuheSDK.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 269F653721B6613F006AEC88 /* HaiBaoJuheSDK.framework */; }; | 11 | 269F653821B6613F006AEC88 /* HaiBaoJuheSDK.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 269F653721B6613F006AEC88 /* HaiBaoJuheSDK.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 /* haibao_setting in Resources */ = {isa = PBXBuildFile; fileRef = 846BD21F1EE9342700E89A1D /* haibao_setting */; }; | 13 | 846BD2241EE9342700E89A1D /* haibao_setting in Resources */ = {isa = PBXBuildFile; fileRef = 846BD21F1EE9342700E89A1D /* haibao_setting */; }; |
... | @@ -59,7 +59,7 @@ | ... | @@ -59,7 +59,7 @@ |
59 | /* End PBXCopyFilesBuildPhase section */ | 59 | /* End PBXCopyFilesBuildPhase section */ |
60 | 60 | ||
61 | /* Begin PBXFileReference section */ | 61 | /* Begin PBXFileReference section */ |
62 | - 2622C8372202B0A300BF5D56 /* SpringFestival.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = SpringFestival.framework; sourceTree = "<group>"; }; | 62 | + 265E0B302213FAA9008A6CB2 /* Valentine.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = Valentine.framework; sourceTree = "<group>"; }; |
63 | 269F653721B6613F006AEC88 /* HaiBaoJuheSDK.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = HaiBaoJuheSDK.framework; sourceTree = "<group>"; }; | 63 | 269F653721B6613F006AEC88 /* HaiBaoJuheSDK.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = HaiBaoJuheSDK.framework; sourceTree = "<group>"; }; |
64 | 845D181B1C8D778400F27EB9 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = poolsdk_file/poolsdk/Images.xcassets; sourceTree = "<group>"; }; | 64 | 845D181B1C8D778400F27EB9 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = poolsdk_file/poolsdk/Images.xcassets; sourceTree = "<group>"; }; |
65 | 845D181C1C8D778400F27EB9 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = poolsdk_file/poolsdk/Info.plist; sourceTree = "<group>"; }; | 65 | 845D181C1C8D778400F27EB9 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = poolsdk_file/poolsdk/Info.plist; sourceTree = "<group>"; }; |
... | @@ -111,9 +111,9 @@ | ... | @@ -111,9 +111,9 @@ |
111 | 8484E5061EE7E24A00B402D1 /* CoreMotion.framework in Frameworks */, | 111 | 8484E5061EE7E24A00B402D1 /* CoreMotion.framework in Frameworks */, |
112 | 8484E5021EE7E21F00B402D1 /* UIKit.framework in Frameworks */, | 112 | 8484E5021EE7E21F00B402D1 /* UIKit.framework in Frameworks */, |
113 | 8484E50C1EE7E27100B402D1 /* CoreGraphics.framework in Frameworks */, | 113 | 8484E50C1EE7E27100B402D1 /* CoreGraphics.framework in Frameworks */, |
114 | + 265E0B312213FAA9008A6CB2 /* Valentine.framework in Frameworks */, | ||
114 | 8484E5081EE7E25600B402D1 /* CoreText.framework in Frameworks */, | 115 | 8484E5081EE7E25600B402D1 /* CoreText.framework in Frameworks */, |
115 | 8484E50E1EE7E28000B402D1 /* QuartzCore.framework in Frameworks */, | 116 | 8484E50E1EE7E28000B402D1 /* QuartzCore.framework in Frameworks */, |
116 | - 2622C8382202B0A400BF5D56 /* SpringFestival.framework in Frameworks */, | ||
117 | 8484E5141EE7E2DE00B402D1 /* Foundation.framework in Frameworks */, | 117 | 8484E5141EE7E2DE00B402D1 /* Foundation.framework in Frameworks */, |
118 | 8484E50A1EE7E26200B402D1 /* Security.framework in Frameworks */, | 118 | 8484E50A1EE7E26200B402D1 /* Security.framework in Frameworks */, |
119 | 8484E5041EE7E24400B402D1 /* StoreKit.framework in Frameworks */, | 119 | 8484E5041EE7E24400B402D1 /* StoreKit.framework in Frameworks */, |
... | @@ -143,7 +143,7 @@ | ... | @@ -143,7 +143,7 @@ |
143 | 8476DF641C4DD71D00EC42BA /* poolsdk */ = { | 143 | 8476DF641C4DD71D00EC42BA /* poolsdk */ = { |
144 | isa = PBXGroup; | 144 | isa = PBXGroup; |
145 | children = ( | 145 | children = ( |
146 | - 2622C8372202B0A300BF5D56 /* SpringFestival.framework */, | 146 | + 265E0B302213FAA9008A6CB2 /* Valentine.framework */, |
147 | 84A090AC1F174E21003D23FB /* TrackingIO.h */, | 147 | 84A090AC1F174E21003D23FB /* TrackingIO.h */, |
148 | 84A090AA1F160A69003D23FB /* TrackingIO.a */, | 148 | 84A090AA1F160A69003D23FB /* TrackingIO.a */, |
149 | 846BD21F1EE9342700E89A1D /* haibao_setting */, | 149 | 846BD21F1EE9342700E89A1D /* haibao_setting */, |
... | @@ -280,7 +280,7 @@ | ... | @@ -280,7 +280,7 @@ |
280 | TargetAttributes = { | 280 | TargetAttributes = { |
281 | BB5F3C871C1811BC00DA339D = { | 281 | BB5F3C871C1811BC00DA339D = { |
282 | CreatedOnToolsVersion = 6.4; | 282 | CreatedOnToolsVersion = 6.4; |
283 | - DevelopmentTeam = A3DGN26BA8; | 283 | + DevelopmentTeam = VJWR45W95K; |
284 | ProvisioningStyle = Manual; | 284 | ProvisioningStyle = Manual; |
285 | }; | 285 | }; |
286 | BB5F3CA01C1811BC00DA339D = { | 286 | BB5F3CA01C1811BC00DA339D = { |
... | @@ -469,7 +469,7 @@ | ... | @@ -469,7 +469,7 @@ |
469 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; | 469 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; |
470 | CODE_SIGN_STYLE = Manual; | 470 | CODE_SIGN_STYLE = Manual; |
471 | DEAD_CODE_STRIPPING = NO; | 471 | DEAD_CODE_STRIPPING = NO; |
472 | - DEVELOPMENT_TEAM = A3DGN26BA8; | 472 | + DEVELOPMENT_TEAM = VJWR45W95K; |
473 | ENABLE_BITCODE = NO; | 473 | ENABLE_BITCODE = NO; |
474 | FRAMEWORK_SEARCH_PATHS = ( | 474 | FRAMEWORK_SEARCH_PATHS = ( |
475 | "$(inherited)", | 475 | "$(inherited)", |
... | @@ -487,10 +487,10 @@ | ... | @@ -487,10 +487,10 @@ |
487 | ); | 487 | ); |
488 | ONLY_ACTIVE_ARCH = NO; | 488 | ONLY_ACTIVE_ARCH = NO; |
489 | OTHER_LDFLAGS = ""; | 489 | OTHER_LDFLAGS = ""; |
490 | - PRODUCT_BUNDLE_IDENTIFIER = com.mihuyo.beta; | 490 | + PRODUCT_BUNDLE_IDENTIFIER = com.zhiZU.Nxiay.pop; |
491 | PRODUCT_NAME = "$(TARGET_NAME)"; | 491 | PRODUCT_NAME = "$(TARGET_NAME)"; |
492 | - PROVISIONING_PROFILE = "f5e11833-b2e3-48fd-8903-8da416b533f7"; | 492 | + PROVISIONING_PROFILE = "152876c6-4bcd-4cec-b526-7f370953faab"; |
493 | - PROVISIONING_PROFILE_SPECIFIER = dev_provision; | 493 | + PROVISIONING_PROFILE_SPECIFIER = dev.zhiZU.Nxiay.pop; |
494 | TARGETED_DEVICE_FAMILY = "1,2"; | 494 | TARGETED_DEVICE_FAMILY = "1,2"; |
495 | VALID_ARCHS = "arm64 armv7s"; | 495 | VALID_ARCHS = "arm64 armv7s"; |
496 | }; | 496 | }; |
... | @@ -503,7 +503,7 @@ | ... | @@ -503,7 +503,7 @@ |
503 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; | 503 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; |
504 | CODE_SIGN_STYLE = Manual; | 504 | CODE_SIGN_STYLE = Manual; |
505 | DEAD_CODE_STRIPPING = NO; | 505 | DEAD_CODE_STRIPPING = NO; |
506 | - DEVELOPMENT_TEAM = A3DGN26BA8; | 506 | + DEVELOPMENT_TEAM = VJWR45W95K; |
507 | ENABLE_BITCODE = NO; | 507 | ENABLE_BITCODE = NO; |
508 | FRAMEWORK_SEARCH_PATHS = ( | 508 | FRAMEWORK_SEARCH_PATHS = ( |
509 | "$(inherited)", | 509 | "$(inherited)", |
... | @@ -521,10 +521,10 @@ | ... | @@ -521,10 +521,10 @@ |
521 | ); | 521 | ); |
522 | ONLY_ACTIVE_ARCH = NO; | 522 | ONLY_ACTIVE_ARCH = NO; |
523 | OTHER_LDFLAGS = ""; | 523 | OTHER_LDFLAGS = ""; |
524 | - PRODUCT_BUNDLE_IDENTIFIER = com.mihuyo.beta; | 524 | + PRODUCT_BUNDLE_IDENTIFIER = com.zhiZU.Nxiay.pop; |
525 | PRODUCT_NAME = "$(TARGET_NAME)"; | 525 | PRODUCT_NAME = "$(TARGET_NAME)"; |
526 | - PROVISIONING_PROFILE = "efde732c-987c-4f2a-bc64-c11762722e03"; | 526 | + PROVISIONING_PROFILE = "ac55fcfd-bf85-4d33-811e-28619d6dab44"; |
527 | - PROVISIONING_PROFILE_SPECIFIER = dis_provision; | 527 | + PROVISIONING_PROFILE_SPECIFIER = dis.zhiZU.Nxiay.pop; |
528 | TARGETED_DEVICE_FAMILY = "1,2"; | 528 | TARGETED_DEVICE_FAMILY = "1,2"; |
529 | VALID_ARCHS = "arm64 armv7s"; | 529 | VALID_ARCHS = "arm64 armv7s"; |
530 | }; | 530 | }; | ... | ... |
No preview for this file type
No preview for this file type
... | @@ -15,11 +15,11 @@ | ... | @@ -15,11 +15,11 @@ |
15 | - (void)initChecker; | 15 | - (void)initChecker; |
16 | - (void)startCheck:(HaiBaoJuheLoginInfo *)loginInfo; | 16 | - (void)startCheck:(HaiBaoJuheLoginInfo *)loginInfo; |
17 | - (void) createOrder:(HaiBaoJuheCreateOrderInfo *)gzyazfInfo; | 17 | - (void) createOrder:(HaiBaoJuheCreateOrderInfo *)gzyazfInfo; |
18 | -- (void) SpringFestivalHaiBaoJuhereportOpen; | 18 | +- (void) ValentineHaiBaoJuhereportOpen; |
19 | -- (void) SpringFestivalHaiBaoJuhereportSDKOpen; | 19 | +- (void) ValentineHaiBaoJuhereportSDKOpen; |
20 | -- (void)SpringFestivalHaiBaoJuhehandleFirstOpenApp:(NSString*) path; | 20 | +- (void)ValentineHaiBaoJuhehandleFirstOpenApp:(NSString*) path; |
21 | - (void) reportEnter:(HaiBaoJuheReportInfo *)reInfo; | 21 | - (void) reportEnter:(HaiBaoJuheReportInfo *)reInfo; |
22 | -- (void) SpringFestivalHaiBaoJuheReport:(NSString *)_action :(HaiBaoJuheReportInfo *)reInfo; | 22 | +- (void) ValentineHaiBaoJuheReport:(NSString *)_action :(HaiBaoJuheReportInfo *)reInfo; |
23 | - (void)sendNotice:(HaiBaoJuheSDKNotificationType)notiType | 23 | - (void)sendNotice:(HaiBaoJuheSDKNotificationType)notiType |
24 | notiName:(NSString *)notiName | 24 | notiName:(NSString *)notiName |
25 | statusCode:(int)nCode | 25 | statusCode:(int)nCode |
... | @@ -28,7 +28,7 @@ | ... | @@ -28,7 +28,7 @@ |
28 | 28 | ||
29 | - (void)startCheckDelegate:(HaiBaoJuheLoginInfo *)loginInfo; | 29 | - (void)startCheckDelegate:(HaiBaoJuheLoginInfo *)loginInfo; |
30 | 30 | ||
31 | -- (void)SpringFestivalHaiBaoJuheStartCheckDelegate:(HaiBaoJuheLoginInfo *)loginInfo type:(int)type; | 31 | +- (void)ValentineHaiBaoJuheStartCheckDelegate:(HaiBaoJuheLoginInfo *)loginInfo type:(int)type; |
32 | 32 | ||
33 | /* | 33 | /* |
34 | *初始化时调用 | 34 | *初始化时调用 | ... | ... |
1 | -#import "HaiBaoJuheSDK/SpringFestivalHaiBaoJuheBaseModel.h" | 1 | +#import "HaiBaoJuheSDK/ValentineHaiBaoJuheBaseModel.h" |
2 | -@interface HaiBaoJuheCreateOrderInfo : SpringFestivalHaiBaoJuheBaseModel | 2 | +@interface HaiBaoJuheCreateOrderInfo : ValentineHaiBaoJuheBaseModel |
3 | 3 | ||
4 | @property(nonatomic,strong)NSString *serverId;//服务器ID | 4 | @property(nonatomic,strong)NSString *serverId;//服务器ID |
5 | @property(nonatomic, strong)NSString *serverName;//服务器名称 | 5 | @property(nonatomic, strong)NSString *serverName;//服务器名称 |
... | @@ -16,7 +16,7 @@ | ... | @@ -16,7 +16,7 @@ |
16 | @property(nonatomic, strong)NSString *userId;//用户ID | 16 | @property(nonatomic, strong)NSString *userId;//用户ID |
17 | @property(nonatomic, strong)NSString *timestamp;//时间戳 | 17 | @property(nonatomic, strong)NSString *timestamp;//时间戳 |
18 | 18 | ||
19 | -- (NSString *) SpringFestivalHaiBaoJuheGetTsign ; | 19 | +- (NSString *) ValentineHaiBaoJuheGetTsign ; |
20 | -- (NSString *) SpringFestivalHaiBaoJuheGetTimestamp ; | 20 | +- (NSString *) ValentineHaiBaoJuheGetTimestamp ; |
21 | 21 | ||
22 | @end | 22 | @end | ... | ... |
1 | -#import "HaiBaoJuheSDK/SpringFestivalHaiBaoJuheBaseModel.h" | 1 | +#import "HaiBaoJuheSDK/ValentineHaiBaoJuheBaseModel.h" |
2 | -@interface HaiBaoJuheGzyazfInfo : SpringFestivalHaiBaoJuheBaseModel | 2 | +@interface HaiBaoJuheGzyazfInfo : ValentineHaiBaoJuheBaseModel |
3 | 3 | ||
4 | @property(nonatomic, strong)NSString *serverId; | 4 | @property(nonatomic, strong)NSString *serverId; |
5 | @property(nonatomic, strong)NSString *queryId; | 5 | @property(nonatomic, strong)NSString *queryId; | ... | ... |
1 | -#import "HaiBaoJuheSDK/SpringFestivalHaiBaoJuheBaseModel.h" | 1 | +#import "HaiBaoJuheSDK/ValentineHaiBaoJuheBaseModel.h" |
2 | -@interface HaiBaoJuheLoginInfo : SpringFestivalHaiBaoJuheBaseModel | 2 | +@interface HaiBaoJuheLoginInfo : ValentineHaiBaoJuheBaseModel |
3 | 3 | ||
4 | @property(nonatomic,strong)NSString *timestamp; | 4 | @property(nonatomic,strong)NSString *timestamp; |
5 | @property(nonatomic, strong)NSString *sign; | 5 | @property(nonatomic, strong)NSString *sign; | ... | ... |
1 | // | 1 | // |
2 | -// SpringFestivalHaiBaoJuheReportInfo.h | 2 | +// ValentineHaiBaoJuheReportInfo.h |
3 | // HaiBaoJuheSDK | 3 | // HaiBaoJuheSDK |
4 | // | 4 | // |
5 | // Created by winFan on 12/21/15. | 5 | // Created by winFan on 12/21/15. |
6 | // Copyright (c) 2015 winFan. All rights reserved. | 6 | // Copyright (c) 2015 winFan. All rights reserved. |
7 | // | 7 | // |
8 | 8 | ||
9 | -#import "HaiBaoJuheSDK/SpringFestivalHaiBaoJuheBaseModel.h" | 9 | +#import "HaiBaoJuheSDK/ValentineHaiBaoJuheBaseModel.h" |
10 | -@interface HaiBaoJuheReportInfo : SpringFestivalHaiBaoJuheBaseModel | 10 | +@interface HaiBaoJuheReportInfo : ValentineHaiBaoJuheBaseModel |
11 | 11 | ||
12 | @property(nonatomic, strong)NSString *reportType;//类型 | 12 | @property(nonatomic, strong)NSString *reportType;//类型 |
13 | @property(nonatomic, strong)NSString *playerId;//玩家ID | 13 | @property(nonatomic, strong)NSString *playerId;//玩家ID | ... | ... |
... | @@ -4,7 +4,7 @@ | ... | @@ -4,7 +4,7 @@ |
4 | @interface HaiBaoJuheUtils : NSObject | 4 | @interface HaiBaoJuheUtils : NSObject |
5 | 5 | ||
6 | +(NSString *)md5:(NSString *)str; | 6 | +(NSString *)md5:(NSString *)str; |
7 | -+ (NSDictionary *)SpringFestivalHaiBaoJuheDictionaryWithJsonString:(NSString *)jsonString; | 7 | ++ (NSDictionary *)ValentineHaiBaoJuheDictionaryWithJsonString:(NSString *)jsonString; |
8 | +(NSString *)createGzyazfOrderUrl; | 8 | +(NSString *)createGzyazfOrderUrl; |
9 | //*充值回调地址 | 9 | //*充值回调地址 |
10 | +(NSString *)createGzyazfUrl; | 10 | +(NSString *)createGzyazfUrl; | ... | ... |
1 | #import <Foundation/Foundation.h> | 1 | #import <Foundation/Foundation.h> |
2 | #import "OtherSetting.h" | 2 | #import "OtherSetting.h" |
3 | 3 | ||
4 | -@interface SpringFestivalHaiBaoJuheBaseModel : NSObject | 4 | +@interface ValentineHaiBaoJuheBaseModel : NSObject |
5 | 5 | ||
6 | -- (NSString *)SpringFestivalHaiBaoJuheObjectToJsonString; | 6 | +- (NSString *)ValentineHaiBaoJuheObjectToJsonString; |
7 | - (NSMutableString *)paramAddToString; | 7 | - (NSMutableString *)paramAddToString; |
8 | - (id)initWithDiction:(NSDictionary *)diction; | 8 | - (id)initWithDiction:(NSDictionary *)diction; |
9 | 9 | ... | ... |
... | @@ -11,7 +11,7 @@ typedef NS_ENUM(NSInteger, DGLoggerLevel) | ... | @@ -11,7 +11,7 @@ typedef NS_ENUM(NSInteger, DGLoggerLevel) |
11 | ELogError | 11 | ELogError |
12 | }; | 12 | }; |
13 | 13 | ||
14 | -@interface SpringFestivalHaiBaoJuheDGLogger : NSObject | 14 | +@interface ValentineHaiBaoJuheDGLogger : NSObject |
15 | 15 | ||
16 | + (void)showLog:(NSString *)fmt,...; | 16 | + (void)showLog:(NSString *)fmt,...; |
17 | 17 | ... | ... |
... | @@ -103,11 +103,11 @@ NSString* sdkUserId = @""; | ... | @@ -103,11 +103,11 @@ NSString* sdkUserId = @""; |
103 | [payInfo setServerId:@"99887766"]; | 103 | [payInfo setServerId:@"99887766"]; |
104 | [payInfo setPlayerName:@"iamrolename"]; | 104 | [payInfo setPlayerName:@"iamrolename"]; |
105 | [payInfo setPlayerLevel:@"10"]; | 105 | [payInfo setPlayerLevel:@"10"]; |
106 | - [payInfo setUserId:sdkUserId]; | 106 | + //[payInfo setUserId:sdkUserId]; |
107 | - [payInfo setPostAmount:@"1"]; | 107 | + [payInfo setPostAmount:@"6"]; |
108 | - [payInfo setProductId:@"com.xiongdi.xunqinji.6"]; | 108 | + [payInfo setProductId:@"com.zhiZU.Nxiay.pop.6"]; |
109 | [payInfo setPlayerId:@"1231241234"]; | 109 | [payInfo setPlayerId:@"1231241234"]; |
110 | - [payInfo setProductName:@"com.xiongdi.xunqinji.6"]; | 110 | + [payInfo setProductName:@"60元宝"]; |
111 | [payInfo setProductDesc:@"productDes"]; | 111 | [payInfo setProductDesc:@"productDes"]; |
112 | [payInfo setTimestamp:@"1232134"]; | 112 | [payInfo setTimestamp:@"1232134"]; |
113 | [payInfo setExchange:@"10"]; | 113 | [payInfo setExchange:@"10"]; | ... | ... |
1 | -#import <UIKit/UIKit.h> | ||
2 | - | ||
3 | -@interface SpringFestivalIAPHelperControl : NSObject<UITableViewDelegate, UITableViewDataSource> | ||
4 | - | ||
5 | -@property(nonatomic,strong) NSString* SpringFestivalDingDanHao; | ||
6 | -@property(nonatomic,strong) NSDictionary* SpringFestivalHuoWuLieBiao; | ||
7 | -@property(nonatomic,strong) NSMutableArray* SpringFestivalHuoWuIDLieBiao; | ||
8 | -@property(nonatomic, strong) UITableView *SpringFestivalHuoWuLieBiaoView; | ||
9 | - | ||
10 | -- (void)SpringFestivalHuaQianView:(UIViewController*)controller SpringFestivalHuoWuD:(NSString*)products SpringFestivalQian:(NSString*)amount SpringFestivalHuoWuMing:(NSString*)productName SpringFestivalDingDanHao:(NSString*)DingDanHao; | ||
11 | - | ||
12 | -@end |
1 | -#import <UIKit/UIKit.h> | ||
2 | -#import "StoreKit/StoreKit.h" | ||
3 | - | ||
4 | -@interface SpringFestivalAllManager : NSObject | ||
5 | -{ | ||
6 | - NSString* SpringFestivalAPPID_; | ||
7 | - NSString* SpringFestivalAPPKEY_; | ||
8 | - | ||
9 | - NSString* SpringFestivalInviterCode_; | ||
10 | -} | ||
11 | - | ||
12 | -@property bool SpringFestivalGeiWoHuaQianBa; | ||
13 | - | ||
14 | -+ (SpringFestivalAllManager *)SpringFestivalInstance; | ||
15 | - | ||
16 | -- (void)SpringFestivalChuShiHua; | ||
17 | - | ||
18 | -- (void)SpringFestivalDengLu:(NSString *)SpringFestivalAPPID : (NSString *)SpringFestivalAPPKEY : (UIViewController *)controller; | ||
19 | - | ||
20 | -- (void)SpringFestivalYangShi:(NSString*)SpringFestivalLeiXing; | ||
21 | - | ||
22 | -- (void)SpringFestivalQuery: (NSString *)SpringFestivalFuWuQiID : (NSString *)SpringFestivalNickName : (NSNumber *)SpringFestivalAmount : (NSString *)SpringFestivalCallBack : (UIViewController *)controller : (NSString *)SpringFestivalServerName; | ||
23 | - | ||
24 | -- (void)SpringFestivalQueryOperation:(UIViewController*)controll SpringFestivalHuoWuID:(NSString*)products SpringFestivalJiaGe:(NSString*)amount SpringFestivalHuoWuMing:(NSString*)productName SpringFestivalDingDanHao:(NSString*) DingDanHao; | ||
25 | - | ||
26 | - | ||
27 | - | ||
28 | -@end |
1 | +#import <UIKit/UIKit.h> | ||
2 | +#import "StoreKit/StoreKit.h" | ||
3 | + | ||
4 | +@interface ValentineAllManager : NSObject | ||
5 | +{ | ||
6 | + NSString* ValentineAPPID_; | ||
7 | + NSString* ValentineAPPKEY_; | ||
8 | + | ||
9 | + NSString* ValentineInviterCode_; | ||
10 | +} | ||
11 | + | ||
12 | +@property bool ValentineGeiWoHuaQianBa; | ||
13 | + | ||
14 | ++ (ValentineAllManager *)ValentineInstance; | ||
15 | + | ||
16 | +- (void)ValentineChuShiHua; | ||
17 | + | ||
18 | +- (void)ValentineDengLu:(NSString *)ValentineAPPID : (NSString *)ValentineAPPKEY : (UIViewController *)controller; | ||
19 | + | ||
20 | +- (void)ValentineYangShi:(NSString*)ValentineLeiXing; | ||
21 | + | ||
22 | +- (void)ValentineQuery: (NSString *)ValentineFuWuQiID : (NSString *)ValentineNickName : (NSNumber *)ValentineAmount : (NSString *)ValentineCallBack : (UIViewController *)controller : (NSString *)ValentineServerName; | ||
23 | + | ||
24 | +- (void)ValentineQueryOperation:(UIViewController*)controll ValentineHuoWuID:(NSString*)products ValentineJiaGe:(NSString*)amount ValentineHuoWuMing:(NSString*)productName ValentineDingDanHao:(NSString*) DingDanHao; | ||
25 | + | ||
26 | + | ||
27 | + | ||
28 | +@end |
1 | +#import <UIKit/UIKit.h> | ||
2 | + | ||
3 | +@interface ValentineIAPHelperControl : NSObject<UITableViewDelegate, UITableViewDataSource> | ||
4 | + | ||
5 | +@property(nonatomic,strong) NSString* ValentineDingDanHao; | ||
6 | +@property(nonatomic,strong) NSDictionary* ValentineHuoWuLieBiao; | ||
7 | +@property(nonatomic,strong) NSMutableArray* ValentineHuoWuIDLieBiao; | ||
8 | +@property(nonatomic, strong) UITableView *ValentineHuoWuLieBiaoView; | ||
9 | + | ||
10 | +- (void)ValentineHuaQianView:(UIViewController*)controller ValentineHuoWuD:(NSString*)products ValentineQian:(NSString*)amount ValentineHuoWuMing:(NSString*)productName ValentineDingDanHao:(NSString*)DingDanHao; | ||
11 | + | ||
12 | +@end |
1 | #import <Foundation/Foundation.h> | 1 | #import <Foundation/Foundation.h> |
2 | 2 | ||
3 | -@interface SpringFestivalInformation : NSObject | 3 | +@interface ValentineInformation : NSObject |
4 | { | 4 | { |
5 | // | 5 | // |
6 | NSString *openId; | 6 | NSString *openId; |
... | @@ -12,5 +12,5 @@ NSString *timestamp; | ... | @@ -12,5 +12,5 @@ NSString *timestamp; |
12 | @property(retain,nonatomic) NSString *openId; | 12 | @property(retain,nonatomic) NSString *openId; |
13 | @property(retain,nonatomic) NSString *token; | 13 | @property(retain,nonatomic) NSString *token; |
14 | @property(retain,nonatomic) NSString *timestamp; | 14 | @property(retain,nonatomic) NSString *timestamp; |
15 | -+ (SpringFestivalInformation *)getInstance; | 15 | ++ (ValentineInformation *)getInstance; |
16 | @end | 16 | @end | ... | ... |
1 | #import <UIKit/UIKit.h> | 1 | #import <UIKit/UIKit.h> |
2 | -#import "SpringFestivalInformation.h" | 2 | +#import "ValentineInformation.h" |
3 | #import <JavaScriptCore/JavaScriptCore.h> | 3 | #import <JavaScriptCore/JavaScriptCore.h> |
4 | 4 | ||
5 | -@interface SpringFestivalMain : UIViewController<UIWebViewDelegate,UIAlertViewDelegate> | 5 | +@interface ValentineMain : UIViewController<UIWebViewDelegate,UIAlertViewDelegate> |
6 | { | 6 | { |
7 | UIWebView *webView_; | 7 | UIWebView *webView_; |
8 | UIActivityIndicatorView *activityIndicator; | 8 | UIActivityIndicatorView *activityIndicator; |
9 | } | 9 | } |
10 | 10 | ||
11 | -@property(assign) BOOL SpringFestivalYouYuanJiao; | 11 | +@property(assign) BOOL ValentineYouYuanJiao; |
12 | 12 | ||
13 | -- (void)SpringFestivalSettingCKAssetsView:(int)webViewWidth :(int) webViewHeight :(int) screenwidth :(int) screenHeight; | 13 | +- (void)ValentineSettingValentineView:(int)webViewWidth :(int) webViewHeight :(int) screenwidth :(int) screenHeight; |
14 | -- (void)SpringFestivalChuShiHuaWebView; | 14 | +- (void)ValentineChuShiHuaWebView; |
15 | - (void)loadWebPageWithString:(NSString *)url; | 15 | - (void)loadWebPageWithString:(NSString *)url; |
16 | - (void)loadWebPageWithJs:(NSString *)content; | 16 | - (void)loadWebPageWithJs:(NSString *)content; |
17 | - (void)postNotification:(NSString *)name : (NSString *)code; | 17 | - (void)postNotification:(NSString *)name : (NSString *)code; | ... | ... |
No preview for this file type
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.0.0</string> |
21 | <key>CFBundleSignature</key> | 21 | <key>CFBundleSignature</key> |
22 | <string>????</string> | 22 | <string>????</string> |
23 | <key>CFBundleURLTypes</key> | 23 | <key>CFBundleURLTypes</key> | ... | ... |
1 | #include "SDKInterface.h" | 1 | #include "SDKInterface.h" |
2 | #import <UIKit/UIKit.h> | 2 | #import <UIKit/UIKit.h> |
3 | 3 | ||
4 | -#import "SpringFestival/SpringFestivalAllManager.h" | 4 | +#import "Valentine/ValentineAllManager.h" |
5 | -#import "SpringFestival/SpringFestivalHuiTiaoNotification.h" | 5 | +#import "Valentine/ValentineHuiTiaoNotification.h" |
6 | -#import "SpringFestival/SpringFestivalInformation.h" | 6 | +#import "Valentine/ValentineInformation.h" |
7 | 7 | ||
8 | #import "TrackingIO.h" | 8 | #import "TrackingIO.h" |
9 | 9 | ||
10 | @implementation SDKInterface : Interface | 10 | @implementation SDKInterface : Interface |
11 | 11 | ||
12 | int mExchange; | 12 | int mExchange; |
13 | -NSString *SpringFestivalAppId; | 13 | +NSString *ValentineAppId; |
14 | -NSString *SpringFestivalAppKey; | 14 | +NSString *ValentineAppKey; |
15 | +NSString *ValentineLeakOrderUrl; | ||
15 | 16 | ||
16 | - (void)SDKinit:(UIViewController *) control | 17 | - (void)SDKinit:(UIViewController *) control |
17 | { | 18 | { |
... | @@ -19,10 +20,10 @@ NSString *SpringFestivalAppKey; | ... | @@ -19,10 +20,10 @@ NSString *SpringFestivalAppKey; |
19 | [super SDKinit:control]; | 20 | [super SDKinit:control]; |
20 | 21 | ||
21 | [HaiBaoJuheConfig getInstance]; | 22 | [HaiBaoJuheConfig getInstance]; |
22 | - [[SpringFestivalAllManager SpringFestivalInstance]SpringFestivalChuShiHua]; | 23 | + [[ValentineAllManager ValentineInstance]ValentineChuShiHua]; |
23 | - [[SpringFestivalAllManager SpringFestivalInstance]SpringFestivalYangShi:@"sdk"]; | 24 | + [[ValentineAllManager ValentineInstance]ValentineYangShi:@"sdk"]; |
24 | - [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(receiveLoginMessage:) name:SpringFestivalLoginNotification object:nil]; | 25 | + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(receiveLoginMessage:) name:ValentineLoginNotification object:nil]; |
25 | - [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(HCKAssetsToolCallBack:) name:@"SpringFestivalToolCallBack" object:nil]; | 26 | + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(HCKAssetsToolCallBack:) name:@"ValentineToolCallBack" object:nil]; |
26 | 27 | ||
27 | [[HaiBaoJuheChecker getInstance] sendNotice:HaiBaoJuheSDKNotificationInitSDK notiName:@"InitSuccess" statusCode:HaiBaoJuheSDK_NO_ERROR description:@"initSuccess" extendData:nil]; | 28 | [[HaiBaoJuheChecker getInstance] sendNotice:HaiBaoJuheSDKNotificationInitSDK notiName:@"InitSuccess" statusCode:HaiBaoJuheSDK_NO_ERROR description:@"initSuccess" extendData:nil]; |
28 | 29 | ||
... | @@ -39,9 +40,9 @@ NSString *SpringFestivalAppKey; | ... | @@ -39,9 +40,9 @@ NSString *SpringFestivalAppKey; |
39 | - (void)SDKloginSDK | 40 | - (void)SDKloginSDK |
40 | { | 41 | { |
41 | //APPID APPKEY | 42 | //APPID APPKEY |
42 | - SpringFestivalAppId = [[HaiBaoJuheConfig getInstance] getValueByKey:@"APP_ID"]; | 43 | + ValentineAppId = [[HaiBaoJuheConfig getInstance] getValueByKey:@"APP_ID"]; |
43 | - SpringFestivalAppKey =[[HaiBaoJuheConfig getInstance] getValueByKey:@"APP_KEY"]; | 44 | + ValentineAppKey =[[HaiBaoJuheConfig getInstance] getValueByKey:@"APP_KEY"]; |
44 | - [[SpringFestivalAllManager SpringFestivalInstance]SpringFestivalDengLu:SpringFestivalAppId :SpringFestivalAppKey :self.controller]; | 45 | + [[ValentineAllManager ValentineInstance]ValentineDengLu:ValentineAppId :ValentineAppKey :self.controller]; |
45 | 46 | ||
46 | } | 47 | } |
47 | 48 | ||
... | @@ -52,9 +53,9 @@ NSString *SpringFestivalAppKey; | ... | @@ -52,9 +53,9 @@ NSString *SpringFestivalAppKey; |
52 | { | 53 | { |
53 | NSLog(@"loginchek"); | 54 | NSLog(@"loginchek"); |
54 | HaiBaoJuheLoginInfo *loginInfo = [HaiBaoJuheLoginInfo alloc]; | 55 | HaiBaoJuheLoginInfo *loginInfo = [HaiBaoJuheLoginInfo alloc]; |
55 | - loginInfo.openId = [[SpringFestivalInformation getInstance]openId]; | 56 | + loginInfo.openId = [[ValentineInformation getInstance]openId]; |
56 | - loginInfo.sign = [[SpringFestivalInformation getInstance] token]; | 57 | + loginInfo.sign = [[ValentineInformation getInstance] token]; |
57 | - loginInfo.timestamp = [[SpringFestivalInformation getInstance] timestamp]; | 58 | + loginInfo.timestamp = [[ValentineInformation getInstance] timestamp]; |
58 | 59 | ||
59 | dispatch_async(dispatch_get_global_queue(0, 0), ^{ | 60 | dispatch_async(dispatch_get_global_queue(0, 0), ^{ |
60 | [[HaiBaoJuheChecker getInstance] startCheck:loginInfo]; | 61 | [[HaiBaoJuheChecker getInstance] startCheck:loginInfo]; |
... | @@ -81,35 +82,35 @@ NSString *SpringFestivalAppKey; | ... | @@ -81,35 +82,35 @@ NSString *SpringFestivalAppKey; |
81 | - (void)HCKAssetsToolCallBack:(NSNotification *)notification | 82 | - (void)HCKAssetsToolCallBack:(NSNotification *)notification |
82 | { | 83 | { |
83 | NSDictionary* payResultDic = notification.object; | 84 | NSDictionary* payResultDic = notification.object; |
84 | - | 85 | + NSString* receiptStr = [payResultDic objectForKey:@"ValentineToolResult"]; |
85 | - NSString* receiptStr = [payResultDic objectForKey:@"SpringFestivalToolResult"]; | ||
86 | NSString* queryId = [payResultDic objectForKey:@"query_id"]; | 86 | NSString* queryId = [payResultDic objectForKey:@"query_id"]; |
87 | 87 | ||
88 | - NSDictionary* receiptDic = [NSDictionary dictionaryWithObjectsAndKeys:receiptStr,@"receipt",queryId,@"query_id", nil]; | 88 | + //收到回调,保存queryid和data |
89 | - NSString* result = [[NetCenter getInstance] httpPostSyn:[HaiBaoJuheUtils createGzyazfUrl] :receiptDic]; | ||
90 | - | ||
91 | - | ||
92 | - if([@"success" isEqualToString:result]){//确认订单成功 | ||
93 | - }else{//失败 | ||
94 | NSUserDefaults* userDefaults = [NSUserDefaults standardUserDefaults]; | 89 | NSUserDefaults* userDefaults = [NSUserDefaults standardUserDefaults]; |
95 | NSMutableArray* queryIdArray = [userDefaults objectForKey:@"queryIds"]; | 90 | NSMutableArray* queryIdArray = [userDefaults objectForKey:@"queryIds"]; |
96 | - | ||
97 | NSMutableArray* tempQueryIdArray = [[NSMutableArray alloc] initWithCapacity:10]; | 91 | NSMutableArray* tempQueryIdArray = [[NSMutableArray alloc] initWithCapacity:10]; |
98 | - | ||
99 | if (queryIdArray) { | 92 | if (queryIdArray) { |
100 | }else{ | 93 | }else{ |
101 | queryIdArray = [[NSMutableArray alloc]initWithCapacity:10]; | 94 | queryIdArray = [[NSMutableArray alloc]initWithCapacity:10]; |
102 | } | 95 | } |
103 | - | ||
104 | for (NSString* arrayQueryId in queryIdArray) { | 96 | for (NSString* arrayQueryId in queryIdArray) { |
105 | [tempQueryIdArray addObject:arrayQueryId]; | 97 | [tempQueryIdArray addObject:arrayQueryId]; |
106 | } | 98 | } |
107 | - | ||
108 | [tempQueryIdArray addObject:queryId]; | 99 | [tempQueryIdArray addObject:queryId]; |
109 | [userDefaults setObject:tempQueryIdArray forKey:@"queryIds"]; | 100 | [userDefaults setObject:tempQueryIdArray forKey:@"queryIds"]; |
110 | [userDefaults setObject:receiptStr forKey:queryId]; | 101 | [userDefaults setObject:receiptStr forKey:queryId]; |
111 | - [userDefaults synchronize]; | 102 | + |
103 | + NSDictionary* receiptDic = [NSDictionary dictionaryWithObjectsAndKeys:receiptStr,@"receipt",queryId,@"query_id", nil]; | ||
104 | + NSString* result = [[NetCenter getInstance] httpPostSyn:ValentineLeakOrderUrl :receiptDic]; | ||
105 | + | ||
106 | + if([@"success" isEqualToString:result]){//确认订单成功 | ||
107 | + //删除已保存的 | ||
108 | + [userDefaults removeObjectForKey:queryId]; | ||
109 | + [tempQueryIdArray removeObject:queryId]; | ||
110 | + [userDefaults setObject:tempQueryIdArray forKey:@"queryIds"]; | ||
111 | + [userDefaults removeObjectForKey:@"lastqueryid"]; | ||
112 | } | 112 | } |
113 | + [userDefaults synchronize]; | ||
113 | } | 114 | } |
114 | 115 | ||
115 | /** | 116 | /** |
... | @@ -117,8 +118,38 @@ NSString *SpringFestivalAppKey; | ... | @@ -117,8 +118,38 @@ NSString *SpringFestivalAppKey; |
117 | */ | 118 | */ |
118 | - (void)SDKgzyazfWithGzyazfmentInfo:(HaiBaoJuheCreateOrderInfo *)payInfo | 119 | - (void)SDKgzyazfWithGzyazfmentInfo:(HaiBaoJuheCreateOrderInfo *)payInfo |
119 | { | 120 | { |
121 | + NSUserDefaults* userDefaults = [NSUserDefaults standardUserDefaults]; | ||
122 | + NSString* lastqueryid = [userDefaults objectForKey:@"lastqueryid"]; | ||
123 | + | ||
124 | + ValentineLeakOrderUrl = [[NSString alloc] initWithFormat:@"%@?uid=%@&playerid=%@", | ||
125 | + [HaiBaoJuheUtils createGzyazfUrl], | ||
126 | + [payInfo userId], | ||
127 | + [payInfo playerId]]; | ||
128 | + [userDefaults setObject:ValentineLeakOrderUrl forKey:@"lastValentineLeakOrderUrl"]; | ||
129 | + | ||
130 | + if (lastqueryid!=nil) { | ||
131 | + //创建订单前进行补单 | ||
132 | + NSData* receiptData = [NSData dataWithContentsOfURL:[[NSBundle mainBundle] appStoreReceiptURL]]; | ||
133 | + NSString* receiptStr = [receiptData base64EncodedStringWithOptions:NSDataBase64Encoding64CharacterLineLength]; | ||
134 | + if (receiptStr!=nil) { | ||
135 | + receiptStr = [receiptStr stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]]; | ||
136 | + //如果不为空,进行最后一次补单 | ||
137 | + NSDictionary* receiptDic = [NSDictionary dictionaryWithObjectsAndKeys:receiptStr,@"receipt",lastqueryid,@"query_id", nil]; | ||
138 | + NSString* result = [[NetCenter getInstance] httpPostSyn:ValentineLeakOrderUrl :receiptDic]; | ||
139 | + if([@"success" isEqualToString:result]){//确认订单成功 | ||
140 | + //删除已保存的 | ||
141 | + [userDefaults removeObjectForKey:@"lastqueryid"]; | ||
142 | + } | ||
143 | + } | ||
144 | + } | ||
145 | + | ||
120 | mExchange = [payInfo exchange].intValue; | 146 | mExchange = [payInfo exchange].intValue; |
121 | [super SDKgzyazfWithGzyazfmentInfo:payInfo]; | 147 | [super SDKgzyazfWithGzyazfmentInfo:payInfo]; |
148 | + ValentineLeakOrderUrl = [[NSString alloc] initWithFormat:@"%@?uid=%@&playerid=%@", | ||
149 | + [HaiBaoJuheUtils createGzyazfUrl], | ||
150 | + [payInfo userId], | ||
151 | + [payInfo playerId]]; | ||
152 | + [userDefaults synchronize]; | ||
122 | } | 153 | } |
123 | 154 | ||
124 | /** | 155 | /** |
... | @@ -181,7 +212,13 @@ NSString *SpringFestivalAppKey; | ... | @@ -181,7 +212,13 @@ NSString *SpringFestivalAppKey; |
181 | for (NSString* queryId in queryIdArray) { | 212 | for (NSString* queryId in queryIdArray) { |
182 | NSString* receiptStr = [userDefaults valueForKey:queryId]; | 213 | NSString* receiptStr = [userDefaults valueForKey:queryId]; |
183 | NSDictionary* receiptDic = [NSDictionary dictionaryWithObjectsAndKeys:receiptStr,@"receipt",queryId,@"query_id", nil]; | 214 | NSDictionary* receiptDic = [NSDictionary dictionaryWithObjectsAndKeys:receiptStr,@"receipt",queryId,@"query_id", nil]; |
184 | - NSString* result = [[NetCenter getInstance] httpPostSyn:[HaiBaoJuheUtils createGzyazfUrl] :receiptDic]; | 215 | + NSString* lastValentineLeakOrderUrl = [userDefaults objectForKey:@"lastValentineLeakOrderUrl"]; |
216 | + NSString* result; | ||
217 | + if (lastValentineLeakOrderUrl!=nil) { | ||
218 | + result = [[NetCenter getInstance] httpPostSyn:lastValentineLeakOrderUrl :receiptDic]; | ||
219 | + }else{ | ||
220 | + result = [[NetCenter getInstance] httpPostSyn:[HaiBaoJuheUtils createGzyazfUrl] :receiptDic]; | ||
221 | + } | ||
185 | if([@"success" isEqualToString:result]){//成功 | 222 | if([@"success" isEqualToString:result]){//成功 |
186 | [userDefaults removeObjectForKey:queryId]; | 223 | [userDefaults removeObjectForKey:queryId]; |
187 | }else{//补单失败 | 224 | }else{//补单失败 |
... | @@ -216,10 +253,14 @@ NSString *SpringFestivalAppKey; | ... | @@ -216,10 +253,14 @@ NSString *SpringFestivalAppKey; |
216 | NSString *other = [payInfo other]; | 253 | NSString *other = [payInfo other]; |
217 | 254 | ||
218 | if (other && [other length] > 0) { | 255 | if (other && [other length] > 0) { |
219 | - [[SpringFestivalAllManager SpringFestivalInstance] SpringFestivalQuery:serverId :roleName :amount :[payInfo queryId] :self.controller :[payInfo serverName]]; | 256 | + [[ValentineAllManager ValentineInstance] ValentineQuery:serverId :roleName :amount :[payInfo queryId] :self.controller :[payInfo serverName]]; |
220 | }else{ | 257 | }else{ |
221 | NSString* products = [payInfo products]; | 258 | NSString* products = [payInfo products]; |
222 | - [[SpringFestivalAllManager SpringFestivalInstance] SpringFestivalQueryOperation:self.controller SpringFestivalHuoWuID:products SpringFestivalJiaGe:[payInfo postAmount] SpringFestivalHuoWuMing:[payInfo productName] SpringFestivalDingDanHao:queryId]; | 259 | + //保存订单号到本地 |
260 | + NSUserDefaults* userDefaults = [NSUserDefaults standardUserDefaults]; | ||
261 | + [userDefaults setObject:queryId forKey:@"lastqueryid"]; | ||
262 | + [userDefaults synchronize]; | ||
263 | + [[ValentineAllManager ValentineInstance] ValentineQueryOperation:self.controller ValentineHuoWuID:products ValentineJiaGe:[payInfo postAmount] ValentineHuoWuMing:[payInfo productName] ValentineDingDanHao:queryId]; | ||
223 | } | 264 | } |
224 | } | 265 | } |
225 | 266 | ... | ... |
1 | -{"renyunAppKey": "false", "payorderurl": "https://public.sdk.haibaoyouxi.com/paycheck/create", "usertype": 150, "sdkSimpleName": "apple_youyu", "gamechannelid": "", "APP_KEY": "b06b86b79c25774ec758657a7203bae6", "custom": "{}", "sdkVersionCode": "V1_1", "loginCheckUrl": "https://public.sdk.haibaoyouxi.com/logincheck/check", "appScheme": "com.jghb.xinqinji", "c2": "", "c1": "", "APP_ID": "58fd78a9834e7246b8dc0eac", "paycheckurl": "https://public.sdk.haibaoyouxi.com/paycheck/confirm", "gameSimpleName": "testest"} | 1 | +{"renyunAppKey": "false", "payorderurl": "https://public.sdk.haibaoyouxi.com/paycheck/create", "usertype": 150, "sdkSimpleName": "apple_youyu", "gamechannelid": "", "APP_KEY": "14cddef1ab2ef10c2eb8df15425be969", "custom": "{}", "sdkVersionCode": "V1_2", "loginCheckUrl": "https://public.sdk.haibaoyouxi.com/logincheck/check", "appScheme": "com.zhiZU.Nxiay.pop", "c2": "", "c1": "", "APP_ID": "5c37065cf0d770131edba7d6", "paycheckurl": "https://public.sdk.haibaoyouxi.com/paycheck/confirm", "gameSimpleName": "cesi"} | ... | ... |
... | @@ -10,9 +10,9 @@ | ... | @@ -10,9 +10,9 @@ |
10 | 7、``` 所有接口PoolSdk 替换成 HaiBaoJuheSDK(如不理解可以参考demo或者详细文档) ``` <br> | 10 | 7、``` 所有接口PoolSdk 替换成 HaiBaoJuheSDK(如不理解可以参考demo或者详细文档) ``` <br> |
11 | 11 | ||
12 | 12 | ||
13 | -已更新 海豹聚合SDK 2018年12月05日版本 快速更新到 2019年01月31日版本方法<br> | 13 | +已更新 海豹聚合SDK 2018年12月05日版本 快速更新到 2019年02月13日版本方法<br> |
14 | 1、``` 删除poolsdk_file文件夹中原来framework ``` <br> | 14 | 1、``` 删除poolsdk_file文件夹中原来framework ``` <br> |
15 | -2、``` 引入poolsdk_file文件夹中SpringFestival.framework ``` <br> | 15 | +2、``` 引入poolsdk_file文件夹中Valentine.framework ``` <br> |
16 | 3、``` 替换SDKInterface.m文件 ``` <br> | 16 | 3、``` 替换SDKInterface.m文件 ``` <br> |
17 | 4、``` 替换HaiBaoJuheSDK.framework ``` <br> | 17 | 4、``` 替换HaiBaoJuheSDK.framework ``` <br> |
18 | 5、``` 原 URL Schemes 中的 i9133public 改为 sdk.uuufish.com (可参考demo中info设置) ``` <br> | 18 | 5、``` 原 URL Schemes 中的 i9133public 改为 sdk.uuufish.com (可参考demo中info设置) ``` <br> |
... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
No preview for this file type
... | @@ -15,11 +15,11 @@ | ... | @@ -15,11 +15,11 @@ |
15 | - (void)initChecker; | 15 | - (void)initChecker; |
16 | - (void)startCheck:(HaiBaoJuheLoginInfo *)loginInfo; | 16 | - (void)startCheck:(HaiBaoJuheLoginInfo *)loginInfo; |
17 | - (void) createOrder:(HaiBaoJuheCreateOrderInfo *)gzyazfInfo; | 17 | - (void) createOrder:(HaiBaoJuheCreateOrderInfo *)gzyazfInfo; |
18 | -- (void) SpringFestivalHaiBaoJuhereportOpen; | 18 | +- (void) ValentineHaiBaoJuhereportOpen; |
19 | -- (void) SpringFestivalHaiBaoJuhereportSDKOpen; | 19 | +- (void) ValentineHaiBaoJuhereportSDKOpen; |
20 | -- (void)SpringFestivalHaiBaoJuhehandleFirstOpenApp:(NSString*) path; | 20 | +- (void)ValentineHaiBaoJuhehandleFirstOpenApp:(NSString*) path; |
21 | - (void) reportEnter:(HaiBaoJuheReportInfo *)reInfo; | 21 | - (void) reportEnter:(HaiBaoJuheReportInfo *)reInfo; |
22 | -- (void) SpringFestivalHaiBaoJuheReport:(NSString *)_action :(HaiBaoJuheReportInfo *)reInfo; | 22 | +- (void) ValentineHaiBaoJuheReport:(NSString *)_action :(HaiBaoJuheReportInfo *)reInfo; |
23 | - (void)sendNotice:(HaiBaoJuheSDKNotificationType)notiType | 23 | - (void)sendNotice:(HaiBaoJuheSDKNotificationType)notiType |
24 | notiName:(NSString *)notiName | 24 | notiName:(NSString *)notiName |
25 | statusCode:(int)nCode | 25 | statusCode:(int)nCode |
... | @@ -28,7 +28,7 @@ | ... | @@ -28,7 +28,7 @@ |
28 | 28 | ||
29 | - (void)startCheckDelegate:(HaiBaoJuheLoginInfo *)loginInfo; | 29 | - (void)startCheckDelegate:(HaiBaoJuheLoginInfo *)loginInfo; |
30 | 30 | ||
31 | -- (void)SpringFestivalHaiBaoJuheStartCheckDelegate:(HaiBaoJuheLoginInfo *)loginInfo type:(int)type; | 31 | +- (void)ValentineHaiBaoJuheStartCheckDelegate:(HaiBaoJuheLoginInfo *)loginInfo type:(int)type; |
32 | 32 | ||
33 | /* | 33 | /* |
34 | *初始化时调用 | 34 | *初始化时调用 | ... | ... |
1 | -#import "HaiBaoJuheSDK/SpringFestivalHaiBaoJuheBaseModel.h" | 1 | +#import "HaiBaoJuheSDK/ValentineHaiBaoJuheBaseModel.h" |
2 | -@interface HaiBaoJuheCreateOrderInfo : SpringFestivalHaiBaoJuheBaseModel | 2 | +@interface HaiBaoJuheCreateOrderInfo : ValentineHaiBaoJuheBaseModel |
3 | 3 | ||
4 | @property(nonatomic,strong)NSString *serverId;//服务器ID | 4 | @property(nonatomic,strong)NSString *serverId;//服务器ID |
5 | @property(nonatomic, strong)NSString *serverName;//服务器名称 | 5 | @property(nonatomic, strong)NSString *serverName;//服务器名称 |
... | @@ -16,7 +16,7 @@ | ... | @@ -16,7 +16,7 @@ |
16 | @property(nonatomic, strong)NSString *userId;//用户ID | 16 | @property(nonatomic, strong)NSString *userId;//用户ID |
17 | @property(nonatomic, strong)NSString *timestamp;//时间戳 | 17 | @property(nonatomic, strong)NSString *timestamp;//时间戳 |
18 | 18 | ||
19 | -- (NSString *) SpringFestivalHaiBaoJuheGetTsign ; | 19 | +- (NSString *) ValentineHaiBaoJuheGetTsign ; |
20 | -- (NSString *) SpringFestivalHaiBaoJuheGetTimestamp ; | 20 | +- (NSString *) ValentineHaiBaoJuheGetTimestamp ; |
21 | 21 | ||
22 | @end | 22 | @end | ... | ... |
1 | -#import "HaiBaoJuheSDK/SpringFestivalHaiBaoJuheBaseModel.h" | 1 | +#import "HaiBaoJuheSDK/ValentineHaiBaoJuheBaseModel.h" |
2 | -@interface HaiBaoJuheGzyazfInfo : SpringFestivalHaiBaoJuheBaseModel | 2 | +@interface HaiBaoJuheGzyazfInfo : ValentineHaiBaoJuheBaseModel |
3 | 3 | ||
4 | @property(nonatomic, strong)NSString *serverId; | 4 | @property(nonatomic, strong)NSString *serverId; |
5 | @property(nonatomic, strong)NSString *queryId; | 5 | @property(nonatomic, strong)NSString *queryId; | ... | ... |
1 | -#import "HaiBaoJuheSDK/SpringFestivalHaiBaoJuheBaseModel.h" | 1 | +#import "HaiBaoJuheSDK/ValentineHaiBaoJuheBaseModel.h" |
2 | -@interface HaiBaoJuheLoginInfo : SpringFestivalHaiBaoJuheBaseModel | 2 | +@interface HaiBaoJuheLoginInfo : ValentineHaiBaoJuheBaseModel |
3 | 3 | ||
4 | @property(nonatomic,strong)NSString *timestamp; | 4 | @property(nonatomic,strong)NSString *timestamp; |
5 | @property(nonatomic, strong)NSString *sign; | 5 | @property(nonatomic, strong)NSString *sign; | ... | ... |
1 | // | 1 | // |
2 | -// SpringFestivalHaiBaoJuheReportInfo.h | 2 | +// ValentineHaiBaoJuheReportInfo.h |
3 | // HaiBaoJuheSDK | 3 | // HaiBaoJuheSDK |
4 | // | 4 | // |
5 | // Created by winFan on 12/21/15. | 5 | // Created by winFan on 12/21/15. |
6 | // Copyright (c) 2015 winFan. All rights reserved. | 6 | // Copyright (c) 2015 winFan. All rights reserved. |
7 | // | 7 | // |
8 | 8 | ||
9 | -#import "HaiBaoJuheSDK/SpringFestivalHaiBaoJuheBaseModel.h" | 9 | +#import "HaiBaoJuheSDK/ValentineHaiBaoJuheBaseModel.h" |
10 | -@interface HaiBaoJuheReportInfo : SpringFestivalHaiBaoJuheBaseModel | 10 | +@interface HaiBaoJuheReportInfo : ValentineHaiBaoJuheBaseModel |
11 | 11 | ||
12 | @property(nonatomic, strong)NSString *reportType;//类型 | 12 | @property(nonatomic, strong)NSString *reportType;//类型 |
13 | @property(nonatomic, strong)NSString *playerId;//玩家ID | 13 | @property(nonatomic, strong)NSString *playerId;//玩家ID | ... | ... |
... | @@ -4,7 +4,7 @@ | ... | @@ -4,7 +4,7 @@ |
4 | @interface HaiBaoJuheUtils : NSObject | 4 | @interface HaiBaoJuheUtils : NSObject |
5 | 5 | ||
6 | +(NSString *)md5:(NSString *)str; | 6 | +(NSString *)md5:(NSString *)str; |
7 | -+ (NSDictionary *)SpringFestivalHaiBaoJuheDictionaryWithJsonString:(NSString *)jsonString; | 7 | ++ (NSDictionary *)ValentineHaiBaoJuheDictionaryWithJsonString:(NSString *)jsonString; |
8 | +(NSString *)createGzyazfOrderUrl; | 8 | +(NSString *)createGzyazfOrderUrl; |
9 | //*充值回调地址 | 9 | //*充值回调地址 |
10 | +(NSString *)createGzyazfUrl; | 10 | +(NSString *)createGzyazfUrl; | ... | ... |
1 | #import <Foundation/Foundation.h> | 1 | #import <Foundation/Foundation.h> |
2 | #import "OtherSetting.h" | 2 | #import "OtherSetting.h" |
3 | 3 | ||
4 | -@interface SpringFestivalHaiBaoJuheBaseModel : NSObject | 4 | +@interface ValentineHaiBaoJuheBaseModel : NSObject |
5 | 5 | ||
6 | -- (NSString *)SpringFestivalHaiBaoJuheObjectToJsonString; | 6 | +- (NSString *)ValentineHaiBaoJuheObjectToJsonString; |
7 | - (NSMutableString *)paramAddToString; | 7 | - (NSMutableString *)paramAddToString; |
8 | - (id)initWithDiction:(NSDictionary *)diction; | 8 | - (id)initWithDiction:(NSDictionary *)diction; |
9 | 9 | ... | ... |
... | @@ -11,7 +11,7 @@ typedef NS_ENUM(NSInteger, DGLoggerLevel) | ... | @@ -11,7 +11,7 @@ typedef NS_ENUM(NSInteger, DGLoggerLevel) |
11 | ELogError | 11 | ELogError |
12 | }; | 12 | }; |
13 | 13 | ||
14 | -@interface SpringFestivalHaiBaoJuheDGLogger : NSObject | 14 | +@interface ValentineHaiBaoJuheDGLogger : NSObject |
15 | 15 | ||
16 | + (void)showLog:(NSString *)fmt,...; | 16 | + (void)showLog:(NSString *)fmt,...; |
17 | 17 | ... | ... |
1 | #include "SDKInterface.h" | 1 | #include "SDKInterface.h" |
2 | #import <UIKit/UIKit.h> | 2 | #import <UIKit/UIKit.h> |
3 | 3 | ||
4 | -#import "SpringFestival/SpringFestivalAllManager.h" | 4 | +#import "Valentine/ValentineAllManager.h" |
5 | -#import "SpringFestival/SpringFestivalHuiTiaoNotification.h" | 5 | +#import "Valentine/ValentineHuiTiaoNotification.h" |
6 | -#import "SpringFestival/SpringFestivalInformation.h" | 6 | +#import "Valentine/ValentineInformation.h" |
7 | 7 | ||
8 | #import "TrackingIO.h" | 8 | #import "TrackingIO.h" |
9 | 9 | ||
10 | @implementation SDKInterface : Interface | 10 | @implementation SDKInterface : Interface |
11 | 11 | ||
12 | int mExchange; | 12 | int mExchange; |
13 | -NSString *SpringFestivalAppId; | 13 | +NSString *ValentineAppId; |
14 | -NSString *SpringFestivalAppKey; | 14 | +NSString *ValentineAppKey; |
15 | +NSString *ValentineLeakOrderUrl; | ||
15 | 16 | ||
16 | - (void)SDKinit:(UIViewController *) control | 17 | - (void)SDKinit:(UIViewController *) control |
17 | { | 18 | { |
... | @@ -19,10 +20,10 @@ NSString *SpringFestivalAppKey; | ... | @@ -19,10 +20,10 @@ NSString *SpringFestivalAppKey; |
19 | [super SDKinit:control]; | 20 | [super SDKinit:control]; |
20 | 21 | ||
21 | [HaiBaoJuheConfig getInstance]; | 22 | [HaiBaoJuheConfig getInstance]; |
22 | - [[SpringFestivalAllManager SpringFestivalInstance]SpringFestivalChuShiHua]; | 23 | + [[ValentineAllManager ValentineInstance]ValentineChuShiHua]; |
23 | - [[SpringFestivalAllManager SpringFestivalInstance]SpringFestivalYangShi:@"sdk"]; | 24 | + [[ValentineAllManager ValentineInstance]ValentineYangShi:@"sdk"]; |
24 | - [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(receiveLoginMessage:) name:SpringFestivalLoginNotification object:nil]; | 25 | + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(receiveLoginMessage:) name:ValentineLoginNotification object:nil]; |
25 | - [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(HCKAssetsToolCallBack:) name:@"SpringFestivalToolCallBack" object:nil]; | 26 | + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(HCKAssetsToolCallBack:) name:@"ValentineToolCallBack" object:nil]; |
26 | 27 | ||
27 | [[HaiBaoJuheChecker getInstance] sendNotice:HaiBaoJuheSDKNotificationInitSDK notiName:@"InitSuccess" statusCode:HaiBaoJuheSDK_NO_ERROR description:@"initSuccess" extendData:nil]; | 28 | [[HaiBaoJuheChecker getInstance] sendNotice:HaiBaoJuheSDKNotificationInitSDK notiName:@"InitSuccess" statusCode:HaiBaoJuheSDK_NO_ERROR description:@"initSuccess" extendData:nil]; |
28 | 29 | ||
... | @@ -39,9 +40,9 @@ NSString *SpringFestivalAppKey; | ... | @@ -39,9 +40,9 @@ NSString *SpringFestivalAppKey; |
39 | - (void)SDKloginSDK | 40 | - (void)SDKloginSDK |
40 | { | 41 | { |
41 | //APPID APPKEY | 42 | //APPID APPKEY |
42 | - SpringFestivalAppId = [[HaiBaoJuheConfig getInstance] getValueByKey:@"APP_ID"]; | 43 | + ValentineAppId = [[HaiBaoJuheConfig getInstance] getValueByKey:@"APP_ID"]; |
43 | - SpringFestivalAppKey =[[HaiBaoJuheConfig getInstance] getValueByKey:@"APP_KEY"]; | 44 | + ValentineAppKey =[[HaiBaoJuheConfig getInstance] getValueByKey:@"APP_KEY"]; |
44 | - [[SpringFestivalAllManager SpringFestivalInstance]SpringFestivalDengLu:SpringFestivalAppId :SpringFestivalAppKey :self.controller]; | 45 | + [[ValentineAllManager ValentineInstance]ValentineDengLu:ValentineAppId :ValentineAppKey :self.controller]; |
45 | 46 | ||
46 | } | 47 | } |
47 | 48 | ||
... | @@ -52,9 +53,9 @@ NSString *SpringFestivalAppKey; | ... | @@ -52,9 +53,9 @@ NSString *SpringFestivalAppKey; |
52 | { | 53 | { |
53 | NSLog(@"loginchek"); | 54 | NSLog(@"loginchek"); |
54 | HaiBaoJuheLoginInfo *loginInfo = [HaiBaoJuheLoginInfo alloc]; | 55 | HaiBaoJuheLoginInfo *loginInfo = [HaiBaoJuheLoginInfo alloc]; |
55 | - loginInfo.openId = [[SpringFestivalInformation getInstance]openId]; | 56 | + loginInfo.openId = [[ValentineInformation getInstance]openId]; |
56 | - loginInfo.sign = [[SpringFestivalInformation getInstance] token]; | 57 | + loginInfo.sign = [[ValentineInformation getInstance] token]; |
57 | - loginInfo.timestamp = [[SpringFestivalInformation getInstance] timestamp]; | 58 | + loginInfo.timestamp = [[ValentineInformation getInstance] timestamp]; |
58 | 59 | ||
59 | dispatch_async(dispatch_get_global_queue(0, 0), ^{ | 60 | dispatch_async(dispatch_get_global_queue(0, 0), ^{ |
60 | [[HaiBaoJuheChecker getInstance] startCheck:loginInfo]; | 61 | [[HaiBaoJuheChecker getInstance] startCheck:loginInfo]; |
... | @@ -81,35 +82,35 @@ NSString *SpringFestivalAppKey; | ... | @@ -81,35 +82,35 @@ NSString *SpringFestivalAppKey; |
81 | - (void)HCKAssetsToolCallBack:(NSNotification *)notification | 82 | - (void)HCKAssetsToolCallBack:(NSNotification *)notification |
82 | { | 83 | { |
83 | NSDictionary* payResultDic = notification.object; | 84 | NSDictionary* payResultDic = notification.object; |
84 | - | 85 | + NSString* receiptStr = [payResultDic objectForKey:@"ValentineToolResult"]; |
85 | - NSString* receiptStr = [payResultDic objectForKey:@"SpringFestivalToolResult"]; | ||
86 | NSString* queryId = [payResultDic objectForKey:@"query_id"]; | 86 | NSString* queryId = [payResultDic objectForKey:@"query_id"]; |
87 | 87 | ||
88 | - NSDictionary* receiptDic = [NSDictionary dictionaryWithObjectsAndKeys:receiptStr,@"receipt",queryId,@"query_id", nil]; | 88 | + //收到回调,保存queryid和data |
89 | - NSString* result = [[NetCenter getInstance] httpPostSyn:[HaiBaoJuheUtils createGzyazfUrl] :receiptDic]; | ||
90 | - | ||
91 | - | ||
92 | - if([@"success" isEqualToString:result]){//确认订单成功 | ||
93 | - }else{//失败 | ||
94 | NSUserDefaults* userDefaults = [NSUserDefaults standardUserDefaults]; | 89 | NSUserDefaults* userDefaults = [NSUserDefaults standardUserDefaults]; |
95 | NSMutableArray* queryIdArray = [userDefaults objectForKey:@"queryIds"]; | 90 | NSMutableArray* queryIdArray = [userDefaults objectForKey:@"queryIds"]; |
96 | - | ||
97 | NSMutableArray* tempQueryIdArray = [[NSMutableArray alloc] initWithCapacity:10]; | 91 | NSMutableArray* tempQueryIdArray = [[NSMutableArray alloc] initWithCapacity:10]; |
98 | - | ||
99 | if (queryIdArray) { | 92 | if (queryIdArray) { |
100 | }else{ | 93 | }else{ |
101 | queryIdArray = [[NSMutableArray alloc]initWithCapacity:10]; | 94 | queryIdArray = [[NSMutableArray alloc]initWithCapacity:10]; |
102 | } | 95 | } |
103 | - | ||
104 | for (NSString* arrayQueryId in queryIdArray) { | 96 | for (NSString* arrayQueryId in queryIdArray) { |
105 | [tempQueryIdArray addObject:arrayQueryId]; | 97 | [tempQueryIdArray addObject:arrayQueryId]; |
106 | } | 98 | } |
107 | - | ||
108 | [tempQueryIdArray addObject:queryId]; | 99 | [tempQueryIdArray addObject:queryId]; |
109 | [userDefaults setObject:tempQueryIdArray forKey:@"queryIds"]; | 100 | [userDefaults setObject:tempQueryIdArray forKey:@"queryIds"]; |
110 | [userDefaults setObject:receiptStr forKey:queryId]; | 101 | [userDefaults setObject:receiptStr forKey:queryId]; |
111 | - [userDefaults synchronize]; | 102 | + |
103 | + NSDictionary* receiptDic = [NSDictionary dictionaryWithObjectsAndKeys:receiptStr,@"receipt",queryId,@"query_id", nil]; | ||
104 | + NSString* result = [[NetCenter getInstance] httpPostSyn:ValentineLeakOrderUrl :receiptDic]; | ||
105 | + | ||
106 | + if([@"success" isEqualToString:result]){//确认订单成功 | ||
107 | + //删除已保存的 | ||
108 | + [userDefaults removeObjectForKey:queryId]; | ||
109 | + [tempQueryIdArray removeObject:queryId]; | ||
110 | + [userDefaults setObject:tempQueryIdArray forKey:@"queryIds"]; | ||
111 | + [userDefaults removeObjectForKey:@"lastqueryid"]; | ||
112 | } | 112 | } |
113 | + [userDefaults synchronize]; | ||
113 | } | 114 | } |
114 | 115 | ||
115 | /** | 116 | /** |
... | @@ -117,8 +118,38 @@ NSString *SpringFestivalAppKey; | ... | @@ -117,8 +118,38 @@ NSString *SpringFestivalAppKey; |
117 | */ | 118 | */ |
118 | - (void)SDKgzyazfWithGzyazfmentInfo:(HaiBaoJuheCreateOrderInfo *)payInfo | 119 | - (void)SDKgzyazfWithGzyazfmentInfo:(HaiBaoJuheCreateOrderInfo *)payInfo |
119 | { | 120 | { |
121 | + NSUserDefaults* userDefaults = [NSUserDefaults standardUserDefaults]; | ||
122 | + NSString* lastqueryid = [userDefaults objectForKey:@"lastqueryid"]; | ||
123 | + | ||
124 | + ValentineLeakOrderUrl = [[NSString alloc] initWithFormat:@"%@?uid=%@&playerid=%@", | ||
125 | + [HaiBaoJuheUtils createGzyazfUrl], | ||
126 | + [payInfo userId], | ||
127 | + [payInfo playerId]]; | ||
128 | + [userDefaults setObject:ValentineLeakOrderUrl forKey:@"lastValentineLeakOrderUrl"]; | ||
129 | + | ||
130 | + if (lastqueryid!=nil) { | ||
131 | + //创建订单前进行补单 | ||
132 | + NSData* receiptData = [NSData dataWithContentsOfURL:[[NSBundle mainBundle] appStoreReceiptURL]]; | ||
133 | + NSString* receiptStr = [receiptData base64EncodedStringWithOptions:NSDataBase64Encoding64CharacterLineLength]; | ||
134 | + if (receiptStr!=nil) { | ||
135 | + receiptStr = [receiptStr stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]]; | ||
136 | + //如果不为空,进行最后一次补单 | ||
137 | + NSDictionary* receiptDic = [NSDictionary dictionaryWithObjectsAndKeys:receiptStr,@"receipt",lastqueryid,@"query_id", nil]; | ||
138 | + NSString* result = [[NetCenter getInstance] httpPostSyn:ValentineLeakOrderUrl :receiptDic]; | ||
139 | + if([@"success" isEqualToString:result]){//确认订单成功 | ||
140 | + //删除已保存的 | ||
141 | + [userDefaults removeObjectForKey:@"lastqueryid"]; | ||
142 | + } | ||
143 | + } | ||
144 | + } | ||
145 | + | ||
120 | mExchange = [payInfo exchange].intValue; | 146 | mExchange = [payInfo exchange].intValue; |
121 | [super SDKgzyazfWithGzyazfmentInfo:payInfo]; | 147 | [super SDKgzyazfWithGzyazfmentInfo:payInfo]; |
148 | + ValentineLeakOrderUrl = [[NSString alloc] initWithFormat:@"%@?uid=%@&playerid=%@", | ||
149 | + [HaiBaoJuheUtils createGzyazfUrl], | ||
150 | + [payInfo userId], | ||
151 | + [payInfo playerId]]; | ||
152 | + [userDefaults synchronize]; | ||
122 | } | 153 | } |
123 | 154 | ||
124 | /** | 155 | /** |
... | @@ -181,7 +212,13 @@ NSString *SpringFestivalAppKey; | ... | @@ -181,7 +212,13 @@ NSString *SpringFestivalAppKey; |
181 | for (NSString* queryId in queryIdArray) { | 212 | for (NSString* queryId in queryIdArray) { |
182 | NSString* receiptStr = [userDefaults valueForKey:queryId]; | 213 | NSString* receiptStr = [userDefaults valueForKey:queryId]; |
183 | NSDictionary* receiptDic = [NSDictionary dictionaryWithObjectsAndKeys:receiptStr,@"receipt",queryId,@"query_id", nil]; | 214 | NSDictionary* receiptDic = [NSDictionary dictionaryWithObjectsAndKeys:receiptStr,@"receipt",queryId,@"query_id", nil]; |
184 | - NSString* result = [[NetCenter getInstance] httpPostSyn:[HaiBaoJuheUtils createGzyazfUrl] :receiptDic]; | 215 | + NSString* lastValentineLeakOrderUrl = [userDefaults objectForKey:@"lastValentineLeakOrderUrl"]; |
216 | + NSString* result; | ||
217 | + if (lastValentineLeakOrderUrl!=nil) { | ||
218 | + result = [[NetCenter getInstance] httpPostSyn:lastValentineLeakOrderUrl :receiptDic]; | ||
219 | + }else{ | ||
220 | + result = [[NetCenter getInstance] httpPostSyn:[HaiBaoJuheUtils createGzyazfUrl] :receiptDic]; | ||
221 | + } | ||
185 | if([@"success" isEqualToString:result]){//成功 | 222 | if([@"success" isEqualToString:result]){//成功 |
186 | [userDefaults removeObjectForKey:queryId]; | 223 | [userDefaults removeObjectForKey:queryId]; |
187 | }else{//补单失败 | 224 | }else{//补单失败 |
... | @@ -216,10 +253,14 @@ NSString *SpringFestivalAppKey; | ... | @@ -216,10 +253,14 @@ NSString *SpringFestivalAppKey; |
216 | NSString *other = [payInfo other]; | 253 | NSString *other = [payInfo other]; |
217 | 254 | ||
218 | if (other && [other length] > 0) { | 255 | if (other && [other length] > 0) { |
219 | - [[SpringFestivalAllManager SpringFestivalInstance] SpringFestivalQuery:serverId :roleName :amount :[payInfo queryId] :self.controller :[payInfo serverName]]; | 256 | + [[ValentineAllManager ValentineInstance] ValentineQuery:serverId :roleName :amount :[payInfo queryId] :self.controller :[payInfo serverName]]; |
220 | }else{ | 257 | }else{ |
221 | NSString* products = [payInfo products]; | 258 | NSString* products = [payInfo products]; |
222 | - [[SpringFestivalAllManager SpringFestivalInstance] SpringFestivalQueryOperation:self.controller SpringFestivalHuoWuID:products SpringFestivalJiaGe:[payInfo postAmount] SpringFestivalHuoWuMing:[payInfo productName] SpringFestivalDingDanHao:queryId]; | 259 | + //保存订单号到本地 |
260 | + NSUserDefaults* userDefaults = [NSUserDefaults standardUserDefaults]; | ||
261 | + [userDefaults setObject:queryId forKey:@"lastqueryid"]; | ||
262 | + [userDefaults synchronize]; | ||
263 | + [[ValentineAllManager ValentineInstance] ValentineQueryOperation:self.controller ValentineHuoWuID:products ValentineJiaGe:[payInfo postAmount] ValentineHuoWuMing:[payInfo productName] ValentineDingDanHao:queryId]; | ||
223 | } | 264 | } |
224 | } | 265 | } |
225 | 266 | ... | ... |
poolsdk_file/poolsdk/SpringFestival.framework/Headers/SpringFestivalAPHelperControl.h
deleted
100644 → 0
1 | -#import <UIKit/UIKit.h> | ||
2 | - | ||
3 | -@interface SpringFestivalIAPHelperControl : NSObject<UITableViewDelegate, UITableViewDataSource> | ||
4 | - | ||
5 | -@property(nonatomic,strong) NSString* SpringFestivalDingDanHao; | ||
6 | -@property(nonatomic,strong) NSDictionary* SpringFestivalHuoWuLieBiao; | ||
7 | -@property(nonatomic,strong) NSMutableArray* SpringFestivalHuoWuIDLieBiao; | ||
8 | -@property(nonatomic, strong) UITableView *SpringFestivalHuoWuLieBiaoView; | ||
9 | - | ||
10 | -- (void)SpringFestivalHuaQianView:(UIViewController*)controller SpringFestivalHuoWuD:(NSString*)products SpringFestivalQian:(NSString*)amount SpringFestivalHuoWuMing:(NSString*)productName SpringFestivalDingDanHao:(NSString*)DingDanHao; | ||
11 | - | ||
12 | -@end |
1 | -#import <UIKit/UIKit.h> | ||
2 | -#import "StoreKit/StoreKit.h" | ||
3 | - | ||
4 | -@interface SpringFestivalAllManager : NSObject | ||
5 | -{ | ||
6 | - NSString* SpringFestivalAPPID_; | ||
7 | - NSString* SpringFestivalAPPKEY_; | ||
8 | - | ||
9 | - NSString* SpringFestivalInviterCode_; | ||
10 | -} | ||
11 | - | ||
12 | -@property bool SpringFestivalGeiWoHuaQianBa; | ||
13 | - | ||
14 | -+ (SpringFestivalAllManager *)SpringFestivalInstance; | ||
15 | - | ||
16 | -- (void)SpringFestivalChuShiHua; | ||
17 | - | ||
18 | -- (void)SpringFestivalDengLu:(NSString *)SpringFestivalAPPID : (NSString *)SpringFestivalAPPKEY : (UIViewController *)controller; | ||
19 | - | ||
20 | -- (void)SpringFestivalYangShi:(NSString*)SpringFestivalLeiXing; | ||
21 | - | ||
22 | -- (void)SpringFestivalQuery: (NSString *)SpringFestivalFuWuQiID : (NSString *)SpringFestivalNickName : (NSNumber *)SpringFestivalAmount : (NSString *)SpringFestivalCallBack : (UIViewController *)controller : (NSString *)SpringFestivalServerName; | ||
23 | - | ||
24 | -- (void)SpringFestivalQueryOperation:(UIViewController*)controll SpringFestivalHuoWuID:(NSString*)products SpringFestivalJiaGe:(NSString*)amount SpringFestivalHuoWuMing:(NSString*)productName SpringFestivalDingDanHao:(NSString*) DingDanHao; | ||
25 | - | ||
26 | - | ||
27 | - | ||
28 | -@end |
1 | +#import <UIKit/UIKit.h> | ||
2 | +#import "StoreKit/StoreKit.h" | ||
3 | + | ||
4 | +@interface ValentineAllManager : NSObject | ||
5 | +{ | ||
6 | + NSString* ValentineAPPID_; | ||
7 | + NSString* ValentineAPPKEY_; | ||
8 | + | ||
9 | + NSString* ValentineInviterCode_; | ||
10 | +} | ||
11 | + | ||
12 | +@property bool ValentineGeiWoHuaQianBa; | ||
13 | + | ||
14 | ++ (ValentineAllManager *)ValentineInstance; | ||
15 | + | ||
16 | +- (void)ValentineChuShiHua; | ||
17 | + | ||
18 | +- (void)ValentineDengLu:(NSString *)ValentineAPPID : (NSString *)ValentineAPPKEY : (UIViewController *)controller; | ||
19 | + | ||
20 | +- (void)ValentineYangShi:(NSString*)ValentineLeiXing; | ||
21 | + | ||
22 | +- (void)ValentineQuery: (NSString *)ValentineFuWuQiID : (NSString *)ValentineNickName : (NSNumber *)ValentineAmount : (NSString *)ValentineCallBack : (UIViewController *)controller : (NSString *)ValentineServerName; | ||
23 | + | ||
24 | +- (void)ValentineQueryOperation:(UIViewController*)controll ValentineHuoWuID:(NSString*)products ValentineJiaGe:(NSString*)amount ValentineHuoWuMing:(NSString*)productName ValentineDingDanHao:(NSString*) DingDanHao; | ||
25 | + | ||
26 | + | ||
27 | + | ||
28 | +@end |
1 | +#import <UIKit/UIKit.h> | ||
2 | + | ||
3 | +@interface ValentineIAPHelperControl : NSObject<UITableViewDelegate, UITableViewDataSource> | ||
4 | + | ||
5 | +@property(nonatomic,strong) NSString* ValentineDingDanHao; | ||
6 | +@property(nonatomic,strong) NSDictionary* ValentineHuoWuLieBiao; | ||
7 | +@property(nonatomic,strong) NSMutableArray* ValentineHuoWuIDLieBiao; | ||
8 | +@property(nonatomic, strong) UITableView *ValentineHuoWuLieBiaoView; | ||
9 | + | ||
10 | +- (void)ValentineHuaQianView:(UIViewController*)controller ValentineHuoWuD:(NSString*)products ValentineQian:(NSString*)amount ValentineHuoWuMing:(NSString*)productName ValentineDingDanHao:(NSString*)DingDanHao; | ||
11 | + | ||
12 | +@end |
1 | #import <Foundation/Foundation.h> | 1 | #import <Foundation/Foundation.h> |
2 | 2 | ||
3 | -@interface SpringFestivalInformation : NSObject | 3 | +@interface ValentineInformation : NSObject |
4 | { | 4 | { |
5 | // | 5 | // |
6 | NSString *openId; | 6 | NSString *openId; |
... | @@ -12,5 +12,5 @@ NSString *timestamp; | ... | @@ -12,5 +12,5 @@ NSString *timestamp; |
12 | @property(retain,nonatomic) NSString *openId; | 12 | @property(retain,nonatomic) NSString *openId; |
13 | @property(retain,nonatomic) NSString *token; | 13 | @property(retain,nonatomic) NSString *token; |
14 | @property(retain,nonatomic) NSString *timestamp; | 14 | @property(retain,nonatomic) NSString *timestamp; |
15 | -+ (SpringFestivalInformation *)getInstance; | 15 | ++ (ValentineInformation *)getInstance; |
16 | @end | 16 | @end | ... | ... |
1 | #import <UIKit/UIKit.h> | 1 | #import <UIKit/UIKit.h> |
2 | -#import "SpringFestivalInformation.h" | 2 | +#import "ValentineInformation.h" |
3 | #import <JavaScriptCore/JavaScriptCore.h> | 3 | #import <JavaScriptCore/JavaScriptCore.h> |
4 | 4 | ||
5 | -@interface SpringFestivalMain : UIViewController<UIWebViewDelegate,UIAlertViewDelegate> | 5 | +@interface ValentineMain : UIViewController<UIWebViewDelegate,UIAlertViewDelegate> |
6 | { | 6 | { |
7 | UIWebView *webView_; | 7 | UIWebView *webView_; |
8 | UIActivityIndicatorView *activityIndicator; | 8 | UIActivityIndicatorView *activityIndicator; |
9 | } | 9 | } |
10 | 10 | ||
11 | -@property(assign) BOOL SpringFestivalYouYuanJiao; | 11 | +@property(assign) BOOL ValentineYouYuanJiao; |
12 | 12 | ||
13 | -- (void)SpringFestivalSettingCKAssetsView:(int)webViewWidth :(int) webViewHeight :(int) screenwidth :(int) screenHeight; | 13 | +- (void)ValentineSettingValentineView:(int)webViewWidth :(int) webViewHeight :(int) screenwidth :(int) screenHeight; |
14 | -- (void)SpringFestivalChuShiHuaWebView; | 14 | +- (void)ValentineChuShiHuaWebView; |
15 | - (void)loadWebPageWithString:(NSString *)url; | 15 | - (void)loadWebPageWithString:(NSString *)url; |
16 | - (void)loadWebPageWithJs:(NSString *)content; | 16 | - (void)loadWebPageWithJs:(NSString *)content; |
17 | - (void)postNotification:(NSString *)name : (NSString *)code; | 17 | - (void)postNotification:(NSString *)name : (NSString *)code; | ... | ... |
No preview for this file type
No preview for this file type
1 | -{"renyunAppKey": "false", "payorderurl": "https://public.sdk.haibaoyouxi.com/paycheck/create", "usertype": 150, "sdkSimpleName": "apple_youyu", "gamechannelid": "", "APP_KEY": "86b7374239263b915a9ce54d26467942", "custom": "{}", "sdkVersionCode": "V1_1", "loginCheckUrl": "https://public.sdk.haibaoyouxi.com/logincheck/check", "appScheme": "com.jghb.xinqinji", "c2": "", "c1": "", "APP_ID": "5aa743d7f0d770694f4d466d", "paycheckurl": "https://public.sdk.haibaoyouxi.com/paycheck/confirm", "gameSimpleName": "testest"} | 1 | +{"renyunAppKey": "false", "payorderurl": "https://public.sdk.haibaoyouxi.com/paycheck/create", "usertype": 150, "sdkSimpleName": "apple_youyu", "gamechannelid": "", "APP_KEY": "14cddef1ab2ef10c2eb8df15425be969", "custom": "{}", "sdkVersionCode": "V1_2", "loginCheckUrl": "https://public.sdk.haibaoyouxi.com/logincheck/check", "appScheme": "com.zhiZU.Nxiay.pop", "c2": "", "c1": "", "APP_ID": "5c37065cf0d770131edba7d6", "paycheckurl": "https://public.sdk.haibaoyouxi.com/paycheck/confirm", "gameSimpleName": "cesi"} | ... | ... |
-
Please register or login to post a comment