molistar商店包版本修改 此commit置顶 1.0.3

This commit is contained in:
liyuhua
2024-04-25 15:40:23 +08:00
parent cfd4111b24
commit ae2b044a5f
8 changed files with 36 additions and 27 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 22 KiB

After

Width:  |  Height:  |  Size: 76 KiB

View File

@@ -23,6 +23,7 @@ NS_ASSUME_NONNULL_BEGIN
///开箱子 大于等级 展示
@property (nonatomic, assign) NSInteger openCandyTreeLimitLevel;
@property (nonatomic,assign) BOOL canOpen;
@property(nonatomic,assign) BOOL isTF;
///是否刷新了
@property (nonatomic,assign) BOOL isLoad;
///房间id用于分享房间跳转到房间

View File

@@ -35,7 +35,12 @@
});
return config;
}
-(BOOL)isTestFlight{
NSURL *receiptURL = [[NSBundle mainBundle] appStoreReceiptURL];
NSString *receiptURLString = [receiptURL path];
BOOL isTestFlight = ([receiptURLString containsString:@"sandboxReceipt"] || [receiptURLString containsString:@"_MASReceipt/receipt"]);
return isTestFlight;
}
- (void)clientInit {
self.canOpen = YES;
@@ -110,6 +115,11 @@
timer = nil;
}
}
- (BOOL)isTF{
if(!_isTF){
_isTF = [self isTestFlight];
}
return _isTF;
}
@end

View File

@@ -52,7 +52,8 @@ isPhoneXSeries = [[UIApplication sharedApplication] delegate].window.safeAreaIns
#define PI_App_Version @"1.0.3"
///渠道
#define PI_App_Source @"appstore"
//#define PI_App_Source @"pi_tf"
#define PI_Test_Flight @"TestFlight"
///正式环境
#define API_HOST_URL @"https://api.hfighting.com"
//#define API_HOST_URL @"https://api.molistar.xyz"

View File

@@ -54,7 +54,7 @@
</dict>
</array>
<key>CFBundleVersion</key>
<string>2</string>
<string>4</string>
<key>FacebookAppID</key>
<string>1266232494209868</string>
<key>FacebookClientToken</key>

View File

@@ -38,6 +38,7 @@
[self.titleView mas_makeConstraints:^(MASConstraintMaker *make) {
make.centerY.equalTo(self.contentView);
make.leading.equalTo(self.iconView.mas_trailing).mas_offset(10);
make.trailing.equalTo(self.selectBtn.mas_leading).mas_offset(-kGetScaleWidth(10));
}];
[self.selectBtn mas_makeConstraints:^(MASConstraintMaker *make) {
make.width.height.mas_equalTo(20);
@@ -70,6 +71,7 @@
_titleView = [UILabel new];
_titleView.font = [UIFont systemFontOfSize:16 weight:UIFontWeightBold];
_titleView.textColor = UIColorFromRGB(0x1F1B4F);
_titleView.adjustsFontSizeToFitWidth = YES;
}
return _titleView;
}

View File

@@ -103,7 +103,7 @@
-(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{
XPNobleCenterPayCell *cell = [tableView dequeueReusableCellWithIdentifier:NSStringFromClass([XPNobleCenterPayCell class]) forIndexPath:indexPath];
cell.isChoose = indexPath.row == self.path.row;
cell.iconImage = indexPath.row == 0 ? kImage( @"exchange_gold_icon") : kImage(@"mine_noble_center_apple");
cell.iconImage = indexPath.row == 0 ? kImage( @"exchange_gold_icon") : kImage(@"noble_open_btn");
NSString *num = [NSString stringWithFormat:@"%@%@",self.diamonds,YMLocalizedString(@"XPNobleCenterPayView1")];
NSString *text = indexPath.row == 0 ? [NSString stringWithFormat:@"%@%@",self.listData[indexPath.row],num] : self.listData[indexPath.row];
@@ -117,7 +117,7 @@
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{
self.path = indexPath;
self.type = indexPath.row == 0 ? NobleCenterPayType_diamond : NobleCenterPayType_Apple;
self.diamondNumView.text = indexPath.row == 0 ? [NSString stringWithFormat:@"%.0f",_money.floatValue * 1000] : [NSString stringWithFormat:@"%.2f",_money.floatValue];
self.diamondNumView.text = indexPath.row == 0 ? [NSString stringWithFormat:@"%.0f",_money.floatValue * 1000] : [NSString stringWithFormat:@"$%.2f",_money.floatValue];
self.diamondNumTitle.text = indexPath.row == 0 ? YMLocalizedString(@"XPNobleCenterPayView1"):@"";
[self.tableView reloadData];
}
@@ -201,10 +201,10 @@
- (NSArray *)listData{
if(!_listData){
#ifdef DEBUG
_listData = @[YMLocalizedString(@"XPNobleCenterPayView2"),@"Apple Pay"];
_listData = @[YMLocalizedString(@"XPNobleCenterPayView2"),YMLocalizedString(@"XPNobleCenterWindow0")];
#else
if(isEnterprise == YES){
_listData = @[YMLocalizedString(@"XPNobleCenterPayView2"),@"Apple Pay"];
_listData = @[YMLocalizedString(@"XPNobleCenterPayView2"),YMLocalizedString(@"XPNobleCenterWindow0")];
}else{
_listData = @[YMLocalizedString(@"XPNobleCenterPayView2")];
}

View File

@@ -9,6 +9,7 @@
#import "YYUtility.h"
#import <CoreTelephony/CTTelephonyNetworkInfo.h> //
#import <CoreTelephony/CTCarrier.h> //
#import "ClientConfig.h"
@@ -33,8 +34,18 @@
}
+ (NSString *)appName {
#ifdef DEBUG
NSString *isProduction = [[NSUserDefaults standardUserDefaults]valueForKey:@"kIsProductionEnvironment"];
if([isProduction isEqualToString:@"YES"]){
return @"youmi";
}
return @"molistar";
#else
return @"youmi";
#endif
return @"molistar";
@@ -110,27 +121,11 @@ static NSString *_from = nil;
+ (NSString *)getAppSource{
if (_from == nil) {
NSString *path = [[NSBundle mainBundle] pathForResource:@"sourceid.dat" ofType:nil];
NSError *error;
NSString *from = [NSString stringWithContentsOfFile:path encoding:NSUTF8StringEncoding error:&error];
//
if (from) {
from = [self removeSpaceAndNewline:from];
}
// 0
if (!error
&& ![from isEqualToString:@"0"]
&& ![from isEqualToString:@""]) {
_from = from;
} else {
if (isEnterprise == NO) {
_from = @"molistar_enterprise"; //
_from = @"molistar_enterprise"; //
}else {
_from = PI_App_Source; //appstore App Store
_from = [ClientConfig shareConfig].isTF == YES ? PI_Test_Flight : PI_App_Source; // Test_Flightappstore App Store
}
}
}
return _from;