From 95a8cfc86dd8fe8832fd314cd5d11ddaec76785f Mon Sep 17 00:00:00 2001 From: liyuhua <15626451870@163.com> Date: Fri, 3 Nov 2023 11:19:14 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8D=87=E7=BA=A7trtc?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Podfile | 2 +- YuMi/Global/YUMIMacroUitls.h | 2 ++ .../Recharge/XPIAPRechargeViewController.m | 31 +++++++++++++++++++ YuMi/Tools/YYUtility/YYUtility+App.m | 2 +- 4 files changed, 35 insertions(+), 2 deletions(-) diff --git a/Podfile b/Podfile index d18a6720..204eea6c 100644 --- a/Podfile +++ b/Podfile @@ -39,7 +39,7 @@ target 'YuMi' do pod 'IQKeyboardManager' pod 'TZImagePickerController' #TRTC - pod 'TXLiteAVSDK_TRTC', '~> 11.4.0.14530' + pod 'TXLiteAVSDK_TRTC', '~> 11.4.14530' #vap礼物动画 pod 'QGVAPlayer' #上传音乐 diff --git a/YuMi/Global/YUMIMacroUitls.h b/YuMi/Global/YUMIMacroUitls.h index 50281281..746f0712 100644 --- a/YuMi/Global/YUMIMacroUitls.h +++ b/YuMi/Global/YUMIMacroUitls.h @@ -50,6 +50,8 @@ isPhoneXSeries = [[UIApplication sharedApplication] delegate].window.safeAreaIns #define PI_App_Version @"2.2.1" +#define PI_App_Source @"appstore" +//#define PI_App_Source @"pi_tf" #ifdef DEBUG #define API_HOST_URL [NSString stringWithFormat:@"%@%@",@"http://beta.api",@".pekolive.com"] diff --git a/YuMi/Modules/YMMine/View/Recharge/XPIAPRechargeViewController.m b/YuMi/Modules/YMMine/View/Recharge/XPIAPRechargeViewController.m index df3df8d0..18ad7779 100644 --- a/YuMi/Modules/YMMine/View/Recharge/XPIAPRechargeViewController.m +++ b/YuMi/Modules/YMMine/View/Recharge/XPIAPRechargeViewController.m @@ -91,6 +91,9 @@ - (void)viewDidLoad { [super viewDidLoad]; +#ifdef DEBUG + + if([ClientConfig shareConfig].canOpen){ [self showLoading]; [Api requestMineChannel:^(BaseModel * _Nullable data, NSInteger code, NSString * _Nullable msg) { @@ -107,6 +110,34 @@ return; } [self initWebView:YES]; + + + + +#else + if(isEnterprise == YES){ + if([ClientConfig shareConfig].canOpen){ + [self showLoading]; + [Api requestMineChannel:^(BaseModel * _Nullable data, NSInteger code, NSString * _Nullable msg) { + [self hideHUD]; + if(code == 200){ + if(data.data[@"isNative"] != nil){ + BOOL is = [data.data[@"isNative"] boolValue]; + [self initWebView:is]; + } + return; + } + [self initWebView:YES]; + }]; + return; + } + [self initWebView:YES]; + + }else{ + [self initWebView:NO]; + } +#endif + } diff --git a/YuMi/Tools/YYUtility/YYUtility+App.m b/YuMi/Tools/YYUtility/YYUtility+App.m index 3a44ea7d..602a50c3 100644 --- a/YuMi/Tools/YYUtility/YYUtility+App.m +++ b/YuMi/Tools/YYUtility/YYUtility+App.m @@ -121,7 +121,7 @@ static NSString *_from = nil; if (isEnterprise == NO) { _from = @"piko_Enterprise"; // 企业包 }else { - _from = @"appstore"; // App Store包 + _from = PI_App_Source; // App Store包 } } }