fix:修正个播房活动入口显示逻辑 #1430

This commit is contained in:
eggmanQQQ
2024-07-29 11:26:34 +08:00
parent 4ea792cbcd
commit e8dffabb2c
3 changed files with 8 additions and 4 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.7 KiB

After

Width:  |  Height:  |  Size: 7.1 KiB

View File

@@ -153,6 +153,9 @@ UIKIT_EXTERN NSString *kShowFirstRechargeView;
@kStrongify(self);
self.playList = [NSMutableArray arrayWithArray:playModels];
self.littleGameList = [NSMutableArray arrayWithArray:littleGameModels];
self.gambleMenuButton.hidden = self.playList.count > 0 ? NO : YES;
[self onRoomUpdate];
return nil;
}] subscribeError:^(NSError * _Nullable error) {}];
@@ -273,10 +276,9 @@ UIKIT_EXTERN NSString *kShowFirstRechargeView;
[self updateConfigEntranceButtons:roomInfo];
if (roomInfo.type == RoomType_Anchor || roomInfo.roomModeType == RoomModeType_Open_Blind) {
self.gambleMenuButton.hidden = YES;
self.pkMenuButton.hidden = YES;
} else {
self.gambleMenuButton.hidden = self.playList.count > 0 ? NO : YES;
self.pkMenuButton.hidden = NO;
}
@@ -327,7 +329,9 @@ UIKIT_EXTERN NSString *kShowFirstRechargeView;
NIMChatroomMembersByIdsRequest *request = [[NIMChatroomMembersByIdsRequest alloc]init];
request.roomId = [NSString stringWithFormat:@"%ld", roomInfo.roomId];
request.userIds = @[[AccountInfoStorage instance].getUid];
@kWeakify(self);
[[NIMSDK sharedSDK].chatroomManager fetchChatroomMembersByIds:request completion:^(NSError * _Nullable error, NSArray<NIMChatroomMember *> * _Nullable members) {
@kStrongify(self);
if (error == nil) {
NIMChatroomMember * member = members.firstObject;
if (member.type == NIMTeamMemberTypeOwner || member.type == NIMTeamMemberTypeManager) {

View File

@@ -649,8 +649,8 @@
if (!_stackView) {
_stackView = [[UIStackView alloc] init];
_stackView.axis = UILayoutConstraintAxisHorizontal;
_stackView.distribution = UIStackViewDistributionFillEqually;
_stackView.alignment = UIStackViewAlignmentCenter;
_stackView.distribution = UIStackViewDistributionFill;
_stackView.alignment = UIStackViewAlignmentLeading;
_stackView.spacing = 11;
}
return _stackView;