This commit is contained in:
启星
2025-12-04 14:11:00 +08:00
parent 2d37ab6844
commit 1c5a908dda
49 changed files with 505 additions and 192 deletions

View File

@@ -62,7 +62,6 @@
[super viewWillAppear:animated];
[self.navigationController setNavigationBarHidden:YES animated:YES];
[self getUserInfo];
[self.tableView reloadData];
[self.tableHeaderView reloadData];
}
@@ -96,6 +95,7 @@
[QXMineNetwork getMineInfoSuccessBlock:^(QXUserModel * _Nonnull userModel) {
weakSelf.userModel = userModel;
weakSelf.tableHeaderView.userModel = userModel;
[weakSelf.tableView reloadData];
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
}];
@@ -232,7 +232,7 @@
}
break;
case QXMainHeaderOptionTypeBodyPrice:{
[QXBodyPriceRuleView showInView:self.view];
[QXBodyPriceRuleView showInView:self.view currentBodyValue:self.userModel.market_value coin:self.userModel.market_value_coin bodyValue:self.userModel.market_value_market];
}
break;
case QXMainHeaderOptionTypeWallet:{
@@ -307,6 +307,7 @@
-(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{
QXMineServiceCell *cell = [QXMineServiceCell cellWithTableView:tableView];
cell.delegate = self;
cell.singerIsAuth = self.userModel.singer_status.intValue==1;
if (indexPath.row == 0) {
cell.isMore = NO;
}else{
@@ -316,7 +317,8 @@
}
-(CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath{
if (indexPath.row == 0) {
return ScaleWidth(168);
// return ScaleWidth(168);
return ScaleWidth(110);
}else{
// if (QXGlobal.shareGlobal.isOpenRecharge) {
return ScaleWidth(168);

View File

@@ -51,7 +51,7 @@
}
-(void)getList{
__weak typeof(self) weakSelf = self;
[QXMineNetwork getFamilyEarningWithUserId:self.userId successBlock:^(NSArray<QXFamilyEarningModel *> * _Nonnull list) {
[QXMineNetwork getFamilyEarningWithUserId:self.userId page:self.page start_time:self.startTime end_time:self.endTime successBlock:^(NSArray<QXFamilyEarningModel *> * _Nonnull list) {
__strong typeof(weakSelf) strongSelf = weakSelf;
if (!strongSelf) {
NSLog(@"⚠️ self has been deallocated, skipping hide operation");

View File

@@ -13,7 +13,7 @@
@interface QXFamilySubViewController ()<UITableViewDelegate,UITableViewDataSource,QXFamilyMemberCellDelegate>
@property (nonatomic,strong)UITableView *tableView;
@property (nonatomic,strong)QXFamilyModel *model;
@property (nonatomic,strong)UIView *noDataView;
@end
@implementation QXFamilySubViewController
@@ -41,17 +41,22 @@
-(void)getList{
BOOL isJoin = YES;
if (self.index == 0) {
isJoin = YES;
}else{
isJoin = NO;
}else{
isJoin = YES;
}
MJWeakSelf
[QXMineNetwork getMyFamilyIsJoin:isJoin successBlock:^(QXFamilyModel * _Nonnull model) {
weakSelf.model = model;
if (weakSelf.model.group_members_lists.count == 0) {
weakSelf.tableView.tableFooterView = weakSelf.noDataView;
}else{
weakSelf.tableView.tableFooterView = nil;
}
[weakSelf.tableView reloadData];
[weakSelf.tableView.mj_header endRefreshing];
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
[weakSelf.tableView.mj_header endRefreshing];
}];
}
-(void)needRefresh{
@@ -128,6 +133,9 @@
return 0;
}
-(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{
if (indexPath.section == 0) {
return;
}
QXFamilyMemberModel*md = self.model.group_members_lists[indexPath.row];
QXUserHomePageViewController *vc = [[QXUserHomePageViewController alloc] init];
vc.user_id = md.user_id;
@@ -154,5 +162,29 @@
}
return _tableView;
}
-(UIView *)noDataView{
if (!_noDataView) {
_noDataView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, SCREEN_WIDTH, ScaleWidth(120)+30)];
UIImageView *imageView = [[UIImageView alloc] initWithImage:[UIImage imageNamed:@"qx_no_data"]];
[_noDataView addSubview:imageView];
[imageView mas_makeConstraints:^(MASConstraintMaker *make) {
make.width.mas_equalTo(ScaleWidth(148));
make.height.mas_equalTo(ScaleWidth(99));
make.centerX.equalTo(_noDataView);
make.top.mas_equalTo(30);
}];
UILabel *titleLabel = [[UILabel alloc] init];
titleLabel.font = [UIFont systemFontOfSize:12];
titleLabel.text = @"暂无数据";
titleLabel.textColor = RGB16(0xffffff);
[_noDataView addSubview:titleLabel];
[titleLabel mas_makeConstraints:^(MASConstraintMaker *make) {
make.centerX.equalTo(_noDataView);
make.top.equalTo(imageView.mas_bottom);
}];
}
return _noDataView;
}
@end

View File

@@ -45,12 +45,18 @@
}
-(void)initSubViews{
self.page = 1;
self.countLabel = [[UILabel alloc] initWithFrame:CGRectMake(16, NavContentHeight+12, 200, 17)];
self.countLabel.textColor = RGB16A(0x000000,0.45);
self.countLabel = [[UILabel alloc] initWithFrame:CGRectMake(16, NavContentHeight+12, 200, 35)];
self.countLabel.textColor = RGB16(0x666666);
self.countLabel.font = [UIFont systemFontOfSize:12];
self.countLabel.text = @"共0首歌";
[self.view addSubview:self.countLabel];
UIButton*recordBtn = [[UIButton alloc] initWithFrame:CGRectMake(self.view.width-35-16, NavContentHeight+12, 35, 35)];
[recordBtn setImage:[[UIImage imageNamed:@"nobility_help_icon"] imageByTintColor:RGB16(0x666666)] forState:(UIControlStateNormal)];
recordBtn.titleLabel.font = [UIFont systemFontOfSize:16];
[recordBtn addTarget:self action:@selector(helpAction) forControlEvents:(UIControlEventTouchUpInside)];
[self.view addSubview:recordBtn];
[self.view addSubview:self.tableView];
[self getSongList];
}
@@ -74,7 +80,12 @@
}];
}
-(void)helpAction{
NSString *urlString = [NSString stringWithFormat:@"%@api/Page/page_show?id=%@",ServerUrl,@"34"];
QXBaseWebViewController *vc = [[QXBaseWebViewController alloc] init];
vc.urlStr = urlString;
[self.navigationController pushViewController:vc animated:YES];
}
-(void)didSeletedGift:(QXGiftModel *)giftModel giftCount:(nonnull NSString *)giftCount{
giftModel.num = giftCount;
self.addSongView.giftModel = giftModel;

View File

@@ -7,6 +7,7 @@
#import "QXRoomSingerAuthViewController.h"
#import "QXAudioRecorderView.h"
#import "QXMineNetwork.h"
@interface QXRoomSingerAuthViewController ()<QXAudioRecorderViewDelegate>
@property (nonatomic,strong)UIView *contentView;
@@ -39,7 +40,11 @@
[super setNavgationItems];
self.navigationTintColor = RGB16(0xffffff);
self.navigationItem.title = @"歌手认证";
UIButton*recordBtn = [[UIButton alloc] initWithFrame:CGRectMake(0, 0, 44, 44)];
[recordBtn setImage:[UIImage imageNamed:@"nobility_help_icon"] forState:(UIControlStateNormal)];
recordBtn.titleLabel.font = [UIFont systemFontOfSize:16];
[recordBtn addTarget:self action:@selector(helpAction) forControlEvents:(UIControlEventTouchUpInside)];
self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithCustomView:recordBtn];
}
- (void)initSubViews{
@@ -71,8 +76,13 @@
self.audioRecorderView.delegate = self;
self.audioRecorderView.hidden = YES;
[self.view addSubview:self.audioRecorderView];
[self conifgViews];
}
-(void)conifgViews{
if ([self.singer_status isEqualToString:@"-1"] || [self.singer_status isEqualToString:@"2"]) {
self.audioRecorderView.hidden = NO;
}else{
self.audioRecorderView.hidden = YES;
}
if ([self.singer_status isEqualToString:@"-1"]) {
self.authStatusLabel.text = @"暂未认证";
@@ -88,6 +98,12 @@
self.authStatusLabel.textColor = RGB16(0xFF2424);
}
}
-(void)helpAction{
NSString *urlString = [NSString stringWithFormat:@"%@api/Page/page_show?id=%@",ServerUrl,@"33"];
QXBaseWebViewController *vc = [[QXBaseWebViewController alloc] init];
vc.urlStr = urlString;
[self.navigationController pushViewController:vc animated:YES];
}
#pragma mark - AudioRecorderViewDelegate
- (void)qxAudioRecorderView:(QXAudioRecorderView *)recorderView didChangeState:(AudioRecorderState)state{
@@ -112,5 +128,26 @@
//
}
-(void)didClickAuthWithFileUrl:(NSURL *)audioFileUrl{
NSData *data = [NSData dataWithContentsOfURL:audioFileUrl];
@weakify(self)
showLoadingInView(self.view);
[[QXCOSUploadManager shareManager] audioUploadFile:data withObjectKey:audioFileUrl.lastPathComponent complete:^(NSString * _Nonnull fileUrl, QXCOSUploadImageState state) {
@strongify(self);
dispatch_async(dispatch_get_main_queue(), ^{
hideLoadingInView(self.view);
if ([fileUrl isExist]) {
[QXMineNetwork singerAuthWithSong:fileUrl successBlock:^(NSDictionary * _Nonnull dict) {
showToast(@"上传成功");
self.singer_status = @"0";
[self conifgViews];
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
showToast(@"上传失败");
}];
}else{
showToast(@"上传失败");
}
});
}];
}
@end

View File

@@ -25,6 +25,10 @@
self.page = 1;
[self getHistorySubsidy];
}
-(void)viewWillAppear:(BOOL)animated{
[super viewWillAppear:animated];
[self.navigationController setNavigationBarHidden:NO animated:YES];
}
-(void)getHistorySubsidy{
MJWeakSelf
[QXMineNetwork dayTaskGiftBoxRecordSuccessBlock:^(NSArray<QXTaskGiftBoxRecordModel *> * _Nonnull list) {