This commit is contained in:
启星
2025-12-26 19:04:08 +08:00
parent 7b7d18e665
commit 890c5f59ed
29 changed files with 359 additions and 151 deletions

View File

@@ -25,6 +25,7 @@
95C3EFF52E49F44A004B2D82 /* libiconv.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = 95F204FC2DEF0AAC0031E710 /* libiconv.tbd */; }; 95C3EFF52E49F44A004B2D82 /* libiconv.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = 95F204FC2DEF0AAC0031E710 /* libiconv.tbd */; };
95C3EFF62E49F44A004B2D82 /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 95F204FA2DEF0AA10031E710 /* Security.framework */; }; 95C3EFF62E49F44A004B2D82 /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 95F204FA2DEF0AA10031E710 /* Security.framework */; };
95EEB7902EFBCE35000BB488 /* StoreKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 95EEB78F2EFBCE35000BB488 /* StoreKit.framework */; }; 95EEB7902EFBCE35000BB488 /* StoreKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 95EEB78F2EFBCE35000BB488 /* StoreKit.framework */; };
95EEB7912EFBD9C2000BB488 /* StoreKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 95EEB78F2EFBCE35000BB488 /* StoreKit.framework */; };
95F204FB2DEF0AA10031E710 /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 95F204FA2DEF0AA10031E710 /* Security.framework */; }; 95F204FB2DEF0AA10031E710 /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 95F204FA2DEF0AA10031E710 /* Security.framework */; };
95F204FD2DEF0AAC0031E710 /* libiconv.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = 95F204FC2DEF0AAC0031E710 /* libiconv.tbd */; }; 95F204FD2DEF0AAC0031E710 /* libiconv.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = 95F204FC2DEF0AAC0031E710 /* libiconv.tbd */; };
95F204FF2DEF0AB20031E710 /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 95F204FE2DEF0AB20031E710 /* SystemConfiguration.framework */; }; 95F204FF2DEF0AB20031E710 /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 95F204FE2DEF0AB20031E710 /* SystemConfiguration.framework */; };
@@ -246,6 +247,7 @@
buildActionMask = 2147483647; buildActionMask = 2147483647;
files = ( files = (
95C3EFEF2E49F44A004B2D82 /* ReplayKit.framework in Frameworks */, 95C3EFEF2E49F44A004B2D82 /* ReplayKit.framework in Frameworks */,
95EEB7912EFBD9C2000BB488 /* StoreKit.framework in Frameworks */,
95C3EFF02E49F44A004B2D82 /* libz.tbd in Frameworks */, 95C3EFF02E49F44A004B2D82 /* libz.tbd in Frameworks */,
95C3EFF12E49F44A004B2D82 /* CoreTelephony.framework in Frameworks */, 95C3EFF12E49F44A004B2D82 /* CoreTelephony.framework in Frameworks */,
95C3EFF22E49F44A004B2D82 /* libsqlite3.tbd in Frameworks */, 95C3EFF22E49F44A004B2D82 /* libsqlite3.tbd in Frameworks */,
@@ -791,7 +793,7 @@
"$(inherited)", "$(inherited)",
"$(SDKROOT)/usr/lib/swift", "$(SDKROOT)/usr/lib/swift",
); );
MARKETING_VERSION = 1.1.13; MARKETING_VERSION = 1.1.14;
PRODUCT_BUNDLE_IDENTIFIER = com.qxcm.qxlive; PRODUCT_BUNDLE_IDENTIFIER = com.qxcm.qxlive;
PRODUCT_NAME = "$(TARGET_NAME)"; PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = ""; PROVISIONING_PROFILE_SPECIFIER = "";
@@ -857,7 +859,7 @@
"$(inherited)", "$(inherited)",
"$(SDKROOT)/usr/lib/swift", "$(SDKROOT)/usr/lib/swift",
); );
MARKETING_VERSION = 1.1.13; MARKETING_VERSION = 1.1.14;
PRODUCT_BUNDLE_IDENTIFIER = com.qxcm.qxlive; PRODUCT_BUNDLE_IDENTIFIER = com.qxcm.qxlive;
PRODUCT_NAME = "$(TARGET_NAME)"; PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = ""; PROVISIONING_PROFILE_SPECIFIER = "";

View File

@@ -21,13 +21,22 @@
self.bgImaegView.image = [UIImage imageNamed:@"app_start_yusheng"];; self.bgImaegView.image = [UIImage imageNamed:@"app_start_yusheng"];;
self.bgImaegView.contentMode = UIViewContentModeScaleAspectFill; self.bgImaegView.contentMode = UIViewContentModeScaleAspectFill;
[self.view addSubview:self.bgImaegView]; [self.view addSubview:self.bgImaegView];
// [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(loginSuccess) name:noticeUserLogin object:nil]; [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(appStartNetWork) name:noticeUserLogin object:nil];
if ([QXRequset shareInstance].AFNetWorkStatus == AFNetworkReachabilityStatusReachableViaWWAN || [QXRequset shareInstance].AFNetWorkStatus == AFNetworkReachabilityStatusReachableViaWiFi) {
[self getAppTheme]; [self getAppTheme];
} }
}
-(void)viewDidDisappear:(BOOL)animated{ -(void)viewDidDisappear:(BOOL)animated{
[super viewDidDisappear:animated]; [super viewDidDisappear:animated];
// [[NSNotificationCenter defaultCenter] removeObserver:self]; // [[NSNotificationCenter defaultCenter] removeObserver:self];
} }
-(void)appStartNetWork{
[self getAppTheme];
}
-(void)getAppTheme{ -(void)getAppTheme{
NSString *themeUrl = [NSString stringWithFormat:@"%@%@",ServerUrl,QXAppTheme]; NSString *themeUrl = [NSString stringWithFormat:@"%@%@",ServerUrl,QXAppTheme];
[[QXRequset shareInstance] getWithUrl:themeUrl parameters:@{} needCache:NO success:^(id responseObject) { [[QXRequset shareInstance] getWithUrl:themeUrl parameters:@{} needCache:NO success:^(id responseObject) {

View File

@@ -19,6 +19,7 @@ typedef void (^showFinishBlock)(void);
@interface QXGlobal : NSObject @interface QXGlobal : NSObject
+(instancetype)shareGlobal; +(instancetype)shareGlobal;
@property (nonatomic,assign)BOOL isNeedUpdate;
// 是否登录 // 是否登录
@property (nonatomic,readonly,assign)BOOL isLogin; @property (nonatomic,readonly,assign)BOOL isLogin;
@property (nonatomic,assign)BOOL isShowLoginVC; @property (nonatomic,assign)BOOL isShowLoginVC;

View File

@@ -156,8 +156,9 @@
[self.alertViewController hideViewFinishBlock:closeBlock]; [self.alertViewController hideViewFinishBlock:closeBlock];
} }
-(BOOL)isOpenRecharge{ -(BOOL)isOpenRecharge{
BOOL isOpenRecharge = [[NSUserDefaults standardUserDefaults] boolForKey:kIsOpenRecharge]; // BOOL isOpenRecharge = [[NSUserDefaults standardUserDefaults] boolForKey:kIsOpenRecharge];
return isOpenRecharge; // return isOpenRecharge;
return YES;
} }
-(void)finishTask{ -(void)finishTask{

View File

@@ -123,7 +123,7 @@
[weakSelf.navigationController popViewControllerAnimated:YES]; [weakSelf.navigationController popViewControllerAnimated:YES];
} }
failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) { failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
showToast(msg);
}]; }];
} }

View File

@@ -715,6 +715,8 @@
-(void)listWillAppear{ -(void)listWillAppear{
if ([self.giftLabelId isEqualToString:@"-10"]) { if ([self.giftLabelId isEqualToString:@"-10"]) {
[self getBagList]; [self getBagList];
}else{
[self reloadData];
} }
self.selectedIndex = -1; self.selectedIndex = -1;
[self.collectionView reloadData]; [self.collectionView reloadData];

View File

@@ -241,7 +241,7 @@
if (imgs.count==0) { if (imgs.count==0) {
return; return;
} }
if (isAppStore) { if (QXGlobal.shareGlobal.isAppStore) {
self.rechargePermissionView.hidden = YES; self.rechargePermissionView.hidden = YES;
}else{ }else{
self.rechargePermissionView.hidden = NO; self.rechargePermissionView.hidden = NO;
@@ -329,6 +329,11 @@
} }
-(void)popFirstRechargeViewOnlyRecharge:(BOOL)onlyRecharge{ -(void)popFirstRechargeViewOnlyRecharge:(BOOL)onlyRecharge{
if ([QXGlobal shareGlobal].isAppStore) { if ([QXGlobal shareGlobal].isAppStore) {
if (self.signStatus.intValue == 1) {
[self popRecommendRoom];
}else{
[self popSignTask];
}
return; return;
} }
MJWeakSelf MJWeakSelf

View File

@@ -33,10 +33,10 @@
} }
-(void)startAnimating{ -(void)startAnimating{
[self.animateImageView startAnimating]; // [self.animateImageView startAnimating];
} }
-(void)endAnimating{ -(void)endAnimating{
[self.animateImageView stopAnimating]; // [self.animateImageView stopAnimating];
} }
-(void)setHistoryModel:(QXMyRoomHistory *)historyModel{ -(void)setHistoryModel:(QXMyRoomHistory *)historyModel{
_historyModel = historyModel; _historyModel = historyModel;

View File

@@ -36,7 +36,7 @@
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="qsd-Ig-Nmi"> <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="qsd-Ig-Nmi">
<rect key="frame" x="8" y="8" width="28" height="14"/> <rect key="frame" x="8" y="8" width="28" height="14"/>
<subviews> <subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="T17-NM-Dxi"> <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="Flow 10001.png" translatesAutoresizingMaskIntoConstraints="NO" id="T17-NM-Dxi">
<rect key="frame" x="7.6666666666666661" y="2" width="12.999999999999998" height="10"/> <rect key="frame" x="7.6666666666666661" y="2" width="12.999999999999998" height="10"/>
<constraints> <constraints>
<constraint firstAttribute="height" constant="10" id="Jz4-mP-9ub"/> <constraint firstAttribute="height" constant="10" id="Jz4-mP-9ub"/>
@@ -175,6 +175,7 @@
</collectionViewCell> </collectionViewCell>
</objects> </objects>
<resources> <resources>
<image name="Flow 10001.png" width="150" height="115"/>
<image name="room_hot_icon" width="14" height="14"/> <image name="room_hot_icon" width="14" height="14"/>
</resources> </resources>
</document> </document>

View File

@@ -25,7 +25,7 @@ typedef void(^RestoreFailurreCompletionHandler)(void);//恢复失败的回调
+ (instancetype)sharedInstance; + (instancetype)sharedInstance;
-(void)butGoodsWithId:(NSString*)productId; -(void)buyGoodsWithId:(NSString*)productId orderNo:(NSString*)orderNo;
- (void)getReceiptState:(void (^)(BOOL success))completion; - (void)getReceiptState:(void (^)(BOOL success))completion;
//恢复内购 //恢复内购
- (void)resumeInAppPurchase; - (void)resumeInAppPurchase;

View File

@@ -14,7 +14,7 @@
@interface QXIAPManager()<SKPaymentTransactionObserver,SKProductsRequestDelegate,SKRequestDelegate> @interface QXIAPManager()<SKPaymentTransactionObserver,SKProductsRequestDelegate,SKRequestDelegate>
@property (nonatomic,strong)NSString*orderNo;
@end @end
@implementation QXIAPManager @implementation QXIAPManager
@@ -31,12 +31,13 @@
/* /*
*/ */
-(void)butGoodsWithId:(NSString*)productId{ -(void)buyGoodsWithId:(NSString*)productId orderNo:(NSString*)orderNo{
self.orderNo = orderNo;
//productId //productId
[[SKPaymentQueue defaultQueue] addTransactionObserver:self]; [[SKPaymentQueue defaultQueue] addTransactionObserver:self];
if ([SKPaymentQueue canMakePayments]) { //app if ([SKPaymentQueue canMakePayments]) { //app
if (productId.length) { if (productId.length) {
showLoadingInView(KEYWINDOW);
NSLog(@"%@商品正在请求中...",productId); NSLog(@"%@商品正在请求中...",productId);
NSArray *product = [[NSArray alloc] initWithObjects:productId, nil]; NSArray *product = [[NSArray alloc] initWithObjects:productId, nil];
NSSet *set = [NSSet setWithArray:product]; NSSet *set = [NSSet setWithArray:product];
@@ -59,9 +60,15 @@
#pragma mark SKProductsRequestDelegate #pragma mark SKProductsRequestDelegate
- (void)productsRequest:(nonnull SKProductsRequest *)request didReceiveResponse:(nonnull SKProductsResponse *)response { - (void)productsRequest:(nonnull SKProductsRequest *)request didReceiveResponse:(nonnull SKProductsResponse *)response {
NSArray *product = response.products; NSArray *product = response.products;
if (response.invalidProductIdentifiers.count) { if (response.invalidProductIdentifiers.count) {
dispatch_async(dispatch_get_main_queue(), ^{
hideLoadingInView(KEYWINDOW);
});
NSLog(@"商品请求错误,error:%@", response.invalidProductIdentifiers); NSLog(@"商品请求错误,error:%@", response.invalidProductIdentifiers);
showToast(@"商品请求错误");
if (self.subscriptionFailurreCompletionHandler) { if (self.subscriptionFailurreCompletionHandler) {
self.subscriptionFailurreCompletionHandler(); self.subscriptionFailurreCompletionHandler();
} }
@@ -73,6 +80,9 @@
} }
- (void)paymentQueue:(nonnull SKPaymentQueue *)queue updatedTransactions:(nonnull NSArray<SKPaymentTransaction *> *)transactions { - (void)paymentQueue:(nonnull SKPaymentQueue *)queue updatedTransactions:(nonnull NSArray<SKPaymentTransaction *> *)transactions {
dispatch_async(dispatch_get_main_queue(), ^{
hideLoadingInView(KEYWINDOW);
});
// NSInteger i = 0; // NSInteger i = 0;
for (SKPaymentTransaction *tran in transactions) { for (SKPaymentTransaction *tran in transactions) {
// if(i != transactions.count - 1){ // if(i != transactions.count - 1){
@@ -100,10 +110,15 @@
} }
[self vertifyReceipt:^(BOOL success) { [self vertifyReceipt:^(BOOL success) {
if(success){ if(success){
if (self.subscriptionSuccessCompletionHandler) {
self.subscriptionSuccessCompletionHandler(); self.subscriptionSuccessCompletionHandler();
}
[[NSNotificationCenter defaultCenter] postNotificationName:noticeAlipayResult object:nil];
}else{ }else{
if (self.subscriptionFailurreCompletionHandler) {
self.subscriptionFailurreCompletionHandler(); self.subscriptionFailurreCompletionHandler();
} }
}
}]; // }]; //
NSLog(@"交易完成,正在校验凭证...."); NSLog(@"交易完成,正在校验凭证....");
} }
@@ -111,8 +126,10 @@
case SKPaymentTransactionStateFailed:// case SKPaymentTransactionStateFailed://
[[SKPaymentQueue defaultQueue] finishTransaction:tran]; [[SKPaymentQueue defaultQueue] finishTransaction:tran];
if (self.subscriptionFailurreCompletionHandler) {
self.subscriptionFailurreCompletionHandler(); self.subscriptionFailurreCompletionHandler();
}
break; break;
@@ -203,39 +220,52 @@
*/ */
- (void)vertifyReceipt:(void (^)(BOOL success))completion { - (void)vertifyReceipt:(void (^)(BOOL success))completion {
NSLog(@"~~~正在检验。。。"); NSLog(@"~~~正在检验。。。");
NSString *receipt = [self getReceipt]; NSString *payment_token = [self getReceipt];
NSString *password = @"秘钥"; // NSString *password = @"秘钥";
NSString *urlString = [NSString stringWithFormat:@"https://校验地址"]; // NSString *urlString = [NSString stringWithFormat:@"https://sandbox.itunes.apple.com/verifyReceipt"];
AFHTTPSessionManager *manager = [AFHTTPSessionManager manager]; // AFHTTPSessionManager *manager = [AFHTTPSessionManager manager];
manager.responseSerializer = [AFHTTPResponseSerializer serializer]; // manager.responseSerializer = [AFHTTPResponseSerializer serializer];
//
NSDictionary *parameters = @{ // NSDictionary *parameters = @{
@"apple_receipt": receipt, // @"apple_receipt": receipt,
@"password": password // @"password": @"a24591f9614b4814b1a77f8ffda41afc"
}; // };
//
[manager POST:urlString parameters:parameters headers:nil progress:nil success:^(NSURLSessionDataTask * _Nonnull task, id _Nullable responseObject) { // [manager POST:urlString parameters:parameters headers:nil progress:nil success:^(NSURLSessionDataTask * _Nonnull task, id _Nullable responseObject) {
// // //
NSLog(@"弹窗提示用户请求成功"); // NSLog(@"弹窗提示用户请求成功");
if (responseObject) { // if (responseObject) {
NSString *string = [[NSString alloc] initWithData:responseObject encoding:NSUTF8StringEncoding]; // NSString *string = [[NSString alloc] initWithData:responseObject encoding:NSUTF8StringEncoding];
if ([string isEqualToString:@"success"] || [string isEqualToString:@"订单已存在"]) { // if ([string isEqualToString:@"success"] || [string isEqualToString:@"订单已存在"]) {
// dispatch_async(dispatch_get_main_queue(), ^{
// completion(YES);
// });
// }else if ([string isEqualToString:@"failure"] || [string isEqualToString:@"fail"]){
// dispatch_async(dispatch_get_main_queue(), ^{
// completion(NO);
// });
// }
// }
//
// } failure:^(NSURLSessionDataTask * _Nullable task, NSError * _Nonnull error) {
// //
// NSLog(@"请求失败:%@", error.localizedDescription);
// dispatch_async(dispatch_get_main_queue(), ^{
// completion(NO);
// });
// }];
showLoadingInView(KEYWINDOW)
[[QXRequset shareInstance] postWithUrl:@"api/Payment/notify_apple" parameters:@{@"order_no":self.orderNo?:@"",@"payment_token":payment_token?:@""} needCache:NO success:^(id responseObject) {
dispatch_async(dispatch_get_main_queue(), ^{ dispatch_async(dispatch_get_main_queue(), ^{
hideLoadingInView(KEYWINDOW);
completion(YES); completion(YES);
}); });
}else if ([string isEqualToString:@"failure"] || [string isEqualToString:@"fail"]){ } fail:^(NSError *error, NSString *msg, NSURLSessionDataTask *task) {
dispatch_async(dispatch_get_main_queue(), ^{
completion(NO);
});
}
}
} failure:^(NSURLSessionDataTask * _Nullable task, NSError * _Nonnull error) {
//
NSLog(@"请求失败:%@", error.localizedDescription);
dispatch_async(dispatch_get_main_queue(), ^{ dispatch_async(dispatch_get_main_queue(), ^{
hideLoadingInView(KEYWINDOW);
completion(NO); completion(NO);
showToast(msg);
}); });
}]; }];
} }

View File

@@ -280,7 +280,7 @@
[[NSNotificationCenter defaultCenter] postNotificationName:noticePhotosStatusChange object:nil]; [[NSNotificationCenter defaultCenter] postNotificationName:noticePhotosStatusChange object:nil];
[weakSelf.navigationController popViewControllerAnimated:YES]; [weakSelf.navigationController popViewControllerAnimated:YES];
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) { } failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
showToast(msg)
}]; }];
}else{ }else{
[QXMineNetwork createPhotosWithName:self.textField.text [QXMineNetwork createPhotosWithName:self.textField.text
@@ -295,7 +295,7 @@
} }
failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) { failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
showToast(msg)
}]; }];
} }

View File

@@ -18,8 +18,10 @@
#import "QXPhotosDetailVC.h" #import "QXPhotosDetailVC.h"
#import "QXIntimateContentView.h" #import "QXIntimateContentView.h"
#import "QXHeartBeatSpaceViewController.h" #import "QXHeartBeatSpaceViewController.h"
#import "QXMenuPopView.h"
#import "QXReportViewController.h"
@interface QXUserHomePageViewController ()<JXCategoryViewDelegate,JXPagerViewDelegate,SDCycleScrollViewDelegate> @interface QXUserHomePageViewController ()<JXCategoryViewDelegate,JXPagerViewDelegate,SDCycleScrollViewDelegate,QXMenuPopViewDelegate>
@property (nonatomic,strong)UIImageView * backgourdImageView; @property (nonatomic,strong)UIImageView * backgourdImageView;
@property (nonatomic,strong)SDCycleScrollView * cycleScrollView; @property (nonatomic,strong)SDCycleScrollView * cycleScrollView;
@property (nonatomic,strong)UIButton *backBtn; @property (nonatomic,strong)UIButton *backBtn;
@@ -46,6 +48,13 @@
-(void)setNavgationItems{ -(void)setNavgationItems{
[super setNavgationItems]; [super setNavgationItems];
self.navigationController.navigationBar.backgroundColor = [UIColor clearColor]; self.navigationController.navigationBar.backgroundColor = [UIColor clearColor];
if (![self.user_id isEqualToString:QXGlobal.shareGlobal.loginModel.user_id]) {
UIButton*moreBtn = [[UIButton alloc] initWithFrame:CGRectMake(0, 0, 44, 44)];
[moreBtn setImage:[UIImage imageNamed:@"dynamic_more"] forState:(UIControlStateNormal)];
// backBtn.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeading;
[moreBtn addTarget:self action:@selector(moreAction) forControlEvents:(UIControlEventTouchUpInside)];
self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithCustomView:moreBtn];
}
} }
- (void)initSubViews{ - (void)initSubViews{
self.bgImageHidden = YES; self.bgImageHidden = YES;
@@ -114,6 +123,13 @@
self.pagingView.frame = CGRectMake(0, NavContentHeight, SCREEN_WIDTH, SCREEN_HEIGHT-NavContentHeight); self.pagingView.frame = CGRectMake(0, NavContentHeight, SCREEN_WIDTH, SCREEN_HEIGHT-NavContentHeight);
} }
-(void)moreAction{
QXMenuPopView *menuView = [[QXMenuPopView alloc] initWithPoint:CGPointMake(SCREEN_WIDTH-60, NavContentHeight+10)];
menuView.dataArray = @[QXText(@"举报"),QXText(@"拉黑")];
menuView.delegate = self;
[menuView showInView:KEYWINDOW];
}
-(void)getUserInfo{ -(void)getUserInfo{
MJWeakSelf MJWeakSelf
[QXMineNetwork userHomePageWithUserId:self.user_id successBlock:^(QXUserHomeModel * _Nonnull userModel) { [QXMineNetwork userHomePageWithUserId:self.user_id successBlock:^(QXUserHomeModel * _Nonnull userModel) {
@@ -150,6 +166,20 @@
showToast(msg); showToast(msg);
}]; }];
} }
-(void)didSelectedIndex:(NSInteger)index menuTitle:(NSString*)menuTitle{
if ([menuTitle isEqualToString:QXText(@"举报")]) {
QXReportViewController *reportVC = [[QXReportViewController alloc] init];
reportVC.reportType = @"1";
reportVC.fromId = self.user_id;
[self.navigationController pushViewController:reportVC animated:YES];
}else if ([menuTitle isEqualToString:QXText(@"拉黑")]) {
[QXMineNetwork addOrRemoveBlackListIsAdd:YES userId:self.user_id successBlock:^(NSDictionary * _Nonnull dict) {
showToast(@"操作成功");
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
showToast(msg);
}];
}
}
#pragma mark - JXPagingViewDelegate #pragma mark - JXPagingViewDelegate
- (UIView *)tableHeaderViewInPagerView:(JXPagerView *)pagerView { - (UIView *)tableHeaderViewInPagerView:(JXPagerView *)pagerView {

View File

@@ -90,6 +90,9 @@
weakSelf.topView.model = model; weakSelf.topView.model = model;
weakSelf.contentView.model = model; weakSelf.contentView.model = model;
[weakSelf.contentView reloadData]; [weakSelf.contentView reloadData];
if (QXGlobal.shareGlobal.isAppStore) {
weakSelf.bottomView.hidden = YES;;
}else{
if (weakSelf.model.nobility_info.status.intValue == 0) { if (weakSelf.model.nobility_info.status.intValue == 0) {
weakSelf.bottomView.hidden = YES;; weakSelf.bottomView.hidden = YES;;
}else{ }else{
@@ -97,6 +100,7 @@
weakSelf.bottomNickNameLabel.text = [NSString stringWithFormat:@"%@的当前爵位状态是%@",model.user_info.nickname,model.nobility_info.name]; weakSelf.bottomNickNameLabel.text = [NSString stringWithFormat:@"%@的当前爵位状态是%@",model.user_info.nickname,model.nobility_info.name];
weakSelf.bottomView.hidden = NO;; weakSelf.bottomView.hidden = NO;;
} }
}
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) { } failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
}]; }];

View File

@@ -103,7 +103,7 @@
[weakSelf.navigationController popToRootViewControllerAnimated:YES]; [weakSelf.navigationController popToRootViewControllerAnimated:YES];
} }
failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) { failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
showToast(msg);
}]; }];
} }

View File

@@ -12,6 +12,8 @@ NS_ASSUME_NONNULL_BEGIN
@interface QXRechargeListModel : NSObject @interface QXRechargeListModel : NSObject
@property (nonatomic,strong)NSString *money; @property (nonatomic,strong)NSString *money;
@property (nonatomic,strong)NSString *coins; @property (nonatomic,strong)NSString *coins;
@property (nonatomic,strong)NSString *product_id;
@property (nonatomic,strong)NSString *ios_coins;
@property (nonatomic,assign)BOOL isSelected; @property (nonatomic,assign)BOOL isSelected;
@end @end

View File

@@ -854,7 +854,8 @@ NS_ASSUME_NONNULL_BEGIN
/** /**
充值列表 充值列表
*/ */
+(void)getRechargeListSuccessBlock:(void (^)(NSArray<QXRechargeListModel*>* list))successBlock +(void)getRechargeListIsAppStore:(BOOL)isAppStore
successBlock:(void (^)(NSArray<QXRechargeListModel*>* list))successBlock
failBlock:(void (^)(NSError * error, NSString * msg))failBlock; failBlock:(void (^)(NSError * error, NSString * msg))failBlock;
/** /**
支付 支付

View File

@@ -24,8 +24,8 @@
[QXGlobal shareGlobal].loginModel.hide_status = userModel.hide_status; [QXGlobal shareGlobal].loginModel.hide_status = userModel.hide_status;
[QXGlobal shareGlobal].loginModel.singer_status = userModel.singer_status; [QXGlobal shareGlobal].loginModel.singer_status = userModel.singer_status;
[[QXGlobal shareGlobal] updateUserInfoWithMolde:[QXGlobal shareGlobal].loginModel]; [[QXGlobal shareGlobal] updateUserInfoWithMolde:[QXGlobal shareGlobal].loginModel];
BOOL api_version = [responseObject[@"api_version"] boolValue]; // BOOL api_version = [responseObject[@"api_version"] boolValue];
[QXGlobal shareGlobal].isAppStore = api_version; // [QXGlobal shareGlobal].isAppStore = api_version;
[[NSUserDefaults standardUserDefaults] setInteger:userModel.is_can_chat forKey:kIsCanChat]; [[NSUserDefaults standardUserDefaults] setInteger:userModel.is_can_chat forKey:kIsCanChat];
[[NSUserDefaults standardUserDefaults] setObject:userModel.can_chat_money forKey:kIsCanChatMoney]; [[NSUserDefaults standardUserDefaults] setObject:userModel.can_chat_money forKey:kIsCanChatMoney];
[[NSUserDefaults standardUserDefaults] synchronize]; [[NSUserDefaults standardUserDefaults] synchronize];
@@ -1689,8 +1689,11 @@
}]; }];
} }
+(void)getRechargeListSuccessBlock:(void (^)(NSArray<QXRechargeListModel *> * _Nonnull))successBlock failBlock:(void (^)(NSError * _Nonnull, NSString * _Nonnull))failBlock{ +(void)getRechargeListIsAppStore:(BOOL)isAppStore
[[QXRequset shareInstance] getWithUrl:QXRechargeList parameters:@{} needCache:NO success:^(id responseObject) { successBlock:(void (^)(NSArray<QXRechargeListModel *> * _Nonnull))successBlock
failBlock:(void (^)(NSError * _Nonnull, NSString * _Nonnull))failBlock{
NSString *urlString = isAppStore?QXRechargeListIOS:QXRechargeList;
[[QXRequset shareInstance] getWithUrl:urlString parameters:@{} needCache:NO success:^(id responseObject) {
if (successBlock) { if (successBlock) {
NSArray*list = [NSArray yy_modelArrayWithClass:[QXRechargeListModel class] json:responseObject[@"data"]]; NSArray*list = [NSArray yy_modelArrayWithClass:[QXRechargeListModel class] json:responseObject[@"data"]];
successBlock(list); successBlock(list);

View File

@@ -17,7 +17,7 @@
-(void)setModel:(QXRechargeListModel *)model{ -(void)setModel:(QXRechargeListModel *)model{
_model = model; _model = model;
self.priceLabel.text = model.money; self.priceLabel.text = model.money;
[self.cornBtn setTitle:model.coins forState:(UIControlStateNormal)]; [self.cornBtn setTitle:QXGlobal.shareGlobal.isAppStore?model.ios_coins:model.coins forState:(UIControlStateNormal)];
if (model.money.intValue == 0 && model.coins.intValue == 0) { if (model.money.intValue == 0 && model.coins.intValue == 0) {
self.customLabel.hidden = NO; self.customLabel.hidden = NO;
self.cornBtn.hidden = YES; self.cornBtn.hidden = YES;

View File

@@ -11,6 +11,7 @@
#import "QXMineNetwork.h" #import "QXMineNetwork.h"
#import <AlipaySDK/AlipaySDK.h> #import <AlipaySDK/AlipaySDK.h>
#import <WXApi.h> #import <WXApi.h>
#import "QXIAPManager.h"
@class QXRechargeCustomView,QXRechargeHeaderView; @class QXRechargeCustomView,QXRechargeHeaderView;
@interface QXRechargeView()<UICollectionViewDelegate,UICollectionViewDataSource,UICollectionViewDelegateFlowLayout,UIGestureRecognizerDelegate> @interface QXRechargeView()<UICollectionViewDelegate,UICollectionViewDataSource,UICollectionViewDelegateFlowLayout,UIGestureRecognizerDelegate>
@@ -38,10 +39,10 @@
} }
-(void)initSubviews{ -(void)initSubviews{
QXRechargeListModel *model = [[QXRechargeListModel alloc] init]; // QXRechargeListModel *model = [[QXRechargeListModel alloc] init];
model.money = @"0"; // model.money = @"0";
model.coins = @"0"; // model.coins = @"0";
[self.rechargeDataArray addObject:model]; // [self.rechargeDataArray addObject:model];
UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(hide)]; UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(hide)];
tap.delegate = self; tap.delegate = self;
tap.enabled = NO; tap.enabled = NO;
@@ -84,19 +85,25 @@
} }
-(void)getRechargeList{ -(void)getRechargeList{
if (QXGlobal.shareGlobal.isAppStore) {
MJWeakSelf MJWeakSelf
[QXMineNetwork getRechargeListSuccessBlock:^(NSArray<QXRechargeListModel *> * _Nonnull list) { [QXMineNetwork getRechargeListIsAppStore:YES successBlock:^(NSArray<QXRechargeListModel *> * _Nonnull list) {
[weakSelf.rechargeDataArray removeAllObjects]; [weakSelf.rechargeDataArray removeAllObjects];
[weakSelf.rechargeDataArray addObjectsFromArray:list]; [weakSelf.rechargeDataArray addObjectsFromArray:list];
// QXRechargeListModel *model = [[QXRechargeListModel alloc] init];
// model.money = @"0";
// model.coins = @"0";
// [weakSelf.rechargeDataArray addObject:model];
[weakSelf.collectionView reloadSections:[NSIndexSet indexSetWithIndex:0]]; [weakSelf.collectionView reloadSections:[NSIndexSet indexSetWithIndex:0]];
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) { } failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
}]; }];
}else{
MJWeakSelf
[QXMineNetwork getRechargeListIsAppStore:NO successBlock:^(NSArray<QXRechargeListModel *> * _Nonnull list) {
[weakSelf.rechargeDataArray removeAllObjects];
[weakSelf.rechargeDataArray addObjectsFromArray:list];
[weakSelf.collectionView reloadSections:[NSIndexSet indexSetWithIndex:0]];
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
}];
[QXMineNetwork walletPayTypeWithUserId:QXGlobal.shareGlobal.loginModel.user_id successBlock:^(QXPayTypeStatusModel * _Nonnull model) { [QXMineNetwork walletPayTypeWithUserId:QXGlobal.shareGlobal.loginModel.user_id successBlock:^(QXPayTypeStatusModel * _Nonnull model) {
[weakSelf.payTypeArray removeAllObjects]; [weakSelf.payTypeArray removeAllObjects];
if (model.wx.is_pay_open.intValue == 1) { if (model.wx.is_pay_open.intValue == 1) {
@@ -119,6 +126,7 @@
}]; }];
} }
}
-(void)setIsPop:(BOOL)isPop{ -(void)setIsPop:(BOOL)isPop{
_isPop = isPop; _isPop = isPop;
@@ -166,19 +174,32 @@
//} //}
-(NSInteger)numberOfSectionsInCollectionView:(UICollectionView *)collectionView{ -(NSInteger)numberOfSectionsInCollectionView:(UICollectionView *)collectionView{
if (QXGlobal.shareGlobal.isAppStore) {
return 1;
}else{
if (self.isOnlyDisplayPayType) { if (self.isOnlyDisplayPayType) {
return 1; return 1;
} }
return 2; return 2;
} }
}
-(NSInteger)collectionView:(UICollectionView *)collectionView numberOfItemsInSection:(NSInteger)section{ -(NSInteger)collectionView:(UICollectionView *)collectionView numberOfItemsInSection:(NSInteger)section{
if (QXGlobal.shareGlobal.isAppStore) {
return self.rechargeDataArray.count;
}else{
if (section == 0 && !self.isOnlyDisplayPayType) { if (section == 0 && !self.isOnlyDisplayPayType) {
return self.rechargeDataArray.count; return self.rechargeDataArray.count;
} }
return self.payTypeArray.count; return self.payTypeArray.count;
} }
}
-(__kindof UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath{ -(__kindof UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath{
if (QXGlobal.shareGlobal.isAppStore) {
QXRechargePriceCell *cell = [collectionView dequeueReusableCellWithReuseIdentifier:@"QXRechargePriceCell" forIndexPath:indexPath];
cell.model = self.rechargeDataArray[indexPath.row];
return cell;
}else{
if (indexPath.section == 0 && !self.isOnlyDisplayPayType) { if (indexPath.section == 0 && !self.isOnlyDisplayPayType) {
QXRechargePriceCell *cell = [collectionView dequeueReusableCellWithReuseIdentifier:@"QXRechargePriceCell" forIndexPath:indexPath]; QXRechargePriceCell *cell = [collectionView dequeueReusableCellWithReuseIdentifier:@"QXRechargePriceCell" forIndexPath:indexPath];
cell.model = self.rechargeDataArray[indexPath.row]; cell.model = self.rechargeDataArray[indexPath.row];
@@ -189,19 +210,31 @@
return cell; return cell;
} }
} }
}
- (CGSize)collectionView:(UICollectionView *)collectionView layout:(UICollectionViewLayout *)collectionViewLayout sizeForItemAtIndexPath:(NSIndexPath *)indexPath{ - (CGSize)collectionView:(UICollectionView *)collectionView layout:(UICollectionViewLayout *)collectionViewLayout sizeForItemAtIndexPath:(NSIndexPath *)indexPath{
if (QXGlobal.shareGlobal.isAppStore) {
return CGSizeMake((SCREEN_WIDTH-16*2-12*2-1)/3, 76);
}else{
if (indexPath.section == 0 && !self.isOnlyDisplayPayType) { if (indexPath.section == 0 && !self.isOnlyDisplayPayType) {
return CGSizeMake((SCREEN_WIDTH-16*2-12*2-1)/3, 76); return CGSizeMake((SCREEN_WIDTH-16*2-12*2-1)/3, 76);
} }
return CGSizeMake(SCREEN_WIDTH, 40); return CGSizeMake(SCREEN_WIDTH, 40);
} }
}
-(CGFloat)collectionView:(UICollectionView *)collectionView layout:(UICollectionViewLayout *)collectionViewLayout minimumLineSpacingForSectionAtIndex:(NSInteger)section{ -(CGFloat)collectionView:(UICollectionView *)collectionView layout:(UICollectionViewLayout *)collectionViewLayout minimumLineSpacingForSectionAtIndex:(NSInteger)section{
if (QXGlobal.shareGlobal.isAppStore) {
return 12;
}else{
if (section == 0) { if (section == 0) {
return 12; return 12;
} }
return 0; return 0;
} }
}
-(UICollectionReusableView *)collectionView:(UICollectionView *)collectionView viewForSupplementaryElementOfKind:(NSString *)kind atIndexPath:(NSIndexPath *)indexPath{ -(UICollectionReusableView *)collectionView:(UICollectionView *)collectionView viewForSupplementaryElementOfKind:(NSString *)kind atIndexPath:(NSIndexPath *)indexPath{
if (QXGlobal.shareGlobal.isAppStore) {
return nil;
}else{
if (indexPath.section == 0 && [kind isEqualToString:UICollectionElementKindSectionFooter] && self.isCustom) { if (indexPath.section == 0 && [kind isEqualToString:UICollectionElementKindSectionFooter] && self.isCustom) {
self.rechargeCustomView = [collectionView dequeueReusableSupplementaryViewOfKind:UICollectionElementKindSectionFooter withReuseIdentifier:@"QXRechargeCustomView" forIndexPath:indexPath]; self.rechargeCustomView = [collectionView dequeueReusableSupplementaryViewOfKind:UICollectionElementKindSectionFooter withReuseIdentifier:@"QXRechargeCustomView" forIndexPath:indexPath];
return self.rechargeCustomView; return self.rechargeCustomView;
@@ -209,23 +242,46 @@
self.rechargeHeaderView = [collectionView dequeueReusableSupplementaryViewOfKind:UICollectionElementKindSectionHeader withReuseIdentifier:@"QXRechargeHeaderView" forIndexPath:indexPath]; self.rechargeHeaderView = [collectionView dequeueReusableSupplementaryViewOfKind:UICollectionElementKindSectionHeader withReuseIdentifier:@"QXRechargeHeaderView" forIndexPath:indexPath];
return self.rechargeHeaderView; return self.rechargeHeaderView;
} }
}
return nil; return nil;
} }
-(CGSize)collectionView:(UICollectionView *)collectionView layout:(UICollectionViewLayout *)collectionViewLayout referenceSizeForHeaderInSection:(NSInteger)section{ -(CGSize)collectionView:(UICollectionView *)collectionView layout:(UICollectionViewLayout *)collectionViewLayout referenceSizeForHeaderInSection:(NSInteger)section{
if (QXGlobal.shareGlobal.isAppStore) {
return CGSizeZero;
}else{
if (section == 0) { if (section == 0) {
return CGSizeZero; return CGSizeZero;
} }
return CGSizeMake(SCREEN_WIDTH, 40); return CGSizeMake(SCREEN_WIDTH, 40);
} }
}
-(CGSize)collectionView:(UICollectionView *)collectionView layout:(UICollectionViewLayout *)collectionViewLayout referenceSizeForFooterInSection:(NSInteger)section{ -(CGSize)collectionView:(UICollectionView *)collectionView layout:(UICollectionViewLayout *)collectionViewLayout referenceSizeForFooterInSection:(NSInteger)section{
if (QXGlobal.shareGlobal.isAppStore) {
return CGSizeZero;
}else{
if (section == 0 && self.isCustom) { if (section == 0 && self.isCustom) {
return CGSizeMake(SCREEN_WIDTH, 50); return CGSizeMake(SCREEN_WIDTH, 50);
} }
return CGSizeZero; return CGSizeZero;
} }
}
-(void)collectionView:(UICollectionView *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath{ -(void)collectionView:(UICollectionView *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath{
if (QXGlobal.shareGlobal.isAppStore) {
QXRechargeListModel *model = self.rechargeDataArray[indexPath.row];
if (self.selectedModel) {
self.selectedModel.isSelected = NO;
}
model.isSelected = YES;
self.selectedModel = model;
if (model.money.intValue == 0 && model.coins.intValue == 0) {
self.isCustom = YES;
}else{
self.isCustom = NO;
}
[collectionView reloadSections:[NSIndexSet indexSetWithIndex:0]];
}else{
if (indexPath.section == 0 && !self.isOnlyDisplayPayType) { if (indexPath.section == 0 && !self.isOnlyDisplayPayType) {
QXRechargeListModel *model = self.rechargeDataArray[indexPath.row]; QXRechargeListModel *model = self.rechargeDataArray[indexPath.row];
if (self.selectedModel) { if (self.selectedModel) {
@@ -252,21 +308,28 @@
[collectionView reloadData]; [collectionView reloadData];
} }
} }
}
-(void)rechargeAction:(UIButton*)sender{ -(void)rechargeAction:(UIButton*)sender{
if (self.selectedPayTypeModel == nil) {
showToast(@"请选择支付方式");
return;
}
if (self.selectedModel == nil) { if (self.selectedModel == nil) {
showToast(@"请选择充值金额"); showToast(@"请选择充值金额");
return; return;
} }
NSString *coins = @"0";
if (QXGlobal.shareGlobal.isAppStore) {
self.selectedPayTypeModel = [[QXPayTypeModel alloc] init];
self.selectedPayTypeModel.type = @"6";
coins = self.selectedModel.ios_coins;
}else{
coins = self.selectedModel.coins;
if (self.selectedPayTypeModel == nil) {
showToast(@"请选择支付方式");
return;
}
}
@weakify(self) @weakify(self)
[QXMineNetwork rechargePayWithMoney:self.selectedModel.money coin:self.selectedModel.coins type:self.selectedPayTypeModel.type userId:QXGlobal.shareGlobal.loginModel.user_id typeId:self.gift_bag_id nobility_id:@"" successBlock:^(NSDictionary * _Nonnull dict) { [QXMineNetwork rechargePayWithMoney:self.selectedModel.money coin:coins type:self.selectedPayTypeModel.type userId:QXGlobal.shareGlobal.loginModel.user_id typeId:self.gift_bag_id nobility_id:@"" successBlock:^(NSDictionary * _Nonnull dict) {
@strongify(self) @strongify(self)
if (self.selectedPayTypeModel.type.intValue == 2) { if (self.selectedPayTypeModel.type.intValue == 2) {
NSDictionary *resultDict = dict[@"data"]; NSDictionary *resultDict = dict[@"data"];
@@ -326,6 +389,9 @@
launchMiniProgramReq.path = [NSString stringWithFormat:@"pages/orderDetail/orderDetail?%@",param]; launchMiniProgramReq.path = [NSString stringWithFormat:@"pages/orderDetail/orderDetail?%@",param];
launchMiniProgramReq.miniProgramType = WXMiniProgramTypeRelease; launchMiniProgramReq.miniProgramType = WXMiniProgramTypeRelease;
[WXApi sendReq:launchMiniProgramReq completion:nil]; [WXApi sendReq:launchMiniProgramReq completion:nil];
}else if (self.selectedPayTypeModel.type.intValue == 6) {
NSString*order_no = [NSString stringWithFormat:@"%@",dict[@"data"][@"order_no"]];
[[QXIAPManager sharedInstance] buyGoodsWithId:self.selectedModel.product_id orderNo:order_no];
} }
if (self.isPop) { if (self.isPop) {
[self hide]; [self hide];

View File

@@ -126,9 +126,14 @@
} }
} }
-(void)setHaveNobility:(BOOL)have{ -(void)setHaveNobility:(BOOL)have{
if (QXGlobal.shareGlobal.isAppStore) {
self.openBtn.hidden = YES;
self.buyBtn.hidden = YES;
}else{
self.openBtn.hidden = have; self.openBtn.hidden = have;
self.buyBtn.hidden = !have; self.buyBtn.hidden = !have;
self.currentNobilityLabel.hidden = !have; self.currentNobilityLabel.hidden = !have;
}
self.currentNobilityLabel.text = self.model.nobility_info.name; self.currentNobilityLabel.text = self.model.nobility_info.name;
self.currentNobilityTimeLabel.text = have?[NSString stringWithFormat:@"截止时间:%@",self.model.nobility_info.end_time]:@"您尚未开通任何爵位"; self.currentNobilityTimeLabel.text = have?[NSString stringWithFormat:@"截止时间:%@",self.model.nobility_info.end_time]:@"您尚未开通任何爵位";
} }

View File

@@ -278,6 +278,9 @@
[[QXGiftDisplayManager sharedManager] becomeFront]; [[QXGiftDisplayManager sharedManager] becomeFront];
[[QXGlobal shareGlobal] dirfViewBecomeToFront]; [[QXGlobal shareGlobal] dirfViewBecomeToFront];
}else{ }else{
if (QXGlobal.shareGlobal.isNeedUpdate) {
return;
}
[self getRecommendRoom]; [self getRecommendRoom];
} }
} }
@@ -365,9 +368,18 @@
XHLaunchVideoAdConfiguration *videoAdconfiguration = [XHLaunchVideoAdConfiguration defaultConfiguration]; XHLaunchVideoAdConfiguration *videoAdconfiguration = [XHLaunchVideoAdConfiguration defaultConfiguration];
// NSString *path = [[NSBundle mainBundle] pathForResource:@"app_start" ofType:@"mp4"]; // NSString *path = [[NSBundle mainBundle] pathForResource:@"app_start" ofType:@"mp4"];
videoAdconfiguration.videoNameOrURLString = @"app_start2.mp4"; videoAdconfiguration.videoNameOrURLString = @"app_start2.mp4";
videoAdconfiguration.duration = 7; videoAdconfiguration.duration = 19;
videoAdconfiguration.skipButtonType = SkipTypeNone; videoAdconfiguration.skipButtonType = SkipTypeNone;
videoAdconfiguration.videoCycleOnce = YES; videoAdconfiguration.videoCycleOnce = YES;
UIButton *btn = [[UIButton alloc] initWithFrame:CGRectMake(SCREEN_WIDTH-60-10, 80, 60, 30)];
[btn setTitle:@"跳过" forState:(UIControlStateNormal)];
[btn setTitleColor:QXConfig.themeColor forState:(UIControlStateNormal)];
btn.titleLabel.font = [UIFont systemFontOfSize:14];
[btn addRoundedCornersWithRadius:17.5];
btn.layer.borderColor = QXConfig.themeColor.CGColor;
btn.layer.borderWidth = 1;
[btn addTarget:self action:@selector(jumpAction) forControlEvents:(UIControlEventTouchUpInside)];
videoAdconfiguration.subViews = @[btn];
[XHLaunchAd videoAdWithVideoAdConfiguration:videoAdconfiguration delegate:self]; [XHLaunchAd videoAdWithVideoAdConfiguration:videoAdconfiguration delegate:self];
//广URLString/(.jpg/.gif) //广URLString/(.jpg/.gif)
// imageAdconfiguration. = model.img; // imageAdconfiguration. = model.img;
@@ -376,6 +388,10 @@
// //广 // //广
// [XHLaunchAd imageAdWithImageAdConfiguration:imageAdconfiguration delegate:self]; // [XHLaunchAd imageAdWithImageAdConfiguration:imageAdconfiguration delegate:self];
} }
-(void)jumpAction{
[XHLaunchAd removeAndAnimated:YES];
}
- (BOOL)xhLaunchAd:(XHLaunchAd *)launchAd clickAtOpenModel:(id)openModel clickPoint:(CGPoint)clickPoint{ - (BOOL)xhLaunchAd:(XHLaunchAd *)launchAd clickAtOpenModel:(id)openModel clickPoint:(CGPoint)clickPoint{
[XHLaunchAd removeAndAnimated:YES]; [XHLaunchAd removeAndAnimated:YES];
return YES; return YES;

View File

@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "gift_coin_funny_bg@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "gift_coin_funny_bg@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 100 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 200 KiB

View File

@@ -20,6 +20,8 @@ static NSString* ServerUrl = @"https://test.vespa.qxyushen.top/";
//static NSString* ServerUrl = @"http://test.chat.qxyushen.top"; //static NSString* ServerUrl = @"http://test.chat.qxyushen.top";
static NSString* H5ServerUrl = @"https://test.vespa.qxyushen.top/h5/"; static NSString* H5ServerUrl = @"https://test.vespa.qxyushen.top/h5/";
#else #else
//static NSString* ServerUrl = @"https://test.vespa.qxyushen.top/";
//static NSString* H5ServerUrl = @"https://test.vespa.qxyushen.top/h5/";
//static NSString* ServerUrl = @"https://vespa.qxyushen.top/"; //static NSString* ServerUrl = @"https://vespa.qxyushen.top/";
//static NSString* H5ServerUrl = @"https://vespa.qxyushen.top/h5/"; //static NSString* H5ServerUrl = @"https://vespa.qxyushen.top/h5/";
static NSString* ServerUrl = @"https://yushengapi.qxyushen.top/"; static NSString* ServerUrl = @"https://yushengapi.qxyushen.top/";
@@ -388,6 +390,8 @@ static NSString * QXRealNameInfo = @"api/UserData/real_name_info";
/// 充值列表 /// 充值列表
static NSString * QXRechargeList = @"api/UserWallet/can_recharge_list"; static NSString * QXRechargeList = @"api/UserWallet/can_recharge_list";
/// 充值列表上架版
static NSString * QXRechargeListIOS = @"api/UserWallet/can_recharge_list_ios";
/// 支付 /// 支付
static NSString * QXRechargePay = @"api/Payment/app_pay"; static NSString * QXRechargePay = @"api/Payment/app_pay";
/// 兑币比例 | 提现手续费 | 人民币购买金币 /// 兑币比例 | 提现手续费 | 人民币购买金币

View File

@@ -181,7 +181,7 @@ NSPhotoLibraryUsageDescription = "访问您的相册,允许可以把视频保存
"请输入监护密码" = "请输入监护密码"; "请输入监护密码" = "请输入监护密码";
"请输入房间密码" = "请输入房间密码"; "请输入房间密码" = "请输入房间密码";
"请联系客服" = "请联系客服"; "请联系客服" = "请联系客服";
"为了呵护未成年人健康成长,蜜耳语音特别推出青少年模式,该模式下部分功能无法正常使用,请监护人主动选择并设置监护密码" = "为了呵护未成年人健康成长,蜜耳语音特别推出青少年模式,该模式下部分功能无法正常使用,请监护人主动选择并设置监护密码"; "为了呵护未成年人健康成长,羽声语音特别推出青少年模式,该模式下部分功能无法正常使用,请监护人主动选择并设置监护密码" = "为了呵护未成年人健康成长,羽声语音特别推出青少年模式,该模式下部分功能无法正常使用,请监护人主动选择并设置监护密码";
"移除" = "移除"; "移除" = "移除";
"回关" = "回关"; "回关" = "回关";
"已互关" = "已互关"; "已互关" = "已互关";

View File

@@ -82,6 +82,7 @@
NSLog(@"需要更新:新版本 %@ 比当前版本 %@ 新", latestVersion, currentVersion); NSLog(@"需要更新:新版本 %@ 比当前版本 %@ 新", latestVersion, currentVersion);
weakSelf.appUpdateView.model = model; weakSelf.appUpdateView.model = model;
[weakSelf.appUpdateView showInView:KEYWINDOW]; [weakSelf.appUpdateView showInView:KEYWINDOW];
QXGlobal.shareGlobal.isNeedUpdate = YES;
break; break;
case 0: case 0:
NSLog(@"版本相同:当前版本 %@ 已是最新", currentVersion); NSLog(@"版本相同:当前版本 %@ 已是最新", currentVersion);
@@ -96,6 +97,9 @@
} }
#pragma mark - #pragma mark -
-(void)popChirldView{ -(void)popChirldView{
if (QXGlobal.shareGlobal.isNeedUpdate) {
return;
}
self.isAlreadyShowChirld = YES; self.isAlreadyShowChirld = YES;
MJWeakSelf MJWeakSelf
QXChirldPopView *view = [[QXChirldPopView alloc] init]; QXChirldPopView *view = [[QXChirldPopView alloc] init];

View File

@@ -51,7 +51,7 @@
self.contentLabel.numberOfLines = 0; self.contentLabel.numberOfLines = 0;
self.contentLabel.font = [UIFont boldSystemFontOfSize:14]; self.contentLabel.font = [UIFont boldSystemFontOfSize:14];
self.contentLabel.textColor = RGB16(0x666666); self.contentLabel.textColor = RGB16(0x666666);
self.contentLabel.text = QXText(@"为了呵护未成年人健康成长,蜜耳语音特别推出青少年模式,该模式下部分功能无法正常使用,请监护人主动选择并设置监护密码"); self.contentLabel.text = QXText(@"为了呵护未成年人健康成长,羽声语音特别推出青少年模式,该模式下部分功能无法正常使用,请监护人主动选择并设置监护密码");
[self addSubview:self.contentLabel]; [self addSubview:self.contentLabel];
// self.goBtn = [[UIButton alloc] init]; // self.goBtn = [[UIButton alloc] init];