2.4.1代码上传,增加微信支付功能

This commit is contained in:
CYH 2023-07-31 16:12:40 +08:00
parent f30140a3d7
commit b020b9c196
14 changed files with 156 additions and 102 deletions

View File

@ -39,7 +39,7 @@ target 'TreeHole' do
# 手机一键登录 # 手机一键登录
# pod 'CL_ShanYanSDK', '= 2.3.4.8' # pod 'CL_ShanYanSDK', '= 2.3.4.8'
# 微信sdk # 微信sdk
# pod 'WechatOpenSDK', '= 1.8.7.1'
# Toast # Toast
pod 'Toast', '4.0.0' pod 'Toast', '4.0.0'
# 腾讯IMSDK # 腾讯IMSDK
@ -93,6 +93,8 @@ target 'TreeHole' do
pod 'TXLiteAVSDK_Professional' pod 'TXLiteAVSDK_Professional'
# pod 'WechatOpenSDK', '1.8.7.1'
end end
target 'HoleNotification' do target 'HoleNotification' do

View File

@ -4319,7 +4319,11 @@
"$(inherited)", "$(inherited)",
"@executable_path/Frameworks", "@executable_path/Frameworks",
); );
MARKETING_VERSION = 2.4.0; LIBRARY_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/TreeHole/Code/WechatSDK/OpenSDK2.0.2",
);
MARKETING_VERSION = 2.4.1;
PRODUCT_BUNDLE_IDENTIFIER = com.zncdts.app123; PRODUCT_BUNDLE_IDENTIFIER = com.zncdts.app123;
PRODUCT_NAME = "$(TARGET_NAME)"; PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = ""; PROVISIONING_PROFILE_SPECIFIER = "";
@ -4377,7 +4381,11 @@
"$(inherited)", "$(inherited)",
"@executable_path/Frameworks", "@executable_path/Frameworks",
); );
MARKETING_VERSION = 2.4.0; LIBRARY_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/TreeHole/Code/WechatSDK/OpenSDK2.0.2",
);
MARKETING_VERSION = 2.4.1;
PRODUCT_BUNDLE_IDENTIFIER = com.zncdts.app123; PRODUCT_BUNDLE_IDENTIFIER = com.zncdts.app123;
PRODUCT_NAME = "$(TARGET_NAME)"; PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = ""; PROVISIONING_PROFILE_SPECIFIER = "";

View File

@ -57,6 +57,12 @@
[TUILogin initWithSdkAppID:TIM_APPID]; // SDKAppID IM [TUILogin initWithSdkAppID:TIM_APPID]; // SDKAppID IM
[Bugly startWithAppId:BUGLY_APPID]; [Bugly startWithAppId:BUGLY_APPID];
[WXApi startLogByLevel:WXLogLevelNormal logBlock:^(NSString *log) {
NSLog(@"weixin - log : %@", log);
}];
//
[WXApi registerApp:@"wx6f74f7bdf0f9ea4f" universalLink:@"https://xidi.iquanpai.com/app/"];
// apple pay // apple pay
[[ApplePayService sharedInstance] autoHandleUpdatedTransactions]; [[ApplePayService sharedInstance] autoHandleUpdatedTransactions];
// //

View File

@ -69,10 +69,10 @@
[WXApi startLogByLevel:WXLogLevelDetail logBlock:^(NSString *log) { [WXApi startLogByLevel:WXLogLevelDetail logBlock:^(NSString *log) {
NSLog(@"WeChatSDK: %@", log); NSLog(@"WeChatSDK: %@", log);
}]; }];
//
// // //
[WXApi registerApp:WEIXIN_APP_ID // [WXApi registerApp:WEIXIN_APP_ID
universalLink:UNIVERSAL_LINK]; // universalLink:UNIVERSAL_LINK];
//// // //// //
// [WXApi checkUniversalLinkReady:^(WXULCheckStep step, WXCheckULStepResult* result) { // [WXApi checkUniversalLinkReady:^(WXULCheckStep step, WXCheckULStepResult* result) {
// NSLog(@"%@, %u, %@, %@", @(step), result.success, result.errorInfo, result.suggestion); // NSLog(@"%@, %u, %@, %@", @(step), result.success, result.errorInfo, result.suggestion);

View File

@ -91,7 +91,9 @@ typedef NS_ENUM(NSUInteger, AuthorizationType) {
+ (AppConfig *)appConfig; + (AppConfig *)appConfig;
+ (void)getAppConfigWithCompletion:(void(^)(AppConfig *config))completion; + (void)getAppConfigWithCompletion:(void(^)(AppConfig *config))completion;
/// 发起微信支付 /// 发起微信支付
//+ (void)payByWetChatPayWithOrderId:(NSString *)orderId payInfo:(NSDictionary *)payInfo; + (void)payByWetChatPayWithOrderId:(NSString *)orderId payInfo:(NSDictionary *)payInfo;
+ (void)payByWetChatPayWithOrderId:(NSString *)orderId payInfo:(NSDictionary *)payInfo userId:(NSString *)userId;
/// 跳转用户资料卡页面 /// 跳转用户资料卡页面
+ (void)showUserCardVCWithUserID:(int)userID; + (void)showUserCardVCWithUserID:(int)userID;

View File

@ -673,52 +673,81 @@ static AppConfig *gAppConfig;
static NSString *currentOrderId = nil; static NSString *currentOrderId = nil;
//+ (void)payByWetChatPayWithOrderId:(NSString *)orderId payInfo:(NSDictionary *)payInfo static NSString *currentUserId = nil;
//{
// currentOrderId = orderId; + (void)payByWetChatPayWithOrderId:(NSString *)orderId payInfo:(NSDictionary *)payInfo
// PayReq *request = [[PayReq alloc] init]; {
// request.partnerId = payInfo[@"partnerId"]; currentOrderId = orderId;
// request.prepayId= payInfo[@"prepayId"]; currentUserId = @"";
// request.package = payInfo[@"package"]; PayReq *request = [[PayReq alloc] init];
// request.nonceStr= payInfo[@"nonceStr"]; request.partnerId = payInfo[@"partnerId"];
// request.timeStamp= [payInfo[@"timeStamp"] intValue]; request.prepayId= payInfo[@"prepayId"];
// request.sign = payInfo[@"sign"]; request.package = payInfo[@"package"];
// [WXApi sendReq:request completion:^(BOOL success) { request.nonceStr= payInfo[@"nonceStr"];
// if (!success) { request.timeStamp= [payInfo[@"timeStamp"] intValue];
// [SVProgressHUD showErrorWithStatus:@"唤起微信支付失败"]; request.sign = payInfo[@"sign"];
// } [WXApi sendReq:request completion:^(BOOL success) {
// }]; if (!success) {
//} [SVProgressHUD showErrorWithStatus:@"唤起微信支付失败"];
}
}];
}
+ (void)payByWetChatPayWithOrderId:(NSString *)orderId payInfo:(NSDictionary *)payInfo userId:(NSString *)userId {
currentUserId = userId;
currentOrderId = orderId;
PayReq *request = [[PayReq alloc] init];
request.partnerId = payInfo[@"partnerId"];
request.prepayId= payInfo[@"prepayId"];
request.package = payInfo[@"package"];
request.nonceStr= payInfo[@"nonceStr"];
request.timeStamp= [payInfo[@"timeStamp"] intValue];
request.sign = payInfo[@"sign"];
[WXApi sendReq:request completion:^(BOOL success) {
if (!success) {
[SVProgressHUD showErrorWithStatus:@"唤起微信支付失败"];
}
}];
}
- (void)onAppDidBecomeActive { - (void)onAppDidBecomeActive {
// [self checkWXOrderIFNeed]; // [self checkWXOrderIFNeed];
} }
//- (void)checkWXOrderIFNeed { - (void)checkWXOrderIFNeed {
// if (!currentOrderId) { if (!currentOrderId) {
// return; return;
// } }
// [PYHTTPManager postWithPath:@"wxcheckorder" params:@{ [PYHTTPManager postWithPath:@"wxcheckorder" params:@{
// @"order_no": currentOrderId ?: @"" @"order_uuid": currentOrderId ?: @""
// } callback:^(id _Nullable rsp, NSError * _Nullable error) { } callback:^(id _Nullable rsp, NSError * _Nullable error) {
// if (!error) { if (!error) {
// [SVProgressHUD dismiss]; [SVProgressHUD dismiss];
// if ([rsp[@"is_pay_succeed"] boolValue]) { if ([rsp[@"is_pay_succeed"] boolValue]) {
// currentOrderId = nil; if (currentUserId.length > 0) {
// [[NSNotificationCenter defaultCenter] postNotificationName:BuyVIPSuccessNotification object:nil];
// [MTAlertView showWithSetupBlcok:^(MTAlertViewConfig *config) { [[NSNotificationCenter defaultCenter] postNotificationName:@"receivedVipMsgnotifi" object:currentUserId];
// config.title = @"VIP购买成功"; currentOrderId = nil;
// config.message = @"你现在是我们小酒馆最尊贵的客人"; currentUserId = nil;
// config.otherTitle = @"确定"; } else {
// }];
// } else { [[NSNotificationCenter defaultCenter] postNotificationName:BuyVIPSuccessNotification object:nil];
//// [SVProgressHUD showErrorWithStatus:@"支付失败"]; [MTAlertView showWithSetupBlcok:^(MTAlertViewConfig *config) {
// } config.title = @"VIP购买成功";
// } else { config.message = @"你现在是我们小酒馆最尊贵的客人";
//// [SVProgressHUD showErrorWithStatus:@"支付失败"]; config.otherTitle = @"确定";
// } }];
// }]; }
//}
} else {
// [SVProgressHUD showErrorWithStatus:@"支付失败"];
}
} else {
[SVProgressHUD showErrorWithStatus:@"支付失败"];
}
}];
}
+ (void)showBadgeOnTabBarItemAtIndex:(int)index number:(int)number { + (void)showBadgeOnTabBarItemAtIndex:(int)index number:(int)number {
@ -786,9 +815,9 @@ static NSString *currentOrderId = nil;
/// ///
- (void)onResp:(BaseResp *)resp - (void)onResp:(BaseResp *)resp
{ {
// if ([resp isKindOfClass:[PayResp class]]) { // if ([resp isKindOfClass:[PayResp class]]) { //
// [self checkWXOrderIFNeed]; [self checkWXOrderIFNeed];
// } }
} }
@end @end

View File

@ -195,7 +195,7 @@
-(void)setDataModel:(userNearbyModel *)dataModel{ -(void)setDataModel:(userNearbyModel *)dataModel{
_dataModel = dataModel; _dataModel = dataModel;
[_userImgV sd_setImageWithURL:[NSURL URLWithString:_dataModel.avatar] placeholderImage:[UIImage imageNamed:@"TH_defalut_avatar"]]; [_userImgV sd_setImageWithURL:[NSURL URLWithString:_dataModel.avatar] placeholderImage:[UIImage imageNamed:@"TH_defalut_avatar"]];
if ([_dataModel.user_vip_kind isEqualToString:@"1"]) { if ([_dataModel.user_vip_kind isEqualToString:@"1"] || [_dataModel.user_vip_kind isEqualToString:@"10"] ) {
_userNameLab.textColor = COLOR_WITH_RGB(0xF8D07D); _userNameLab.textColor = COLOR_WITH_RGB(0xF8D07D);
_userVipImgV.hidden = NO; _userVipImgV.hidden = NO;
}else{ }else{

View File

@ -173,7 +173,7 @@
return; return;
*/ */
if ([UserService currentUser].isVIP) { // if ([UserService currentUser].isVIP) {
[PYAppService sendVipVC:@"vip_page" forUserID:self.convData.userID]; [PYAppService sendVipVC:@"vip_page" forUserID:self.convData.userID];
@ -181,9 +181,9 @@
// [[NSNotificationCenter defaultCenter] removeObserver:self name:@"sendVipMsgnotifi" object:nil]; // [[NSNotificationCenter defaultCenter] removeObserver:self name:@"sendVipMsgnotifi" object:nil];
// [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(sengVipMsg:) name:@"sendVipMsgnotifi" object:nil]; // [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(sengVipMsg:) name:@"sendVipMsgnotifi" object:nil];
}else { // }else {
[ToastUtil showToast:@"需要成为会员才可以赠送VIP哦~"]; // [ToastUtil showToast:@"需要成为会员才可以赠送VIP哦~"];
} // }
} }

View File

@ -71,7 +71,7 @@
}]; }];
}]; }];
[logoutItem addSubview:logoutLabel]; [logoutItem addSubview:logoutLabel];
logoutItem.bottom = SCREEN_HEIGHT - NAVIGATION_BAR_HEIGHT; logoutItem.bottom = SCREEN_HEIGHT - NAVIGATION_BAR_HEIGHT + 20;
[self.view addSubview:logoutItem]; [self.view addSubview:logoutItem];
self.tableView.contentSize = CGSizeMake(0, logoutItem.bottom); self.tableView.contentSize = CGSizeMake(0, logoutItem.bottom);

View File

@ -92,31 +92,33 @@ static NSString * const kDidReportPayActionCacheKey = @"kDidReportPayActionCache
if (exExtraDay != nil) { if (exExtraDay != nil) {
extraTotalDay = @(exExtraDay.intValue + storeExtraDay.intValue); extraTotalDay = @(exExtraDay.intValue + storeExtraDay.intValue);
} }
// [PYHTTPManager postWithPath:@"wxgoodprepay" params:@{ [PYHTTPManager postWithPath:@"wxgoodprepay" params:@{
// @"vip_good_id": ID @"vip_good_id": @([ID intValue]),@"vip_source":@"",@"extra_vip_day":extraTotalDay
// } callback:^(id _Nullable rsp, NSError * _Nullable error) {
// if (error) {
// [SVProgressHUD showErrorWithStatus:@"创建订单失败"]; } callback:^(id _Nullable rsp, NSError * _Nullable error) {
// return; if (error) {
// } [SVProgressHUD showErrorWithStatus:@"创建订单失败"];
// [PYAppService payByWetChatPayWithOrderId:rsp[@"trade_no"] payInfo:rsp]; return;
// }]; }
NSString *goodsID = ID; [PYAppService payByWetChatPayWithOrderId:rsp[@"trade_no"] payInfo:rsp];
NSMutableDictionary *paramsM = [@{ }];
@"apple_good_id": goodsID, // NSString *goodsID = ID;
@"extra_vip_day": extraTotalDay // NSMutableDictionary *paramsM = [@{
} mutableCopy]; // @"apple_good_id": goodsID,
// @"extra_vip_day": extraTotalDay
[paramsM addEntriesFromDictionary:extInfo]; // } mutableCopy];
//
[PYHTTPManager postWithPath:@"iaporder" params:paramsM callback:^(id _Nullable rsp, NSError * _Nullable error) { // [paramsM addEntriesFromDictionary:extInfo];
if (error) { //
[SVProgressHUD showSuccessWithStatus:error.userInfo[@"message"]]; // [PYHTTPManager postWithPath:@"iaporder" params:paramsM callback:^(id _Nullable rsp, NSError * _Nullable error) {
return; // if (error) {
} // [SVProgressHUD showSuccessWithStatus:error.userInfo[@"message"]];
[ApplePayService payProductWithId:goodsID orderId:rsp[@"trade_uuid"] restoreProduct:NO isFastBuy:isFastBuy]; // return;
}]; // }
// [ApplePayService payProductWithId:goodsID orderId:rsp[@"trade_uuid"] restoreProduct:NO isFastBuy:isFastBuy];
// }];
} }
+ (void)SendStartPay:(NSString *)ID UserID:(NSString *)userID isFastBuy:(BOOL)isFastBuy extInfo:(NSDictionary *)extInfo + (void)SendStartPay:(NSString *)ID UserID:(NSString *)userID isFastBuy:(BOOL)isFastBuy extInfo:(NSDictionary *)extInfo
@ -146,7 +148,7 @@ static NSString * const kDidReportPayActionCacheKey = @"kDidReportPayActionCache
NSDictionary *infoDictionary = [[NSBundle mainBundle] infoDictionary];//app NSDictionary *infoDictionary = [[NSBundle mainBundle] infoDictionary];//app
NSMutableDictionary *paramsM = [@{ NSMutableDictionary *paramsM = [@{
@"ios_good_id": goodsID, @"vip_good_id": @([goodsID intValue]),
@"give_user_id": @(VuserID), @"give_user_id": @(VuserID),
@"extra_vip_day": extraTotalDay, @"extra_vip_day": extraTotalDay,
// @"device_platform" :@"iOS", // @"device_platform" :@"iOS",
@ -156,15 +158,15 @@ static NSString * const kDidReportPayActionCacheKey = @"kDidReportPayActionCache
[paramsM addEntriesFromDictionary:extInfo]; [paramsM addEntriesFromDictionary:extInfo];
[PYHTTPManager postWithPath:@"ios/givevip" params:paramsM callback:^(id _Nullable rsp1, NSError * _Nullable error) { [PYHTTPManager postWithPath:@"android/givevip" params:paramsM callback:^(id _Nullable rsp1, NSError * _Nullable error) {
NSLog(@"rsp===%@,goodsID===%@",rsp1,paramsM); NSLog(@"rsp===%@,goodsID===%@",rsp1,paramsM);
NSString *vipType ; NSString *vipType ;
if ([goodsID containsString:@"68"]) { if ([goodsID containsString:@"1"]) {
vipType = @"赠送你一个月会员"; vipType = @"赠送你一个月会员";
}else if ([goodsID containsString:@"128"]) }else if ([goodsID containsString:@"13"])
{ {
vipType = @"赠送你三个月会员"; vipType = @"赠送你三个月会员";
}else{ }else{
@ -173,7 +175,7 @@ static NSString * const kDidReportPayActionCacheKey = @"kDidReportPayActionCache
if (error) { if (!error) {
// [SVProgressHUD showSuccessWithStatus:error.userInfo[@"message"]]; // [SVProgressHUD showSuccessWithStatus:error.userInfo[@"message"]];
[SVProgressHUD showSuccessWithStatus:error.userInfo[@"message"]]; [SVProgressHUD showSuccessWithStatus:error.userInfo[@"message"]];
NSLog(@"message===%@",error.userInfo[@"message"]); NSLog(@"message===%@",error.userInfo[@"message"]);
@ -181,11 +183,11 @@ static NSString * const kDidReportPayActionCacheKey = @"kDidReportPayActionCache
int code = [error.userInfo[@"code"] intValue]; int code = [error.userInfo[@"code"] intValue];
if (code==0) { if (code==0) {
[PYAppService payByWetChatPayWithOrderId:rsp1[@"trade_no"] payInfo:rsp1 userId:vipType];
[ApplePayService payProductWithId:goodsID orderId:rsp1[@"trade_uuid"] restoreProduct:NO isFastBuy:isFastBuy]; // [ApplePayService payProductWithId:goodsID orderId:rsp1[@"trade_uuid"] restoreProduct:NO isFastBuy:isFastBuy];
//
[[NSNotificationCenter defaultCenter] postNotificationName:@"receivedVipMsgnotifi" object:vipType];
}else if (code==1100) }else if (code==1100)

View File

@ -174,12 +174,12 @@
[[NSNotificationCenter defaultCenter] removeObserver:self name:@"receivedVipMsgnotifi" object:nil]; [[NSNotificationCenter defaultCenter] removeObserver:self name:@"receivedVipMsgnotifi" object:nil];
self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc] initWithImage:ImageNamed(@"TH_down_btn") style:UIBarButtonItemStyleDone target:self action:@selector(close)]; self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc] initWithImage:ImageNamed(@"TH_down_btn") style:UIBarButtonItemStyleDone target:self action:@selector(close)];
self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"恢复购买" style:UIBarButtonItemStylePlain target:self action:@selector(restore)]; // self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"恢复购买" style:UIBarButtonItemStylePlain target:self action:@selector(restore)];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(refresh) name:BuyVIPSuccessNotification object:nil]; [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(refresh) name:BuyVIPSuccessNotification object:nil];
} }
- (void)refresh { - (void)refresh {
[PYHTTPManager getWithPath:@"vipconfig" params:nil callback:^(id _Nullable rsp, NSError * _Nullable error) { [PYHTTPManager getWithPath:self.userID.length > 0 ? @"vipconfig" : @"vipconfig/experience" params:nil callback:^(id _Nullable rsp, NSError * _Nullable error) {
NSLog(@"会员页面 : %@",rsp); NSLog(@"会员页面 : %@",rsp);
[self endLoading:error]; [self endLoading:error];
if (!error) { if (!error) {
@ -286,18 +286,19 @@
NSString *userID = [self.userID stringByTrimmingCharactersInSet:[NSCharacterSet characterSetWithCharactersInString:@"hole_"]]; NSString *userID = [self.userID stringByTrimmingCharactersInSet:[NSCharacterSet characterSetWithCharactersInString:@"hole_"]];
NSLog(@"userID%@",userID); NSLog(@"userID%@",userID);
[ApplePayService sendStartVipPay:goodsID isFastBuy:NO source:self.vipSource UserID:userID]; [ApplePayService sendStartVipPay:[NSString stringWithFormat:@"%@",@(weakself.selectedGoodsInfo.good.vip_good_id)] isFastBuy:NO source:self.vipSource UserID:userID];
} }
} else {
[ApplePayService startVipPay:[NSString stringWithFormat:@"%@",@(weakself.selectedGoodsInfo.good.vip_good_id)] isFastBuy:NO source:self.vipSource];
} }
[ApplePayService startVipPay:goodsID isFastBuy:NO source:self.vipSource];
}]; }];
[bottomView addSubview:buyButton]; [bottomView addSubview:buyButton];
RichTextLabel *richLabel = [RichTextLabel richTextFullString:[NSString stringWithFormat:@"查阅服务协议·隐私协议·会员服务协议购买后你可以随时在iTunes商店设置页取消订阅点击右上角也可恢复之前的购买"] items:@[ RichTextLabel *richLabel = [RichTextLabel richTextFullString:[NSString stringWithFormat:@"查阅服务协议·隐私协议·会员服务协议"] items:@[
[RichLabelItem itemWithText:@"服务协议" action:^{ [RichLabelItem itemWithText:@"服务协议" action:^{
[PYAppService openWebVCWithTitle:@"服务协议" url:@"http://iquanpai.com/app-h5/4_131.html"]; [PYAppService openWebVCWithTitle:@"服务协议" url:@"http://iquanpai.com/app-h5/4_131.html"];
}], }],

View File

@ -257,13 +257,16 @@
CGSize itemSize = config.itemSize; CGSize itemSize = config.itemSize;
if (CGSizeEqualToSize(itemSize, CGSizeZero)) { if (CGSizeEqualToSize(itemSize, CGSizeZero)) {
itemSize.width = (config.contentWidth - config.contentInset.left - config.contentInset.right - config.columnSpacing * (config.maxColumn - 1)) / config.maxColumn; itemSize.width = (config.contentWidth - config.contentInset.left - config.contentInset.right - config.columnSpacing * (self.itemModels.count- 1)) / self.itemModels.count;
itemSize.height = config.itemHeight > 0 ? config.itemHeight : itemSize.width * config.itemRatio; itemSize.height = config.itemHeight > 0 ? config.itemHeight : itemSize.width * (self.itemModels.count == 4 ? 0.25 : config.itemRatio);
} }
flowLayout.itemSize = itemSize; itemSize.width = (config.contentWidth - config.contentInset.left - config.contentInset.right - config.columnSpacing * (self.itemModels.count- 1)) / self.itemModels.count;
CGFloat contentHeight = config.contentInset.top + config.contentInset.bottom + (itemSize.height + config.rowSpacing) * (self.itemModels.count / config.maxColumn + 1) - config.rowSpacing; CGFloat contentHeight = config.contentInset.top + config.contentInset.bottom + (itemSize.height + config.rowSpacing)- config.rowSpacing;
CGFloat contentWidth = config.contentInset.left + config.contentInset.right + (itemSize.width + config.columnSpacing) * config.maxColumn - config.columnSpacing; CGFloat contentWidth = config.contentInset.left + config.contentInset.right + (itemSize.width + config.columnSpacing) * self.itemModels.count - config.columnSpacing;
flowLayout.itemSize = CGSizeMake(itemSize.width, contentHeight);
self.collectionView = [[UICollectionView alloc] initWithFrame:CGRectMake(0, 0, config.contentWidth, contentHeight) collectionViewLayout:flowLayout]; self.collectionView = [[UICollectionView alloc] initWithFrame:CGRectMake(0, 0, config.contentWidth, contentHeight) collectionViewLayout:flowLayout];
[self layoutSubviews]; [self layoutSubviews];

View File

@ -11,7 +11,7 @@
<string>Editor</string> <string>Editor</string>
<key>CFBundleURLSchemes</key> <key>CFBundleURLSchemes</key>
<array> <array>
<string>wx1f7c5b876fffd4e1</string> <string>wx6f74f7bdf0f9ea4f</string>
</array> </array>
</dict> </dict>
<dict> <dict>

View File

@ -7,6 +7,7 @@
<key>com.apple.developer.associated-domains</key> <key>com.apple.developer.associated-domains</key>
<array> <array>
<string>applinks:h5.diandi.club</string> <string>applinks:h5.diandi.club</string>
<string>applinks:https://xidi.iquanpai.com/app/</string>
</array> </array>
</dict> </dict>
</plist> </plist>