提交
This commit is contained in:
@@ -368,6 +368,7 @@
|
||||
-(void)gotoSetting{
|
||||
QXSettingViewController *vc = [[QXSettingViewController alloc] init];
|
||||
vc.haveNobility = self.userModel.is_hide.intValue == 1;
|
||||
vc.haveMobile = [QXGlobal.shareGlobal.loginModel.mobile isExist];
|
||||
MJWeakSelf
|
||||
vc.logOutBlock = ^(BOOL isCancel, NSString * _Nonnull code) {
|
||||
weakSelf.cancelCode = code;
|
||||
|
||||
@@ -17,5 +17,6 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
@property (nonatomic,strong)QXDayTaskTypeModel *model;
|
||||
@property (nonatomic,strong)UIButton *titleBtn;
|
||||
@property (nonatomic,strong)UIButton *lockImageBtn;
|
||||
@property (nonatomic,strong)UILabel *badgeLabel;
|
||||
@end
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@@ -28,23 +28,34 @@
|
||||
@property (nonatomic,strong)QXDayTaskModel *model;
|
||||
@property (nonatomic,strong)QXDayTaskTypeModel *typeModel;
|
||||
@property (nonatomic,strong)UIImageView *nodataView;
|
||||
|
||||
@property (nonatomic,assign)NSInteger selectedInex;
|
||||
@end
|
||||
|
||||
@implementation QXTaskViewController
|
||||
|
||||
- (void)viewDidLoad {
|
||||
self.isNoChangeBgImage = YES;
|
||||
[super viewDidLoad];
|
||||
// Do any additional setup after loading the view.
|
||||
self.selectedInex = 0;
|
||||
}
|
||||
-(void)viewWillAppear:(BOOL)animated{
|
||||
[super viewWillAppear:animated];
|
||||
[self.navigationController setNavigationBarHidden:NO animated:YES];
|
||||
self.navigationController.navigationBar.titleTextAttributes = @{NSForegroundColorAttributeName:RGB16(0xffffff)};
|
||||
[self getDayTask];
|
||||
|
||||
}
|
||||
-(void)viewWillDisappear:(BOOL)animated{
|
||||
[super viewWillDisappear:animated];
|
||||
self.navigationController.navigationBar.titleTextAttributes = @{NSForegroundColorAttributeName:RGB16(0x000000)};
|
||||
}
|
||||
|
||||
-(void)setNavgationItems{
|
||||
[super setNavgationItems];
|
||||
self.navigationItem.title = QXText(@"每日任务");
|
||||
self.navigationTintColor = RGB16(0xffffff);
|
||||
UIButton*recordBtn = [[UIButton alloc] initWithFrame:CGRectMake(0, 0, 44, 44)];
|
||||
[recordBtn setTitle:QXText(@"礼盒记录") forState:(UIControlStateNormal)];
|
||||
[recordBtn setTitleColor:QXConfig.themeColor forState:(UIControlStateNormal)];
|
||||
@@ -53,11 +64,11 @@
|
||||
self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithCustomView:recordBtn];
|
||||
}
|
||||
- (void)initSubViews{
|
||||
self.bgImageHidden = YES;
|
||||
[self updateBgImage:@"app_home_bg"];
|
||||
self.view.backgroundColor = RGB16(0xE3FAE4);
|
||||
[self.view addSubview:self.topView];
|
||||
self.bottomView = [[UIView alloc] initWithFrame:CGRectMake(16, self.topView.bottom, SCREEN_WIDTH-32, SCREEN_HEIGHT-self.topView.bottom-kSafeAreaBottom)];
|
||||
self.bottomView.backgroundColor = RGB16(0xffffff);
|
||||
self.bottomView.backgroundColor = [UIColor clearColor];
|
||||
[self.bottomView addRoundedCornersWithRadius:16];
|
||||
self.tableView.frame = CGRectMake(0, 48, self.bottomView.width, self.bottomView.height-48);
|
||||
[self.bottomView addSubview:self.tableView];
|
||||
@@ -87,15 +98,16 @@
|
||||
make.right.mas_equalTo(0);
|
||||
make.height.mas_equalTo(48);
|
||||
}];
|
||||
|
||||
|
||||
}
|
||||
-(void)getDayTask{
|
||||
MJWeakSelf
|
||||
[QXMineNetwork getDayTaskListSuccessBlock:^(QXDayTaskModel * _Nonnull model) {
|
||||
// for (QXDayTaskTypeModel*md in model.tasks) {
|
||||
// [self sortStudentsByScoreRule:md];
|
||||
// }
|
||||
weakSelf.model = model;
|
||||
weakSelf.topView.model = model;
|
||||
weakSelf.typeModel = model.tasks.firstObject;
|
||||
weakSelf.typeModel = model.tasks[weakSelf.selectedInex];
|
||||
if (weakSelf.typeModel) {
|
||||
weakSelf.typeModel.isSelected = YES;
|
||||
[weakSelf.dataArray removeAllObjects];
|
||||
@@ -107,6 +119,37 @@
|
||||
|
||||
}];
|
||||
}
|
||||
//- (void)sortStudentsByScoreRule:(QXDayTaskTypeModel*)typeModel {
|
||||
// if (typeModel.task_list.count == 0) return;
|
||||
// __block NSInteger count = 0;
|
||||
//// wait_draw_num
|
||||
// // 自定义排序逻辑:2 > 1 > 3
|
||||
// NSArray *array = [typeModel.task_list sortedArrayUsingComparator:^NSComparisonResult(QXDayTaskListModel *obj1, QXDayTaskListModel *obj2) {
|
||||
// // 定义优先级:2(高) > 1(中) > 3(低)
|
||||
// NSInteger priority1 = [self priorityForScore:obj1.task_status.intValue];
|
||||
// NSInteger priority2 = [self priorityForScore:obj1.task_status.intValue];
|
||||
// count++;
|
||||
// if (priority1 > priority2) {
|
||||
// return NSOrderedAscending; // obj1排在前面
|
||||
// } else if (priority1 < priority2) {
|
||||
// return NSOrderedDescending; // obj2排在前面
|
||||
// } else {
|
||||
// // 成绩相同,可以按其他条件排序(可选)
|
||||
// return NSOrderedSame;
|
||||
// }
|
||||
// }];
|
||||
// typeModel.task_list = array;
|
||||
// typeModel.wait_draw_num = count;
|
||||
//}
|
||||
//- (NSInteger)priorityForScore:(NSInteger)score {
|
||||
// // 优先级映射:2(最高) -> 3, 1(中等) -> 2, 3(最低) -> 1
|
||||
// switch (score) {
|
||||
// case 2: return 3; // 最高优先级
|
||||
// case 1: return 2; // 中等优先级
|
||||
// case 3: return 1; // 最低优先级
|
||||
// default: return 0; // 异常情况
|
||||
// }
|
||||
//}
|
||||
|
||||
-(void)recordAction{
|
||||
QXTaskGiftRecordVC *vc = [[QXTaskGiftRecordVC alloc] init];
|
||||
@@ -215,6 +258,7 @@
|
||||
if (model == self.typeModel) {
|
||||
return;
|
||||
}
|
||||
self.selectedInex = indexPath.row;
|
||||
if (self.typeModel) {
|
||||
self.typeModel.isSelected = NO;
|
||||
}
|
||||
@@ -312,6 +356,11 @@
|
||||
self.titleBtn.selected = NO;
|
||||
self.lockImageBtn.selected = NO;
|
||||
}
|
||||
if (model.wait_reward_num>0) {
|
||||
self.badgeLabel.hidden = NO;
|
||||
}else{
|
||||
self.badgeLabel.hidden = YES;
|
||||
}
|
||||
}
|
||||
-(void)initSubviews{
|
||||
|
||||
@@ -327,8 +376,8 @@
|
||||
self.lockImageBtn.userInteractionEnabled = NO;
|
||||
|
||||
self.titleBtn = [[UIButton alloc] init];
|
||||
[self.titleBtn setTitleColor:RGB16(0x333333) forState:(UIControlStateSelected)];
|
||||
[self.titleBtn setTitleColor:RGB16A(0x000000,0.45) forState:(UIControlStateNormal)];
|
||||
[self.titleBtn setTitleColor:RGB16A(0xffffff,0.4) forState:(UIControlStateNormal)];
|
||||
[self.titleBtn setTitleColor:RGB16(0xffffff) forState:(UIControlStateSelected)];
|
||||
self.titleBtn.titleLabel.font = [UIFont boldSystemFontOfSize:16];
|
||||
[self addSubview:self.titleBtn];
|
||||
[self.titleBtn mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
@@ -336,6 +385,17 @@
|
||||
make.right.equalTo(self.lockImageBtn.mas_left);
|
||||
}];
|
||||
self.titleBtn.userInteractionEnabled = NO;
|
||||
|
||||
self.badgeLabel = [[UILabel alloc] init];
|
||||
self.badgeLabel.hidden = YES;
|
||||
self.badgeLabel.backgroundColor = RGB16(0xE36C4A);
|
||||
[self.badgeLabel addRoundedCornersWithRadius:4];
|
||||
[self addSubview:self.badgeLabel];
|
||||
[self.badgeLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.right.equalTo(self.titleBtn);
|
||||
make.top.mas_equalTo(12);
|
||||
make.width.height.mas_equalTo(8);
|
||||
}];
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@interface QXBindMobileViewController : QXBaseViewController
|
||||
|
||||
@property (nonatomic,assign)BOOL haveMobile;
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@@ -11,9 +11,12 @@
|
||||
#import "QXLoginNetwork.h"
|
||||
|
||||
@interface QXBindMobileViewController ()<QXLoginTextFieldDelegate>
|
||||
@property (nonatomic,strong)UILabel *mobileLabel;
|
||||
@property (nonatomic,strong)QXLoginTextField *oldMobileCodeTextField;
|
||||
@property (nonatomic,strong)QXLoginTextField *accountTextField;
|
||||
@property (nonatomic,strong)QXLoginTextField *codeTextField;
|
||||
@property (nonatomic,strong)UIButton *commitBtn;
|
||||
@property (nonatomic,assign)BOOL isNetworking;
|
||||
@end
|
||||
|
||||
@implementation QXBindMobileViewController
|
||||
@@ -27,46 +30,113 @@
|
||||
self.navigationItem.title = QXText(@"手机绑定");
|
||||
}
|
||||
-(void)initSubViews{
|
||||
self.accountTextField = [[QXLoginTextField alloc] initWithFrame:CGRectMake(16, NavContentHeight+12, SCREEN_WIDTH-32, 44) type:(LoginTextTypeAccount)];
|
||||
self.accountTextField.backgroundColor = RGB16(0xEFF2F8);
|
||||
[self.accountTextField addRoundedCornersWithRadius:11];
|
||||
[self.view addSubview:self.accountTextField];
|
||||
|
||||
self.codeTextField = [[QXLoginTextField alloc] initWithFrame:CGRectMake(16, self.accountTextField.bottom+12, SCREEN_WIDTH-32, 44) type:(LoginTextTypeCode)];
|
||||
self.codeTextField.backgroundColor = RGB16(0xEFF2F8);
|
||||
[self.codeTextField addRoundedCornersWithRadius:11];
|
||||
self.codeTextField.delegate = self;
|
||||
[self.view addSubview:self.codeTextField];
|
||||
|
||||
self.commitBtn = [[UIButton alloc] initWithFrame:CGRectMake(38, self.codeTextField.bottom+16, SCREEN_WIDTH-38*2, 42)];
|
||||
self.commitBtn.needEventInterval = 1;
|
||||
[self.commitBtn setTitle:QXText(@"立即绑定") forState:(UIControlStateNormal)];
|
||||
[self.commitBtn setTitleColor:QXConfig.btnTextColor forState:(UIControlStateNormal)];
|
||||
[self.commitBtn addTarget:self action:@selector(commitAction) forControlEvents:(UIControlEventTouchUpInside)];
|
||||
[self.commitBtn addRoundedCornersWithRadius:21];
|
||||
self.commitBtn.titleLabel.font = [UIFont systemFontOfSize:14];
|
||||
self.commitBtn.backgroundColor = QXConfig.themeColor;
|
||||
[self.view addSubview:self.commitBtn];
|
||||
if (self.haveMobile) {
|
||||
self.mobileLabel = [[UILabel alloc] initWithFrame:CGRectMake(16, NavContentHeight+17, SCREEN_WIDTH-32, 18)];
|
||||
self.mobileLabel.textColor = RGB16(0x999999);
|
||||
self.mobileLabel.font = [UIFont systemFontOfSize:12];
|
||||
NSString *pMobile = [QXGlobal.shareGlobal.loginModel.mobile stringByReplacingCharactersInRange:NSMakeRange(3, 4) withString:@"****"];
|
||||
NSString *mobile = [NSString stringWithFormat:@"当前手机号 %@",pMobile];
|
||||
NSMutableAttributedString *attr = [[NSMutableAttributedString alloc] initWithString:mobile];
|
||||
[attr yy_setFont:[UIFont boldSystemFontOfSize:16] range:[mobile rangeOfString:pMobile]];
|
||||
[attr yy_setColor:RGB16(0x333333) range:[mobile rangeOfString:pMobile]];
|
||||
self.mobileLabel.attributedText = attr;
|
||||
[self.view addSubview:self.mobileLabel];
|
||||
|
||||
self.oldMobileCodeTextField = [[QXLoginTextField alloc] initWithFrame:CGRectMake(16, self.mobileLabel.bottom+12, SCREEN_WIDTH-32, 44) type:(LoginTextTypeCode)];
|
||||
self.oldMobileCodeTextField.backgroundColor = RGB16(0xEFF2F8);
|
||||
self.oldMobileCodeTextField.textField.placeholder = @"请输入旧手机号验证码";
|
||||
[self.oldMobileCodeTextField addRoundedCornersWithRadius:11];
|
||||
self.oldMobileCodeTextField.delegate = self;
|
||||
[self.view addSubview:self.oldMobileCodeTextField];
|
||||
|
||||
|
||||
self.accountTextField = [[QXLoginTextField alloc] initWithFrame:CGRectMake(16, self.oldMobileCodeTextField.bottom+12, SCREEN_WIDTH-32, 44) type:(LoginTextTypeAccount)];
|
||||
self.accountTextField.backgroundColor = RGB16(0xEFF2F8);
|
||||
[self.accountTextField addRoundedCornersWithRadius:11];
|
||||
self.codeTextField.textField.placeholder = @"请输入新手机号";
|
||||
[self.view addSubview:self.accountTextField];
|
||||
|
||||
self.codeTextField = [[QXLoginTextField alloc] initWithFrame:CGRectMake(16, self.accountTextField.bottom+12, SCREEN_WIDTH-32, 44) type:(LoginTextTypeCode)];
|
||||
self.codeTextField.backgroundColor = RGB16(0xEFF2F8);
|
||||
[self.codeTextField addRoundedCornersWithRadius:11];
|
||||
self.codeTextField.delegate = self;
|
||||
self.codeTextField.textField.placeholder = @"请输入新手机号验证码";
|
||||
[self.view addSubview:self.codeTextField];
|
||||
|
||||
self.commitBtn = [[UIButton alloc] initWithFrame:CGRectMake(38, self.codeTextField.bottom+16, SCREEN_WIDTH-38*2, 42)];
|
||||
self.commitBtn.needEventInterval = 1;
|
||||
[self.commitBtn setTitle:QXText(@"立即绑定") forState:(UIControlStateNormal)];
|
||||
[self.commitBtn setTitleColor:QXConfig.btnTextColor forState:(UIControlStateNormal)];
|
||||
[self.commitBtn addTarget:self action:@selector(commitAction) forControlEvents:(UIControlEventTouchUpInside)];
|
||||
[self.commitBtn addRoundedCornersWithRadius:21];
|
||||
self.commitBtn.titleLabel.font = [UIFont systemFontOfSize:14];
|
||||
self.commitBtn.backgroundColor = QXConfig.themeColor;
|
||||
[self.view addSubview:self.commitBtn];
|
||||
}else{
|
||||
|
||||
self.accountTextField = [[QXLoginTextField alloc] initWithFrame:CGRectMake(16, NavContentHeight+12, SCREEN_WIDTH-32, 44) type:(LoginTextTypeAccount)];
|
||||
self.accountTextField.backgroundColor = RGB16(0xEFF2F8);
|
||||
[self.accountTextField addRoundedCornersWithRadius:11];
|
||||
[self.view addSubview:self.accountTextField];
|
||||
|
||||
self.codeTextField = [[QXLoginTextField alloc] initWithFrame:CGRectMake(16, self.accountTextField.bottom+12, SCREEN_WIDTH-32, 44) type:(LoginTextTypeCode)];
|
||||
self.codeTextField.backgroundColor = RGB16(0xEFF2F8);
|
||||
[self.codeTextField addRoundedCornersWithRadius:11];
|
||||
self.codeTextField.delegate = self;
|
||||
[self.view addSubview:self.codeTextField];
|
||||
|
||||
self.commitBtn = [[UIButton alloc] initWithFrame:CGRectMake(38, self.codeTextField.bottom+16, SCREEN_WIDTH-38*2, 42)];
|
||||
self.commitBtn.needEventInterval = 1;
|
||||
[self.commitBtn setTitle:QXText(@"立即绑定") forState:(UIControlStateNormal)];
|
||||
[self.commitBtn setTitleColor:QXConfig.btnTextColor forState:(UIControlStateNormal)];
|
||||
[self.commitBtn addTarget:self action:@selector(commitAction) forControlEvents:(UIControlEventTouchUpInside)];
|
||||
[self.commitBtn addRoundedCornersWithRadius:21];
|
||||
self.commitBtn.titleLabel.font = [UIFont systemFontOfSize:14];
|
||||
self.commitBtn.backgroundColor = QXConfig.themeColor;
|
||||
[self.view addSubview:self.commitBtn];
|
||||
}
|
||||
}
|
||||
-(void)didClickSendCode:(UIButton *)sender{
|
||||
if (self.accountTextField.textField.text.length < 11) {
|
||||
showToast(QXText(@"请输入正确的手机号码"));
|
||||
return;
|
||||
if (sender == self.codeTextField.codeBtn) {
|
||||
sender.userInteractionEnabled = NO;
|
||||
if (self.accountTextField.textField.text.length < 11) {
|
||||
showToast(QXText(@"请输入正确的手机号码"));
|
||||
return;
|
||||
}
|
||||
if ([self.accountTextField.textField.text isEqualToString:QXGlobal.shareGlobal.loginModel.mobile]) {
|
||||
showToast(QXText(@"新手机号不能与旧手机号相同"));
|
||||
return;
|
||||
}
|
||||
GetSmscodeType type = GetSmscodeTypeFindChangeMobile;
|
||||
MJWeakSelf
|
||||
self.isNetworking = YES;
|
||||
[QXLoginNetwork getSmscodeWithMobile:self.accountTextField.textField.text
|
||||
type:type
|
||||
successBlock:^(id _Nonnull responseObject) {
|
||||
[weakSelf.codeTextField startTimeDown];
|
||||
sender.userInteractionEnabled = YES;
|
||||
}
|
||||
failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||
showToast(msg);
|
||||
sender.userInteractionEnabled = YES;
|
||||
}];
|
||||
}else{
|
||||
GetSmscodeType type = GetSmscodeTypeFindChangeMobile;
|
||||
NSString *oldMobile = [QXGlobal shareGlobal].loginModel.mobile;
|
||||
MJWeakSelf
|
||||
sender.userInteractionEnabled = NO;
|
||||
[QXLoginNetwork getSmscodeWithMobile:oldMobile
|
||||
type:type
|
||||
successBlock:^(id _Nonnull responseObject) {
|
||||
[weakSelf.oldMobileCodeTextField startTimeDown];
|
||||
sender.userInteractionEnabled = YES;
|
||||
}
|
||||
failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||
showToast(msg);
|
||||
sender.userInteractionEnabled = YES;
|
||||
}];
|
||||
}
|
||||
GetSmscodeType type = GetSmscodeTypeFindBindMobile;
|
||||
NSString *oldMobile = [QXGlobal shareGlobal].loginModel.mobile;
|
||||
if (oldMobile.length > 0) {
|
||||
type = GetSmscodeTypeFindChangeMobile;
|
||||
}
|
||||
MJWeakSelf
|
||||
[QXLoginNetwork getSmscodeWithMobile:self.accountTextField.textField.text
|
||||
type:type
|
||||
successBlock:^(id _Nonnull responseObject) {
|
||||
[weakSelf.codeTextField startTimeDown];
|
||||
}
|
||||
failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||
|
||||
}];
|
||||
|
||||
}
|
||||
-(void)commitAction{
|
||||
NSString *oldMobile = [QXGlobal shareGlobal].loginModel.mobile;
|
||||
@@ -79,7 +149,7 @@
|
||||
showToast(QXText(@"绑定成功"));
|
||||
[QXGlobal shareGlobal].loginModel.mobile = mobile;
|
||||
[[QXGlobal shareGlobal]updateUserInfoWithMolde:[QXGlobal shareGlobal].loginModel];
|
||||
[self.navigationController popViewControllerAnimated:YES];
|
||||
[self.navigationController popToRootViewControllerAnimated:YES];
|
||||
}
|
||||
failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||
showToast(msg)
|
||||
|
||||
16
QXLive/Mine(音域)/Controller/设置/QXModifyMobileViewController.h
Normal file
16
QXLive/Mine(音域)/Controller/设置/QXModifyMobileViewController.h
Normal file
@@ -0,0 +1,16 @@
|
||||
//
|
||||
// QXModifyMobileViewController.h
|
||||
// QXLive
|
||||
//
|
||||
// Created by 启星 on 2025/12/19.
|
||||
//
|
||||
|
||||
#import "QXBaseViewController.h"
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@interface QXModifyMobileViewController : QXBaseViewController
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
87
QXLive/Mine(音域)/Controller/设置/QXModifyMobileViewController.m
Normal file
87
QXLive/Mine(音域)/Controller/设置/QXModifyMobileViewController.m
Normal file
@@ -0,0 +1,87 @@
|
||||
//
|
||||
// QXModifyMobileViewController.m
|
||||
// QXLive
|
||||
//
|
||||
// Created by 启星 on 2025/12/19.
|
||||
//
|
||||
|
||||
#import "QXModifyMobileViewController.h"
|
||||
#import "QXBindMobileViewController.h"
|
||||
@interface QXModifyMobileViewController ()
|
||||
@property (nonatomic,strong)UIImageView *topImageView;
|
||||
@property (nonatomic,strong)UILabel *titleLabel;
|
||||
@property (nonatomic,strong)UILabel *mobileLabel;
|
||||
@property (nonatomic,strong)UIButton *changeBtn;
|
||||
@end
|
||||
|
||||
@implementation QXModifyMobileViewController
|
||||
|
||||
- (void)viewDidLoad {
|
||||
[super viewDidLoad];
|
||||
// Do any additional setup after loading the view.
|
||||
}
|
||||
-(void)setNavgationItems{
|
||||
[super setNavgationItems];
|
||||
self.navigationItem.title = @"更换手机号码";
|
||||
}
|
||||
-(void)initSubViews{
|
||||
self.topImageView = [[UIImageView alloc] initWithImage:[UIImage imageNamed:@"change_mobile_top"]];
|
||||
[self.view addSubview:self.topImageView];
|
||||
[self.topImageView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.width.height.mas_equalTo(ScaleWidth(150));
|
||||
make.top.mas_equalTo(NavContentHeight);
|
||||
make.centerX.equalTo(self.view);
|
||||
}];
|
||||
|
||||
self.titleLabel = [[UILabel alloc] init];
|
||||
self.titleLabel.textColor = RGB16(0x666666);
|
||||
self.titleLabel.font = [UIFont systemFontOfSize:14];
|
||||
self.titleLabel.text = @"更换手机号码以后,个人信息不变";
|
||||
[self.view addSubview:self.titleLabel];
|
||||
[self.titleLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.centerX.equalTo(self.view);
|
||||
make.top.equalTo(self.topImageView.mas_bottom).offset(8);
|
||||
make.height.mas_equalTo(21);
|
||||
}];
|
||||
|
||||
|
||||
self.mobileLabel = [[UILabel alloc] init];
|
||||
self.mobileLabel.textColor = RGB16(0x999999);
|
||||
self.mobileLabel.font = [UIFont systemFontOfSize:12];
|
||||
NSString *pMobile = [QXGlobal.shareGlobal.loginModel.mobile stringByReplacingCharactersInRange:NSMakeRange(3, 4) withString:@"****"];
|
||||
NSString *mobile = [NSString stringWithFormat:@"当前手机号 %@",pMobile];
|
||||
NSMutableAttributedString *attr = [[NSMutableAttributedString alloc] initWithString:mobile];
|
||||
[attr yy_setFont:[UIFont boldSystemFontOfSize:17] range:[mobile rangeOfString:pMobile]];
|
||||
[attr yy_setColor:RGB16(0x333333) range:[mobile rangeOfString:pMobile]];
|
||||
self.mobileLabel.attributedText = attr;
|
||||
[self.view addSubview:self.mobileLabel];
|
||||
[self.mobileLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.centerX.equalTo(self.view);
|
||||
make.top.equalTo(self.titleLabel.mas_bottom).offset(8);
|
||||
make.height.mas_equalTo(28);
|
||||
}];
|
||||
|
||||
self.changeBtn = [[UIButton alloc] init];
|
||||
[self.changeBtn setTitle:@"更换手机号码" forState:(UIControlStateNormal)];
|
||||
[self.changeBtn setTitleColor:QXConfig.btnTextColor forState:(UIControlStateNormal)];
|
||||
[self.changeBtn addTarget:self action:@selector(changeAction) forControlEvents:(UIControlEventTouchUpInside)];
|
||||
[self.changeBtn addRoundedCornersWithRadius:21];
|
||||
self.changeBtn.titleLabel.font = [UIFont systemFontOfSize:14];
|
||||
self.changeBtn.backgroundColor = QXConfig.themeColor;
|
||||
[self.view addSubview:self.changeBtn];
|
||||
[self.changeBtn mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.centerX.equalTo(self.view);
|
||||
make.top.equalTo(self.mobileLabel.mas_bottom).offset(30);
|
||||
make.height.mas_equalTo(42);
|
||||
make.width.mas_equalTo(ScaleWidth(300));
|
||||
}];
|
||||
}
|
||||
|
||||
|
||||
|
||||
-(void)changeAction{
|
||||
QXBindMobileViewController *vc = [[QXBindMobileViewController alloc] init];
|
||||
vc.haveMobile = YES;
|
||||
[self.navigationController pushViewController:vc animated:YES];
|
||||
}
|
||||
@end
|
||||
@@ -17,6 +17,7 @@
|
||||
@property (nonatomic,strong)QXLoginTextField *pwdTextField;
|
||||
@property (nonatomic,strong)QXLoginTextField *repwdTextField;
|
||||
@property (nonatomic,strong)UIButton *commitBtn;
|
||||
@property (nonatomic,assign)BOOL isNetworking;
|
||||
@end
|
||||
|
||||
@implementation QXSetPwdViewController
|
||||
@@ -75,13 +76,19 @@
|
||||
|
||||
-(void)didClickSendCode:(UIButton *)sender{
|
||||
MJWeakSelf
|
||||
if (self.isNetworking) {
|
||||
return;
|
||||
}
|
||||
self.isNetworking = YES;
|
||||
[QXLoginNetwork getSmscodeWithMobile:[QXGlobal shareGlobal].loginModel.mobile
|
||||
type:GetSmscodeTypeSetPassword
|
||||
successBlock:^(id _Nonnull responseObject) {
|
||||
[weakSelf.codeTextField startTimeDown];
|
||||
weakSelf.isNetworking = NO;
|
||||
}
|
||||
failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||
|
||||
weakSelf.isNetworking = NO;
|
||||
showToast(msg)
|
||||
}];
|
||||
}
|
||||
-(void)commitAction{
|
||||
|
||||
@@ -12,6 +12,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
@interface QXSettingViewController : QXBaseViewController
|
||||
@property (nonatomic,copy)void(^logOutBlock)(BOOL isCancel,NSString*code);
|
||||
@property (nonatomic,assign)BOOL haveNobility;
|
||||
@property (nonatomic,assign)BOOL haveMobile;
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
#import "QXAlertView.h"
|
||||
#import "QXReVerificationPopView.h"
|
||||
#import "QXTimer.h"
|
||||
#import "QXModifyMobileViewController.h"
|
||||
static NSInteger maxClickCount = 6;
|
||||
@interface QXSettingViewController ()<UITableViewDelegate,UITableViewDataSource>
|
||||
@property (nonatomic,strong)UITableView *tableView;
|
||||
@@ -44,18 +45,20 @@ static NSInteger maxClickCount = 6;
|
||||
QXText(@"隐身进入房间"),
|
||||
QXText(@"黑名单"),
|
||||
QXText(@"设置密码"),
|
||||
QXText(@"手机绑定"),
|
||||
self.haveMobile?QXText(@"手机换绑"):QXText(@"手机绑定"),
|
||||
QXText(@"关于我们"),
|
||||
QXText(@"版本号")
|
||||
QXText(@"版本号"),
|
||||
@"上传日志"
|
||||
];
|
||||
}else{
|
||||
section1 = @[
|
||||
// QXText(@"消息通知"),
|
||||
QXText(@"黑名单"),
|
||||
QXText(@"设置密码"),
|
||||
QXText(@"手机绑定"),
|
||||
self.haveMobile?QXText(@"手机换绑"):QXText(@"手机绑定"),
|
||||
QXText(@"关于我们"),
|
||||
QXText(@"版本号")
|
||||
QXText(@"版本号"),
|
||||
@"上传日志"
|
||||
];
|
||||
}
|
||||
|
||||
@@ -72,6 +75,7 @@ static NSInteger maxClickCount = 6;
|
||||
QXText(@"黑名单"):[NSNumber numberWithInteger:QXSettingCellTypeOnlyArrow],
|
||||
QXText(@"设置密码"):[NSNumber numberWithInteger:QXSettingCellTypeOnlyArrow],
|
||||
QXText(@"手机绑定"):[NSNumber numberWithInteger:QXSettingCellTypeOnlyArrow],
|
||||
QXText(@"手机换绑"):[NSNumber numberWithInteger:QXSettingCellTypeOnlyArrow],
|
||||
QXText(@"版本号"):[NSNumber numberWithInteger:QXSettingCellTypeOnlyDetail],
|
||||
QXText(@"切换账号"):[NSNumber numberWithInteger:QXSettingCellTypeOnlyArrow],
|
||||
QXText(@"实名认证"):[NSNumber numberWithInteger:QXSettingCellTypeNormal],
|
||||
@@ -86,6 +90,7 @@ static NSInteger maxClickCount = 6;
|
||||
QXText(@"黑名单"):@"QXBlackListlViewController",
|
||||
QXText(@"设置密码"):@"QXSetPwdViewController",
|
||||
QXText(@"手机绑定"):@"QXBindMobileViewController",
|
||||
QXText(@"手机换绑"):@"QXModifyMobileViewController",
|
||||
QXText(@"版本号"):@"",
|
||||
QXText(@"切换账号"):@"QXChangeAccountViewController",
|
||||
QXText(@"实名认证"):[QXGlobal shareGlobal].isRealName?@"QXRealNameFinishedViewController":@"QXRealNameViewController",
|
||||
@@ -100,6 +105,7 @@ static NSInteger maxClickCount = 6;
|
||||
QXText(@"黑名单"):@"",
|
||||
QXText(@"设置密码"):@"",
|
||||
QXText(@"手机绑定"):@"",
|
||||
QXText(@"手机换绑"):@"",
|
||||
QXText(@"版本号"):appVersion,
|
||||
QXText(@"切换账号"):@"",
|
||||
QXText(@"实名认证"):@"",
|
||||
@@ -174,9 +180,29 @@ static NSInteger maxClickCount = 6;
|
||||
}else{
|
||||
self.clickCount = 0;
|
||||
}
|
||||
|
||||
if ([text isEqualToString:@"上传日志"]) {
|
||||
__weak typeof(self)weakSelf = self;
|
||||
showLoadingInView(self.view);
|
||||
NSString *path = [QXLogger getLatestLogFilePath];
|
||||
NSString *fileName = [path lastPathComponent];
|
||||
if (![fileName isExist]) {
|
||||
fileName = @"ios_log";
|
||||
}
|
||||
NSURL *filePath = [NSURL fileURLWithPath:path];
|
||||
[[QXCOSUploadManager shareManager] uploadFile:filePath withObjectKey:fileName path:LOG_FILE_BASE_PATH complete:^(NSString * _Nonnull fileUrl, QXCOSUploadImageState state) {
|
||||
dispatch_async(dispatch_get_main_queue(), ^{
|
||||
hideLoadingInView(weakSelf.view);
|
||||
});
|
||||
[QXMineNetwork appLogReportWithLogName:fileName log_url:fileUrl successBlock:^(NSString * _Nonnull status) {
|
||||
|
||||
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||
|
||||
}];
|
||||
}];
|
||||
|
||||
return;
|
||||
}
|
||||
if ([text isEqualToString:QXText(@"账号注销")]) {
|
||||
UIView *view;
|
||||
if ([QXGlobal.shareGlobal.loginModel.mobile isExist]) {
|
||||
[[QXGlobal shareGlobal] showView:self.codeAlertView controller:self popType:(PopViewTypeTopToCenter) tapDismiss:NO finishBlock:^{
|
||||
|
||||
|
||||
@@ -54,7 +54,8 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
///1 锁 0 开
|
||||
@property(nonatomic,strong)NSString *is_lock;
|
||||
@property(nonatomic,strong)NSArray<QXDayTaskListModel*>*task_list;
|
||||
|
||||
/// 待领取数量
|
||||
@property(nonatomic,assign)NSInteger wait_reward_num;
|
||||
@property(nonatomic,assign)BOOL isSelected;
|
||||
@end
|
||||
|
||||
|
||||
@@ -36,6 +36,8 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
/// 是否为cp礼物 0 打开 1 锁住
|
||||
@property (nonatomic,strong)NSString *is_cp;
|
||||
|
||||
@property (nonatomic,strong)NSString *icon;
|
||||
|
||||
/// 是否为师徒标签
|
||||
@property (nonatomic,strong)NSString *is_teacher;
|
||||
|
||||
|
||||
21
QXLive/Mine(音域)/Model/QXRoomActivityStatusModel.h
Normal file
21
QXLive/Mine(音域)/Model/QXRoomActivityStatusModel.h
Normal file
@@ -0,0 +1,21 @@
|
||||
//
|
||||
// QXRoomActivityStatusModel.h
|
||||
// QXLive
|
||||
//
|
||||
// Created by 启星 on 2025/12/21.
|
||||
//
|
||||
|
||||
#import <Foundation/Foundation.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@interface QXRoomActivityStatusModel : NSObject
|
||||
@property (nonatomic,strong)NSString *gift_bag_id;
|
||||
@property (nonatomic,strong)NSString *name;
|
||||
/// 活动状态 0 未开启 1 已开启
|
||||
@property (nonatomic,strong)NSString *status;
|
||||
@property (nonatomic,strong)NSString *status_str;
|
||||
@property (nonatomic,strong)NSString *icon;
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
12
QXLive/Mine(音域)/Model/QXRoomActivityStatusModel.m
Normal file
12
QXLive/Mine(音域)/Model/QXRoomActivityStatusModel.m
Normal file
@@ -0,0 +1,12 @@
|
||||
//
|
||||
// QXRoomActivityStatusModel.m
|
||||
// QXLive
|
||||
//
|
||||
// Created by 启星 on 2025/12/21.
|
||||
//
|
||||
|
||||
#import "QXRoomActivityStatusModel.h"
|
||||
|
||||
@implementation QXRoomActivityStatusModel
|
||||
|
||||
@end
|
||||
@@ -54,6 +54,8 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
@property (nonatomic,strong)NSArray<QXUserHomeModel*>*user_list;
|
||||
/// 火热值
|
||||
@property (nonatomic,strong)NSString*hot_value;
|
||||
|
||||
@property (nonatomic,strong)NSString*lucky_water;
|
||||
@end
|
||||
|
||||
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
#import "QXUserSongListModel.h"
|
||||
#import "QXRoomBestFriendModel.h"
|
||||
#import "QXFamilyModel.h"
|
||||
#import "QXRoomActivityStatusModel.h"
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@@ -291,6 +292,15 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
successBlock:(void (^)(NSArray<QXMyRoomHistory*>* list))successBlock
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock;
|
||||
|
||||
/**
|
||||
进入房间前监测
|
||||
*/
|
||||
+(void)beforeJoinRoomWithRoomId:(NSString *)room_id
|
||||
successBlock:(void (^)(NSDictionary* dict))successBlock
|
||||
roomErrorBlock:(void (^)(NSString * roomId, NSString * msg))roomErrorBlock
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock;
|
||||
|
||||
|
||||
/**
|
||||
进入房间
|
||||
*/
|
||||
@@ -1438,7 +1448,19 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
+(void)appTaskWaitDrawSuccessBlock:(void (^)(NSString* num))successBlock
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock;
|
||||
|
||||
/**
|
||||
每日任务未领取数量
|
||||
*/
|
||||
+(void)appLogReportWithLogName:(NSString*)log_name
|
||||
log_url:(NSString*)log_url
|
||||
successBlock:(void (^)(NSString* status))successBlock
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock;
|
||||
|
||||
/**
|
||||
获取房间活动状态
|
||||
*/
|
||||
+(void)getRoomActivityStatusSuccessBlock:(void (^)(NSArray<QXRoomActivityStatusModel*>* list))successBlock
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock;
|
||||
@end
|
||||
|
||||
|
||||
|
||||
@@ -588,6 +588,32 @@
|
||||
failBlock(error,msg);
|
||||
}];
|
||||
}
|
||||
+(void)beforeJoinRoomWithRoomId:(NSString *)room_id
|
||||
successBlock:(void (^)(NSDictionary* dict))successBlock
|
||||
roomErrorBlock:(void (^)(NSString * roomId, NSString * msg))roomErrorBlock
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock{
|
||||
[[QXRequset shareInstance] postWithUrl:QXBeforeJoinRoom parameters:@{@"room_id":room_id} needCache:NO success:^(id responseObject) {
|
||||
int code = [responseObject[@"code"] intValue];
|
||||
if(code == 202){
|
||||
id object = responseObject[@"data"];
|
||||
NSString *roomId = @"";
|
||||
NSString*content = @"";
|
||||
if ([object isKindOfClass:[NSDictionary class]]) {
|
||||
roomId = [NSString stringWithFormat:@"%@",object[@"room_id"]];
|
||||
content = [NSString stringWithFormat:@"%@",object[@"msg"]];
|
||||
}
|
||||
if (roomErrorBlock) {
|
||||
roomErrorBlock(roomId,content);
|
||||
}
|
||||
}else{
|
||||
if (successBlock) {
|
||||
successBlock(responseObject[@"data"]);
|
||||
}
|
||||
}
|
||||
} fail:^(NSError *error, NSString *msg, NSURLSessionDataTask *task) {
|
||||
failBlock(error,msg);
|
||||
}];
|
||||
}
|
||||
|
||||
+(void)joinRoomWithRoomId:(NSString *)room_id successBlock:(nonnull void (^)(QXRoomModel * _Nonnull))successBlock roomErrorBlock:(nonnull void (^)(NSString * _Nonnull, NSString * _Nonnull))roomErrorBlock failBlock:(nonnull void (^)(NSError * _Nonnull, NSString * _Nonnull))failBlock{
|
||||
NSDictionary *parameters =@{
|
||||
@@ -710,24 +736,25 @@
|
||||
successBlock(responseObject[@"data"]);
|
||||
}
|
||||
// NSDictionary *cp_type = [NSDictionary stringWithFormat:@"%@",responseObject[@"data"][@"cp_type"]];
|
||||
id object = responseObject[@"data"][@"cp_type"];
|
||||
if ([object isKindOfClass:[NSDictionary class]]) {
|
||||
NSDictionary *cpDict = (NSDictionary *)object;
|
||||
NSString *cp_type = [NSString stringWithFormat:@"%@",cpDict[@"cp_type"]];
|
||||
if (cp_type.intValue == 1) {
|
||||
/// 单向送cp礼物
|
||||
NSString *jsonStr = [cpDict jsonStringEncoded];
|
||||
[[QXRoomMessageManager shared] sendC2CMessage:jsonStr messageType:(QXRoomMessageTypeSendAndRecieveCpHeartSignal) userId:userId];
|
||||
}else if (cp_type.intValue == 2){
|
||||
/// cp礼物已达成双向绑定
|
||||
NSString *jsonStr = [cpDict jsonStringEncoded];
|
||||
[[QXRoomMessageManager shared] sendC2CMessage:jsonStr messageType:(QXRoomMessageTypeCpHeartFinished) userId:userId];
|
||||
[[QXRoomMessageManager shared] showCpFinishedAlertViewWithText:[NSString stringWithFormat:@"%@",cpDict[@"text"]]];
|
||||
}else{
|
||||
|
||||
if ([responseObject[@"data"] isKindOfClass:[NSDictionary class]]) {
|
||||
id object = responseObject[@"data"][@"cp_type"];
|
||||
if ([object isKindOfClass:[NSDictionary class]]) {
|
||||
NSDictionary *cpDict = (NSDictionary *)object;
|
||||
NSString *cp_type = [NSString stringWithFormat:@"%@",cpDict[@"cp_type"]];
|
||||
if (cp_type.intValue == 1) {
|
||||
/// 单向送cp礼物
|
||||
NSString *jsonStr = [cpDict jsonStringEncoded];
|
||||
[[QXRoomMessageManager shared] sendC2CMessage:jsonStr messageType:(QXRoomMessageTypeSendAndRecieveCpHeartSignal) userId:userId];
|
||||
}else if (cp_type.intValue == 2){
|
||||
/// cp礼物已达成双向绑定
|
||||
NSString *jsonStr = [cpDict jsonStringEncoded];
|
||||
[[QXRoomMessageManager shared] sendC2CMessage:jsonStr messageType:(QXRoomMessageTypeCpHeartFinished) userId:userId];
|
||||
[[QXRoomMessageManager shared] showCpFinishedAlertViewWithText:[NSString stringWithFormat:@"%@",cpDict[@"text"]]];
|
||||
}else{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
} fail:^(NSError *error, NSString *msg, NSURLSessionDataTask *task) {
|
||||
failBlock(error,msg);
|
||||
}];
|
||||
@@ -2882,7 +2909,7 @@
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock{
|
||||
[[QXRequset shareInstance] getWithUrl:QXAppSignStatus parameters:@{} needCache:NO success:^(id responseObject) {
|
||||
if (successBlock) {
|
||||
NSString *status = [NSString stringWithFormat:@"%@",responseObject[@"data"]];
|
||||
NSString *status = [NSString stringWithFormat:@"%@",responseObject[@"data"][@"status"]];
|
||||
successBlock(status);
|
||||
}
|
||||
} fail:^(NSError *error, NSString *msg, NSURLSessionDataTask *task) {
|
||||
@@ -2904,4 +2931,31 @@
|
||||
failBlock(error,msg);
|
||||
}];
|
||||
}
|
||||
|
||||
|
||||
+(void)appLogReportWithLogName:(NSString *)log_name log_url:(NSString *)log_url successBlock:(void (^)(NSString * _Nonnull))successBlock failBlock:(void (^)(NSError * _Nonnull, NSString * _Nonnull))failBlock{
|
||||
[[QXRequset shareInstance] postWithUrl:QXAppLogReport parameters:@{@"log_name":log_name?:@"",@"log_url":log_url?:@""} needCache:NO success:^(id responseObject) {
|
||||
if (successBlock) {
|
||||
successBlock(responseObject);
|
||||
}
|
||||
} fail:^(NSError *error, NSString *msg, NSURLSessionDataTask *task) {
|
||||
failBlock(error,msg);
|
||||
}];
|
||||
}
|
||||
|
||||
/**
|
||||
获取房间活动状态
|
||||
*/
|
||||
+(void)getRoomActivityStatusSuccessBlock:(void (^)(NSArray<QXRoomActivityStatusModel*>* list))successBlock
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock{
|
||||
[[QXRequset shareInstance] getWithUrl:QXActivityStatus parameters:@{} needCache:NO success:^(id responseObject) {
|
||||
if (successBlock) {
|
||||
NSArray *list = [NSArray yy_modelArrayWithClass:[QXRoomActivityStatusModel class] json:responseObject[@"data"]];
|
||||
successBlock(list);
|
||||
}
|
||||
} fail:^(NSError *error, NSString *msg, NSURLSessionDataTask *task) {
|
||||
failBlock(error,msg);
|
||||
}];
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
@@ -36,6 +36,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
@property (weak, nonatomic) IBOutlet UIButton *roomSubsidyBtn;
|
||||
@property (nonatomic,assign)NSInteger bgImageCount;
|
||||
@property (weak, nonatomic) IBOutlet UIImageView *roomWaitImageView;
|
||||
@property (weak, nonatomic) IBOutlet UILabel *luckyWaterLabel;
|
||||
|
||||
@property (nonatomic,strong)QXRoomListModel *model;
|
||||
/// 0 我创建的 1 我主持的
|
||||
|
||||
@@ -92,10 +92,13 @@
|
||||
NSString *money = [NSString stringWithFormat:@"%.4f",model.today_profit.doubleValue];
|
||||
self.moneyLabel.text = [NSString stringWithFormat:@"%@",money];
|
||||
[self.typeImageView sd_setImageWithURL:[NSURL URLWithString:model.label_icon] placeholderImage:nil];
|
||||
self.luckyWaterLabel.text = model.lucky_water;
|
||||
if (model.apply_status.intValue == 1) {
|
||||
self.roomWaitImageView.hidden = NO;
|
||||
self.luckyWaterLabel.hidden = YES;
|
||||
}else{
|
||||
self.roomWaitImageView.hidden = YES;
|
||||
self.luckyWaterLabel.hidden = NO;
|
||||
}
|
||||
}
|
||||
- (IBAction)roomDetailAction:(id)sender {
|
||||
|
||||
@@ -130,6 +130,12 @@
|
||||
<constraint firstAttribute="width" constant="64" id="sSX-Jv-Huj"/>
|
||||
</constraints>
|
||||
</imageView>
|
||||
<label hidden="YES" opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="幸运流水:0" textAlignment="right" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="2bq-E7-5RX">
|
||||
<rect key="frame" x="460.33333333333331" y="116.66666666666667" width="63.666666666666686" height="16.000000000000014"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="13"/>
|
||||
<color key="textColor" white="0.5" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="sme-1q-gFv">
|
||||
<rect key="frame" x="12" y="109.66666666666667" width="82" height="30.000000000000014"/>
|
||||
<constraints>
|
||||
@@ -161,6 +167,7 @@
|
||||
<constraint firstAttribute="trailing" secondItem="3bm-oL-g9B" secondAttribute="trailing" constant="6" id="FFG-1q-qus"/>
|
||||
<constraint firstItem="N2H-oT-j7d" firstAttribute="leading" secondItem="n8c-Bl-dxD" secondAttribute="trailing" constant="8" symbolic="YES" id="IUg-ec-S0W"/>
|
||||
<constraint firstItem="UEZ-KG-LO0" firstAttribute="leading" secondItem="gwx-5C-Dyi" secondAttribute="trailing" id="KiF-aV-j2i"/>
|
||||
<constraint firstItem="2bq-E7-5RX" firstAttribute="centerY" secondItem="sme-1q-gFv" secondAttribute="centerY" id="KtY-XS-4qD"/>
|
||||
<constraint firstItem="NQD-O5-Mxv" firstAttribute="leading" secondItem="n8c-Bl-dxD" secondAttribute="leading" id="LkZ-It-52D"/>
|
||||
<constraint firstItem="n8c-Bl-dxD" firstAttribute="leading" secondItem="hCx-Bc-lup" secondAttribute="trailing" constant="8" id="Ozs-3q-8HK"/>
|
||||
<constraint firstAttribute="trailing" secondItem="t6e-Ib-pCi" secondAttribute="trailing" id="Q80-US-afM"/>
|
||||
@@ -185,6 +192,7 @@
|
||||
<constraint firstItem="k0N-ev-a0T" firstAttribute="leading" secondItem="kMB-zj-bvu" secondAttribute="leading" constant="12" id="rB0-hW-4Ld"/>
|
||||
<constraint firstAttribute="trailing" secondItem="xiq-z8-B3x" secondAttribute="trailing" constant="12" id="ukL-M0-WWd"/>
|
||||
<constraint firstItem="ay1-ie-dOO" firstAttribute="centerY" secondItem="sme-1q-gFv" secondAttribute="centerY" id="vdN-zt-xpb"/>
|
||||
<constraint firstItem="2bq-E7-5RX" firstAttribute="trailing" secondItem="7dX-Cp-SDr" secondAttribute="trailing" id="wtS-vE-whA"/>
|
||||
</constraints>
|
||||
<userDefinedRuntimeAttributes>
|
||||
<userDefinedRuntimeAttribute type="boolean" keyPath="layer.masksToBounds" value="YES"/>
|
||||
@@ -208,6 +216,7 @@
|
||||
<outlet property="comeCountLabel" destination="RxR-I5-aqT" id="Ros-Uf-7C7"/>
|
||||
<outlet property="followLabel" destination="gwx-5C-Dyi" id="uTA-Os-MrH"/>
|
||||
<outlet property="headerImageView" destination="hCx-Bc-lup" id="bfX-FC-RjW"/>
|
||||
<outlet property="luckyWaterLabel" destination="2bq-E7-5RX" id="W0y-PM-cDj"/>
|
||||
<outlet property="moneyLabel" destination="7dX-Cp-SDr" id="igl-zs-dLw"/>
|
||||
<outlet property="nickNameLabel" destination="N2H-oT-j7d" id="Zrg-Bj-xZR"/>
|
||||
<outlet property="onlineLabel" destination="UEZ-KG-LO0" id="XG2-KV-U11"/>
|
||||
@@ -222,6 +231,6 @@
|
||||
</objects>
|
||||
<resources>
|
||||
<image name="my_room_wait" width="88" height="88"/>
|
||||
<image name="user_header_placehoulder" width="60" height="60"/>
|
||||
<image name="user_header_placehoulder" width="100" height="100"/>
|
||||
</resources>
|
||||
</document>
|
||||
|
||||
@@ -16,6 +16,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@end
|
||||
@interface QXDayTaskCell : UITableViewCell
|
||||
@property (weak, nonatomic) IBOutlet UIView *bgView;
|
||||
@property (weak, nonatomic) IBOutlet UIImageView *iconImageView;
|
||||
@property (weak, nonatomic) IBOutlet UILabel *titleLabel;
|
||||
@property (weak, nonatomic) IBOutlet UILabel *subTitleLabel;
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
if (!cell) {
|
||||
cell = [[NSBundle mainBundle] loadNibNamed:cellId owner:nil options:nil].lastObject;
|
||||
cell.backgroundColor = [UIColor clearColor];
|
||||
cell.contentView.backgroundColor = UIColor.clearColor;
|
||||
}
|
||||
return cell;
|
||||
}
|
||||
@@ -35,15 +36,24 @@
|
||||
if (model.task_status.intValue == 1) {
|
||||
self.finishBtn.enabled = YES;
|
||||
self.finishBtn.selected = NO;
|
||||
self.finishBtn.layer.borderWidth = 1;
|
||||
// self.finishBtn.layer.borderWidth = 1;
|
||||
// self.bgView.layer.borderColor = RGB(184, 177, 106).CGColor;
|
||||
// self.bgView.backgroundColor = RGB(110, 72, 41);
|
||||
// self.bgView.layer.borderWidth = 1;
|
||||
}else if (model.task_status.intValue == 2) {
|
||||
self.finishBtn.enabled = YES;
|
||||
self.finishBtn.selected = YES;
|
||||
self.finishBtn.layer.borderWidth = 1;
|
||||
// self.finishBtn.layer.borderWidth = 1;
|
||||
// self.bgView.layer.borderColor = RGB(184, 177, 106).CGColor;
|
||||
// self.bgView.backgroundColor = RGB(110, 72, 41);
|
||||
// self.bgView.layer.borderWidth = 1;
|
||||
}else{
|
||||
self.finishBtn.selected = NO;
|
||||
self.finishBtn.enabled = NO;
|
||||
self.finishBtn.layer.borderWidth = 0;
|
||||
// self.finishBtn.layer.borderWidth = 0;
|
||||
// self.bgView.layer.borderColor = RGB(184, 177, 106).CGColor;
|
||||
// self.bgView.backgroundColor = RGB(110, 72, 41);
|
||||
// self.bgView.layer.borderWidth = 1;
|
||||
}
|
||||
}
|
||||
- (IBAction)finishAction:(id)sender {
|
||||
@@ -55,14 +65,14 @@
|
||||
[super awakeFromNib];
|
||||
// Initialization code
|
||||
[self.finishBtn addRoundedCornersWithRadius:15];
|
||||
[self.finishBtn setTitleColor:RGB16(0x3ABC6D) forState:(UIControlStateNormal)];
|
||||
[self.finishBtn setTitleColor:UIColor.whiteColor forState:(UIControlStateNormal)];
|
||||
[self.finishBtn setTitleColor:UIColor.whiteColor forState:(UIControlStateSelected)];
|
||||
[self.finishBtn setTitleColor:RGB16(0x666666) forState:(UIControlStateDisabled)];
|
||||
[self.finishBtn setBackgroundImage:[UIImage imageWithColor:RGB16(0x3ABC6D)] forState:(UIControlStateSelected)];
|
||||
[self.finishBtn setBackgroundImage:[UIImage imageWithColor:UIColor.clearColor] forState:(UIControlStateNormal)];
|
||||
[self.finishBtn setBackgroundImage:[UIImage imageWithColor:RGB16(0xF1F2F3)] forState:(UIControlStateDisabled)];
|
||||
self.finishBtn.layer.borderColor = RGB16(0x3ABC6D).CGColor;
|
||||
self.finishBtn.layer.borderWidth = 1;
|
||||
[self.finishBtn setTitleColor:RGB16(0xD8D8D8) forState:(UIControlStateDisabled)];
|
||||
[self.finishBtn setBackgroundImage:[UIImage imageWithColor:RGB16(0xE36C4A)] forState:(UIControlStateSelected)];
|
||||
[self.finishBtn setBackgroundImage:[UIImage imageWithColor:QXConfig.themeColor] forState:(UIControlStateNormal)];
|
||||
[self.finishBtn setBackgroundImage:[UIImage imageWithColor:RGB16(0xAC9993)] forState:(UIControlStateDisabled)];
|
||||
// self.finishBtn.layer.borderColor = RGB16(0x3ABC6D).CGColor;
|
||||
// self.finishBtn.layer.borderWidth = 1;
|
||||
}
|
||||
|
||||
- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
|
||||
|
||||
@@ -17,6 +17,16 @@
|
||||
<rect key="frame" x="0.0" y="0.0" width="481" height="108"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<subviews>
|
||||
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="vrD-8N-Rf4">
|
||||
<rect key="frame" x="0.0" y="4" width="481" height="100"/>
|
||||
<color key="backgroundColor" red="0.20000000000000001" green="0.16470588235294117" blue="0.27450980392156865" alpha="1" colorSpace="calibratedRGB"/>
|
||||
<userDefinedRuntimeAttributes>
|
||||
<userDefinedRuntimeAttribute type="boolean" keyPath="layer.masksToBounds" value="YES"/>
|
||||
<userDefinedRuntimeAttribute type="number" keyPath="layer.cornerRadius">
|
||||
<integer key="value" value="8"/>
|
||||
</userDefinedRuntimeAttribute>
|
||||
</userDefinedRuntimeAttributes>
|
||||
</view>
|
||||
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="Zzf-Hx-7yu">
|
||||
<rect key="frame" x="16" y="9" width="40" height="40"/>
|
||||
<constraints>
|
||||
@@ -27,7 +37,7 @@
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="gZv-uE-Dy3">
|
||||
<rect key="frame" x="62" y="9" width="333" height="69"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="14"/>
|
||||
<color key="textColor" red="0.20000000000000001" green="0.20000000000000001" blue="0.20000000000000001" alpha="1" colorSpace="calibratedRGB"/>
|
||||
<color key="textColor" red="1" green="1" blue="1" alpha="1" colorSpace="calibratedRGB"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="bni-4p-6Qt">
|
||||
@@ -50,7 +60,7 @@
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="eqP-bF-SEp">
|
||||
<rect key="frame" x="62" y="83" width="333" height="17"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="14"/>
|
||||
<color key="textColor" red="0.88627450980392153" green="0.25490196078431371" blue="0.44313725490196076" alpha="1" colorSpace="calibratedRGB"/>
|
||||
<color key="textColor" red="1" green="0.69019607843137254" blue="0.15294117647058825" alpha="1" colorSpace="calibratedRGB"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
</subviews>
|
||||
@@ -61,9 +71,13 @@
|
||||
<constraint firstItem="bni-4p-6Qt" firstAttribute="leading" secondItem="eqP-bF-SEp" secondAttribute="trailing" constant="10" id="ANm-2o-d67"/>
|
||||
<constraint firstAttribute="trailing" secondItem="bni-4p-6Qt" secondAttribute="trailing" constant="16" id="FGd-NP-Bud"/>
|
||||
<constraint firstItem="eqP-bF-SEp" firstAttribute="top" secondItem="gZv-uE-Dy3" secondAttribute="bottom" constant="5" id="Ftb-vc-ugs"/>
|
||||
<constraint firstItem="vrD-8N-Rf4" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" constant="4" id="Glk-DW-BDl"/>
|
||||
<constraint firstItem="Zzf-Hx-7yu" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" constant="9" id="JNo-Ml-0Uf"/>
|
||||
<constraint firstItem="Zzf-Hx-7yu" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="16" id="LJ1-Ut-byU"/>
|
||||
<constraint firstItem="vrD-8N-Rf4" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" id="VBb-ng-q59"/>
|
||||
<constraint firstAttribute="bottom" secondItem="vrD-8N-Rf4" secondAttribute="bottom" constant="4" id="WxO-37-JHo"/>
|
||||
<constraint firstItem="bni-4p-6Qt" firstAttribute="leading" secondItem="gZv-uE-Dy3" secondAttribute="trailing" constant="10" id="XUO-fj-17G"/>
|
||||
<constraint firstAttribute="trailing" secondItem="vrD-8N-Rf4" secondAttribute="trailing" id="a8L-dS-yCw"/>
|
||||
<constraint firstAttribute="bottom" secondItem="eqP-bF-SEp" secondAttribute="bottom" constant="8" id="iSn-GZ-hix"/>
|
||||
<constraint firstItem="gZv-uE-Dy3" firstAttribute="top" secondItem="Zzf-Hx-7yu" secondAttribute="top" id="mgj-C7-FFs"/>
|
||||
<constraint firstItem="eqP-bF-SEp" firstAttribute="leading" secondItem="gZv-uE-Dy3" secondAttribute="leading" id="qVo-gN-l0W"/>
|
||||
@@ -71,6 +85,7 @@
|
||||
</tableViewCellContentView>
|
||||
<viewLayoutGuide key="safeArea" id="aW0-zy-SZf"/>
|
||||
<connections>
|
||||
<outlet property="bgView" destination="vrD-8N-Rf4" id="hMg-zC-qbI"/>
|
||||
<outlet property="finishBtn" destination="bni-4p-6Qt" id="K8I-ow-9Uv"/>
|
||||
<outlet property="iconImageView" destination="Zzf-Hx-7yu" id="D8z-6l-i8N"/>
|
||||
<outlet property="subTitleLabel" destination="eqP-bF-SEp" id="NDK-d5-ZFa"/>
|
||||
|
||||
@@ -50,18 +50,18 @@
|
||||
|
||||
self.bgView = [[UIView alloc] initWithFrame:CGRectMake(0, ScaleWidth(52), self.width, self.height-ScaleWidth(52)-12)];
|
||||
[self.bgView addRoundedCornersWithRadius:16];
|
||||
self.bgView.backgroundColor = [UIColor whiteColor];
|
||||
self.bgView.backgroundColor = RGB16(0x31433F);
|
||||
[self addSubview:self.bgView];
|
||||
|
||||
CGFloat boxWidth = (self.width-16*3)/2;
|
||||
self.leftBoxView = [[QXDayTaskTopSubView alloc] initWithFrame:CGRectMake(16, 16, boxWidth, self.bgView.height-16*2)];
|
||||
[self.leftBoxView addRoundedCornersWithRadius:8];
|
||||
self.leftBoxView.backgroundColor = RGB16(0xFCE4ED);
|
||||
self.leftBoxView.backgroundColor = RGB16(0xA457F8);
|
||||
self.leftBoxView.type = QXDayTaskTopSubViewTypeLeft;
|
||||
[self.bgView addSubview:self.leftBoxView];
|
||||
|
||||
self.rightBoxView = [[QXDayTaskTopSubView alloc] initWithFrame:CGRectMake(self.leftBoxView.right+16, 16, boxWidth, self.leftBoxView.height) ];
|
||||
self.rightBoxView.backgroundColor = RGB16(0xFDE8AE);
|
||||
self.rightBoxView.backgroundColor = RGB16(0xD89F47);
|
||||
[self.rightBoxView addRoundedCornersWithRadius:8];
|
||||
self.rightBoxView.type = QXDayTaskTopSubViewTypeRight;
|
||||
[self.bgView addSubview:self.rightBoxView];
|
||||
@@ -98,13 +98,13 @@
|
||||
-(void)initSubviews{
|
||||
self.titleLabel = [[UILabel alloc] initWithFrame:CGRectMake(10, 10, self.width-20, 24)];
|
||||
self.titleLabel.font = [UIFont boldSystemFontOfSize:16];
|
||||
self.titleLabel.textColor = RGB16(0xE24171);
|
||||
self.titleLabel.textColor = RGB16(0xffffff);
|
||||
self.titleLabel.textAlignment = NSTextAlignmentCenter;
|
||||
[self addSubview:self.titleLabel];
|
||||
|
||||
self.subTitleLabel = [[UILabel alloc] initWithFrame:CGRectMake(10, self.titleLabel.bottom, self.width-20, 18)];
|
||||
self.subTitleLabel.font = [UIFont systemFontOfSize:12];
|
||||
self.subTitleLabel.textColor = RGB16(0x999999);
|
||||
self.subTitleLabel.textColor = RGB16(0xffffff);
|
||||
self.subTitleLabel.textAlignment = NSTextAlignmentCenter;
|
||||
[self addSubview:self.subTitleLabel];
|
||||
|
||||
@@ -114,7 +114,7 @@
|
||||
|
||||
self.cornLabel = [[UILabel alloc] initWithFrame:CGRectMake(10, self.iconImageView.bottom, self.width-20, 18)];
|
||||
self.cornLabel.font = [UIFont systemFontOfSize:12];
|
||||
self.cornLabel.textColor = RGB16(0x999999);
|
||||
self.cornLabel.textColor = RGB16(0xffffff);
|
||||
self.cornLabel.textAlignment = NSTextAlignmentCenter;
|
||||
[self addSubview:self.cornLabel];
|
||||
|
||||
@@ -146,7 +146,7 @@
|
||||
_boxModel = boxModel;
|
||||
self.titleLabel.text = boxModel.name;
|
||||
NSMutableAttributedString *attr = [[NSMutableAttributedString alloc] initWithString:boxModel.title];
|
||||
[attr yy_setColor:RGB16(0xE24171) range:[boxModel.title rangeOfString:boxModel.highest_gain]];
|
||||
[attr yy_setColor:RGB16(0xFFEA00) range:[boxModel.title rangeOfString:boxModel.highest_gain]];
|
||||
self.subTitleLabel.attributedText = attr;
|
||||
if (boxModel.icon.length > 0 && ([boxModel.icon hasPrefix:@"http"] || [boxModel.icon hasPrefix:@"https"])) {
|
||||
[self.iconImageView sd_setImageWithURL:[NSURL URLWithString:boxModel.icon]];
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
@property (nonatomic,strong)QXLoginTextField *codeTextField;
|
||||
@property (nonatomic,strong)UIButton *closeBtn;
|
||||
@property (nonatomic,strong)UIButton *commitBtn;
|
||||
@property (nonatomic,assign)BOOL isNetworking;
|
||||
@end
|
||||
@implementation QXReVerificationPopView
|
||||
|
||||
@@ -126,6 +127,9 @@
|
||||
}
|
||||
|
||||
-(void)didClickSendCode:(UIButton *)sender{
|
||||
if (self.isNetworking) {
|
||||
return;
|
||||
}
|
||||
NSString*mobile = [QXGlobal shareGlobal].loginModel.mobile;
|
||||
if (mobile.length == 0) {
|
||||
showToast(@"请先绑定手机号");
|
||||
@@ -136,10 +140,13 @@
|
||||
type = GetSmscodeTypeAccountCancel;
|
||||
}
|
||||
MJWeakSelf
|
||||
self.isNetworking = YES;
|
||||
[QXLoginNetwork getSmscodeWithMobile:[QXGlobal shareGlobal].loginModel.mobile type:type successBlock:^(id _Nonnull responseObject) {
|
||||
[weakSelf.codeTextField startTimeDown];
|
||||
weakSelf.isNetworking = NO;
|
||||
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||
showToast(msg);
|
||||
weakSelf.isNetworking = NO;
|
||||
}];
|
||||
}
|
||||
@end
|
||||
|
||||
Reference in New Issue
Block a user