提交
This commit is contained in:
@@ -141,14 +141,8 @@
|
|||||||
QXRoomChatListModel *model = [QXRoomChatListModel yy_modelWithJSON:msg.Text];
|
QXRoomChatListModel *model = [QXRoomChatListModel yy_modelWithJSON:msg.Text];
|
||||||
model.messageType = QXRoomChatMessageTypeSystem;
|
model.messageType = QXRoomChatMessageTypeSystem;
|
||||||
NSString *jia_jia = [NSString stringWithFormat:@"%@",msg.Text[@"jia_jia"]];
|
NSString *jia_jia = [NSString stringWithFormat:@"%@",msg.Text[@"jia_jia"]];
|
||||||
if ([self.exRoomId isExist] && [self.roomId isExist]) {
|
if (!isSuperRoom) {
|
||||||
/// 酒吧房小黑屋不管大房间的特效
|
/// 酒吧房小黑屋不管大房间的特效
|
||||||
if ([groupId isEqualToString:self.groupId]){
|
|
||||||
if (([jia_jia hasPrefix:@"http"] || [jia_jia hasPrefix:@"https"]) && ([jia_jia hasSuffix:@"svga"] || [jia_jia hasSuffix:@"mp4"])) {
|
|
||||||
[[QXGiftPlayerManager shareManager] displayChatEffectView:jia_jia];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}else{
|
|
||||||
if (([jia_jia hasPrefix:@"http"] || [jia_jia hasPrefix:@"https"]) && ([jia_jia hasSuffix:@"svga"] || [jia_jia hasSuffix:@"mp4"])) {
|
if (([jia_jia hasPrefix:@"http"] || [jia_jia hasPrefix:@"https"]) && ([jia_jia hasSuffix:@"svga"] || [jia_jia hasSuffix:@"mp4"])) {
|
||||||
[[QXGiftPlayerManager shareManager] displayChatEffectView:jia_jia];
|
[[QXGiftPlayerManager shareManager] displayChatEffectView:jia_jia];
|
||||||
}
|
}
|
||||||
@@ -179,21 +173,14 @@
|
|||||||
/// 收到礼物
|
/// 收到礼物
|
||||||
QXRoomChatListModel *model = [QXRoomChatListModel yy_modelWithJSON:msg.Text];
|
QXRoomChatListModel *model = [QXRoomChatListModel yy_modelWithJSON:msg.Text];
|
||||||
model.messageType = QXRoomChatMessageTypeGift;
|
model.messageType = QXRoomChatMessageTypeGift;
|
||||||
if ([self.exRoomId isExist] && [self.roomId isExist]) {
|
if (!isSuperRoom) {
|
||||||
/// 酒吧房小黑屋不管大房间的特效
|
/// 酒吧房小黑屋不管大房间的特效
|
||||||
if ([groupId isEqualToString:self.groupId]){
|
|
||||||
NSArray *arr = [model.GiftInfo.play_image componentsSeparatedByString:@","];
|
|
||||||
[[QXGiftPlayerManager shareManager] displayFullEffectViewWithMorePlayImages:arr];
|
|
||||||
[[QXGiftDisplayManager sharedManager] receiveGift:model];
|
|
||||||
}
|
|
||||||
}else{
|
|
||||||
if ([model.GiftInfo.play_image isExist]) {
|
if ([model.GiftInfo.play_image isExist]) {
|
||||||
NSArray *arr = [model.GiftInfo.play_image componentsSeparatedByString:@","];
|
NSArray *arr = [model.GiftInfo.play_image componentsSeparatedByString:@","];
|
||||||
[[QXGiftPlayerManager shareManager] displayFullEffectViewWithMorePlayImages:arr];
|
[[QXGiftPlayerManager shareManager] displayFullEffectViewWithMorePlayImages:arr];
|
||||||
}
|
}
|
||||||
[[QXGiftDisplayManager sharedManager] receiveGift:model];
|
[[QXGiftDisplayManager sharedManager] receiveGift:model];
|
||||||
}
|
}
|
||||||
|
|
||||||
if (model.ToUserInfos.count>0) {
|
if (model.ToUserInfos.count>0) {
|
||||||
if (self.delegate && [self.delegate respondsToSelector:@selector(didRecieveGiftWithWithUserInfos:)]) {
|
if (self.delegate && [self.delegate respondsToSelector:@selector(didRecieveGiftWithWithUserInfos:)]) {
|
||||||
[self.delegate didRecieveGiftWithWithUserInfos:model.ToUserInfos];
|
[self.delegate didRecieveGiftWithWithUserInfos:model.ToUserInfos];
|
||||||
|
|||||||
@@ -169,7 +169,7 @@
|
|||||||
UILabel *waterLabel = [[UILabel alloc] initWithFrame:CGRectMake(SCREEN_WIDTH-16-130, 0, SCREEN_WIDTH-130-32, 25)];
|
UILabel *waterLabel = [[UILabel alloc] initWithFrame:CGRectMake(SCREEN_WIDTH-16-130, 0, SCREEN_WIDTH-130-32, 25)];
|
||||||
waterLabel.font = [UIFont systemFontOfSize:13];
|
waterLabel.font = [UIFont systemFontOfSize:13];
|
||||||
waterLabel.textColor = [UIColor colorWithHexString:@"#333333"];
|
waterLabel.textColor = [UIColor colorWithHexString:@"#333333"];
|
||||||
NSString *total_earning = [NSString stringWithFormat:@"%.2f",model.total_earning];
|
NSString *total_earning = [NSString stringWithFormat:@"%.4f",model.total_earning];
|
||||||
NSString *total_price = [NSString stringWithFormat:@"%.2f",model.total_price];
|
NSString *total_price = [NSString stringWithFormat:@"%.2f",model.total_price];
|
||||||
NSString *s = [NSString stringWithFormat:@"收益 %@ 流水 %@",total_earning,total_price];
|
NSString *s = [NSString stringWithFormat:@"收益 %@ 流水 %@",total_earning,total_price];
|
||||||
NSMutableAttributedString *attr = [[NSMutableAttributedString alloc] initWithString:s];
|
NSMutableAttributedString *attr = [[NSMutableAttributedString alloc] initWithString:s];
|
||||||
@@ -181,6 +181,11 @@
|
|||||||
[waterLabel sizeToFit];
|
[waterLabel sizeToFit];
|
||||||
waterLabel.frame = CGRectMake(SCREEN_WIDTH-16-waterLabel.size.width, 0, waterLabel.size.width, 25);
|
waterLabel.frame = CGRectMake(SCREEN_WIDTH-16-waterLabel.size.width, 0, waterLabel.size.width, 25);
|
||||||
[header addSubview:waterLabel];
|
[header addSubview:waterLabel];
|
||||||
|
if (self.type == 1) {
|
||||||
|
waterLabel.hidden = YES;
|
||||||
|
}else{
|
||||||
|
waterLabel.hidden = NO;
|
||||||
|
}
|
||||||
return header;
|
return header;
|
||||||
}
|
}
|
||||||
-(CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section{
|
-(CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section{
|
||||||
|
|||||||
@@ -1570,6 +1570,12 @@ NS_ASSUME_NONNULL_BEGIN
|
|||||||
successBlock:(void (^)(NSDictionary* dict))successBlock
|
successBlock:(void (^)(NSDictionary* dict))successBlock
|
||||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock;
|
failBlock:(void (^)(NSError * error, NSString * msg))failBlock;
|
||||||
|
|
||||||
|
/**
|
||||||
|
小黑屋列表
|
||||||
|
*/
|
||||||
|
+(void)roomBarCabinRoomListWithRoomId:(NSString*)roomId
|
||||||
|
successBlock:(void (^)(NSArray* list))successBlock
|
||||||
|
failBlock:(void (^)(NSError * error, NSString * msg))failBlock;
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
|
|||||||
@@ -3197,4 +3197,28 @@
|
|||||||
failBlock(error,msg);
|
failBlock(error,msg);
|
||||||
}];
|
}];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
小黑屋列表
|
||||||
|
*/
|
||||||
|
+(void)roomBarCabinRoomListWithRoomId:(NSString*)roomId
|
||||||
|
successBlock:(void (^)(NSArray* list))successBlock
|
||||||
|
failBlock:(void (^)(NSError * error, NSString * msg))failBlock{
|
||||||
|
NSDictionary *parameters =@{
|
||||||
|
@"room_id":roomId?:@"",
|
||||||
|
};
|
||||||
|
[[QXRequset shareInstance] postWithUrl:QXRoomBarCabinRoomList parameters:parameters needCache:NO success:^(id responseObject) {
|
||||||
|
if (successBlock) {
|
||||||
|
id object = responseObject[@"data"];
|
||||||
|
NSArray *array = [NSArray array];
|
||||||
|
if ([object isKindOfClass:[NSArray class]]) {
|
||||||
|
array = (NSArray*)object;
|
||||||
|
}
|
||||||
|
successBlock(array);
|
||||||
|
}
|
||||||
|
} fail:^(NSError *error, NSString *msg, NSURLSessionDataTask *task) {
|
||||||
|
failBlock(error,msg);
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|||||||
@@ -125,7 +125,7 @@
|
|||||||
-(void)setModel:(QXRoomDetailModel *)model{
|
-(void)setModel:(QXRoomDetailModel *)model{
|
||||||
_model = model;
|
_model = model;
|
||||||
self.allWaterLabel.text = [NSString stringWithFormat:@"%.2f",model.total_amount];;
|
self.allWaterLabel.text = [NSString stringWithFormat:@"%.2f",model.total_amount];;
|
||||||
self.allPriceLabel.text = [NSString stringWithFormat:@"%.2f",model.total_earning];
|
self.allPriceLabel.text = [NSString stringWithFormat:@"%.4f",model.total_earning];
|
||||||
}
|
}
|
||||||
|
|
||||||
-(UIImageView *)bgImageView{
|
-(UIImageView *)bgImageView{
|
||||||
|
|||||||
22
QXLive/Other/Assets.xcassets/room/酒吧房/bar_room_title_cabin_room.imageset/Contents.json
vendored
Normal file
22
QXLive/Other/Assets.xcassets/room/酒吧房/bar_room_title_cabin_room.imageset/Contents.json
vendored
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
{
|
||||||
|
"images" : [
|
||||||
|
{
|
||||||
|
"idiom" : "universal",
|
||||||
|
"scale" : "1x"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename" : "bar_room_title_cabin_room@2x.png",
|
||||||
|
"idiom" : "universal",
|
||||||
|
"scale" : "2x"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename" : "bar_room_title_cabin_room@3x.png",
|
||||||
|
"idiom" : "universal",
|
||||||
|
"scale" : "3x"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"info" : {
|
||||||
|
"author" : "xcode",
|
||||||
|
"version" : 1
|
||||||
|
}
|
||||||
|
}
|
||||||
Binary file not shown.
|
After Width: | Height: | Size: 2.3 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 4.8 KiB |
@@ -614,4 +614,6 @@ static NSString * QXRoomGetSeductionCoin = @"api/BarRoom/get_liao_ta_coin";
|
|||||||
static NSString * QXRoomBarSeduction = @"api/BarRoom/liao_ta";
|
static NSString * QXRoomBarSeduction = @"api/BarRoom/liao_ta";
|
||||||
/// 约他
|
/// 约他
|
||||||
static NSString * QXRoomBarAsk = @"api/BarRoom/meeting_ta";
|
static NSString * QXRoomBarAsk = @"api/BarRoom/meeting_ta";
|
||||||
|
/// 小黑屋列表
|
||||||
|
static NSString * QXRoomBarCabinRoomList = @"api/BarRoom/black_room_list";
|
||||||
#endif /* Api_h */
|
#endif /* Api_h */
|
||||||
|
|||||||
@@ -26,6 +26,9 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
-(void)updateProgress:(NSNotification *)notice{
|
-(void)updateProgress:(NSNotification *)notice{
|
||||||
|
if ([self.roomModel.room_info.type_id isEqualToString:@"6"]) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
QXMeetActivityDriftModel *model = notice.object;
|
QXMeetActivityDriftModel *model = notice.object;
|
||||||
if (model.from_type == QXMeetActivityTypeAcLock) {
|
if (model.from_type == QXMeetActivityTypeAcLock) {
|
||||||
[self.meetView updateUserAndGiftInfoWithModel:model];
|
[self.meetView updateUserAndGiftInfoWithModel:model];
|
||||||
|
|||||||
@@ -271,6 +271,7 @@ QXUpSeatViewDelegate
|
|||||||
make.size.mas_equalTo(CGSizeMake(SCREEN_WIDTH, SCREEN_HEIGHT));
|
make.size.mas_equalTo(CGSizeMake(SCREEN_WIDTH, SCREEN_HEIGHT));
|
||||||
}];
|
}];
|
||||||
QXCPEffectView *cpEffectView = [[QXGiftPlayerManager shareManager] defaultCpEffectView];
|
QXCPEffectView *cpEffectView = [[QXGiftPlayerManager shareManager] defaultCpEffectView];
|
||||||
|
cpEffectView.isBackground = NO;
|
||||||
[cpEffectView mas_makeConstraints:^(MASConstraintMaker *make) {
|
[cpEffectView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
// make.top.equalTo(self.seatContentView.mas_bottom).offset(padding);
|
// make.top.equalTo(self.seatContentView.mas_bottom).offset(padding);
|
||||||
// make.left.right.equalTo(self.bgEffectView);
|
// make.left.right.equalTo(self.bgEffectView);
|
||||||
|
|||||||
@@ -476,7 +476,7 @@ NSInteger maxMessageCount = 20;
|
|||||||
self.nameLabel.textColor = superRoomMessageColor;
|
self.nameLabel.textColor = superRoomMessageColor;
|
||||||
[attr yy_setColor:superRoomMessageColor range:NSMakeRange(0, attr.length)];
|
[attr yy_setColor:superRoomMessageColor range:NSMakeRange(0, attr.length)];
|
||||||
}else{
|
}else{
|
||||||
self.nameLabel.textColor = messageNameColor;
|
self.nameLabel.textColor = RGB16(0xDED6ED);
|
||||||
if ([message.FromUserInfo.nickname isExist]) {
|
if ([message.FromUserInfo.nickname isExist]) {
|
||||||
[attr yy_setColor:messageNameColor range:[message.text rangeOfString:message.FromUserInfo.nickname]];
|
[attr yy_setColor:messageNameColor range:[message.text rangeOfString:message.FromUserInfo.nickname]];
|
||||||
}
|
}
|
||||||
@@ -968,7 +968,7 @@ NSInteger maxMessageCount = 20;
|
|||||||
if (message.isSuperRoom) {
|
if (message.isSuperRoom) {
|
||||||
self.nameLabel.textColor = superRoomMessageColor;
|
self.nameLabel.textColor = superRoomMessageColor;
|
||||||
}else{
|
}else{
|
||||||
self.nameLabel.textColor = messageNameColor;
|
self.nameLabel.textColor = RGB16(0xDED6ED);
|
||||||
}
|
}
|
||||||
self.nameLabel.text = message.FromUserInfo.nickname;
|
self.nameLabel.text = message.FromUserInfo.nickname;
|
||||||
[self.headerImageView setHeadIcon:message.FromUserInfo.avatar dress:@""];
|
[self.headerImageView setHeadIcon:message.FromUserInfo.avatar dress:@""];
|
||||||
|
|||||||
@@ -218,7 +218,7 @@
|
|||||||
self.cabinRoom.titleLabel.font = [UIFont systemFontOfSize:12];
|
self.cabinRoom.titleLabel.font = [UIFont systemFontOfSize:12];
|
||||||
[self.cabinRoom setTitleColor:[UIColor whiteColor] forState:(UIControlStateNormal)];
|
[self.cabinRoom setTitleColor:[UIColor whiteColor] forState:(UIControlStateNormal)];
|
||||||
[self.cabinRoom addTarget:self action:@selector(cabinAction) forControlEvents:(UIControlEventTouchUpInside)];
|
[self.cabinRoom addTarget:self action:@selector(cabinAction) forControlEvents:(UIControlEventTouchUpInside)];
|
||||||
[self.cabinRoom setImage:[UIImage imageNamed:@"room_clear_charm"] forState:(UIControlStateNormal)];
|
[self.cabinRoom setImage:[UIImage imageNamed:@"bar_room_title_cabin_room"] forState:(UIControlStateNormal)];
|
||||||
self.cabinRoom.backgroundColor = RGB16A(0xFFFFFF,0.2);
|
self.cabinRoom.backgroundColor = RGB16A(0xFFFFFF,0.2);
|
||||||
[self.cabinRoom addRoundedCornersWithRadius:ScaleWidth(11)];
|
[self.cabinRoom addRoundedCornersWithRadius:ScaleWidth(11)];
|
||||||
[self addSubview:self.cabinRoom];
|
[self addSubview:self.cabinRoom];
|
||||||
@@ -243,6 +243,10 @@
|
|||||||
}
|
}
|
||||||
-(void)setIsCompere:(BOOL)isCompere{
|
-(void)setIsCompere:(BOOL)isCompere{
|
||||||
_isCompere = isCompere;
|
_isCompere = isCompere;
|
||||||
|
if ([self.roomModel.room_info.type_id isEqualToString:@"11"]) {
|
||||||
|
self.clearCharmBtn.hidden = YES;
|
||||||
|
return;
|
||||||
|
}
|
||||||
self.clearCharmBtn.hidden = !isCompere;
|
self.clearCharmBtn.hidden = !isCompere;
|
||||||
}
|
}
|
||||||
-(void)layoutSubviews{
|
-(void)layoutSubviews{
|
||||||
@@ -260,6 +264,11 @@
|
|||||||
self.followBtn.selected = NO;
|
self.followBtn.selected = NO;
|
||||||
}
|
}
|
||||||
self.countLabel.text = roomModel.room_info.online_number?roomModel.room_info.online_number:@"0";
|
self.countLabel.text = roomModel.room_info.online_number?roomModel.room_info.online_number:@"0";
|
||||||
|
if ([self.roomModel.room_info.type_id isEqualToString:@"11"]) {
|
||||||
|
self.cabinRoom.hidden = NO;
|
||||||
|
}else{
|
||||||
|
self.cabinRoom.hidden = YES;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
-(void)setOnlineUsers:(NSArray *)onlineUsers{
|
-(void)setOnlineUsers:(NSArray *)onlineUsers{
|
||||||
_onlineUsers = onlineUsers;
|
_onlineUsers = onlineUsers;
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ NS_ASSUME_NONNULL_BEGIN
|
|||||||
@property (nonatomic,strong) VAPView *playerMp4View;
|
@property (nonatomic,strong) VAPView *playerMp4View;
|
||||||
-(void)displayCpEffectUrl:(QXRoomChatListModel*)model;
|
-(void)displayCpEffectUrl:(QXRoomChatListModel*)model;
|
||||||
@property (nonatomic, strong) dispatch_queue_t queue;
|
@property (nonatomic, strong) dispatch_queue_t queue;
|
||||||
|
@property (nonatomic, assign) BOOL isBackground;
|
||||||
- (void)destroyEffectView;
|
- (void)destroyEffectView;
|
||||||
-(void)stopPlay;
|
-(void)stopPlay;
|
||||||
-(void)startPlay;
|
-(void)startPlay;
|
||||||
|
|||||||
@@ -19,7 +19,6 @@
|
|||||||
@property (nonatomic, assign) BOOL isLoadEffect;
|
@property (nonatomic, assign) BOOL isLoadEffect;
|
||||||
@property (nonatomic, strong) QXRoomChatListModel *playModel;
|
@property (nonatomic, strong) QXRoomChatListModel *playModel;
|
||||||
@property (nonatomic, assign) BOOL isPlaying;
|
@property (nonatomic, assign) BOOL isPlaying;
|
||||||
@property (nonatomic, assign) BOOL isBackground;
|
|
||||||
@end
|
@end
|
||||||
@implementation QXCPEffectView
|
@implementation QXCPEffectView
|
||||||
- (instancetype)initWithFrame:(CGRect)frame {
|
- (instancetype)initWithFrame:(CGRect)frame {
|
||||||
|
|||||||
@@ -84,7 +84,7 @@
|
|||||||
<action selector="upAction:" destination="KGk-i7-Jjw" eventType="touchUpInside" id="lXk-rU-fQZ"/>
|
<action selector="upAction:" destination="KGk-i7-Jjw" eventType="touchUpInside" id="lXk-rU-fQZ"/>
|
||||||
</connections>
|
</connections>
|
||||||
</button>
|
</button>
|
||||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="张三" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="wAY-Bl-81T">
|
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="wAY-Bl-81T">
|
||||||
<rect key="frame" x="204" y="57.666666666666657" width="60" height="18"/>
|
<rect key="frame" x="204" y="57.666666666666657" width="60" height="18"/>
|
||||||
<constraints>
|
<constraints>
|
||||||
<constraint firstAttribute="height" constant="18" id="8g8-R3-JIJ"/>
|
<constraint firstAttribute="height" constant="18" id="8g8-R3-JIJ"/>
|
||||||
@@ -94,7 +94,7 @@
|
|||||||
<color key="textColor" red="0.59999999999999998" green="0.59999999999999998" blue="0.59999999999999998" alpha="1" colorSpace="custom" customColorSpace="calibratedRGB"/>
|
<color key="textColor" red="0.59999999999999998" green="0.59999999999999998" blue="0.59999999999999998" alpha="1" colorSpace="custom" customColorSpace="calibratedRGB"/>
|
||||||
<nil key="highlightedColor"/>
|
<nil key="highlightedColor"/>
|
||||||
</label>
|
</label>
|
||||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="ID:123567" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="aET-0G-opo">
|
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="aET-0G-opo">
|
||||||
<rect key="frame" x="204" y="87.666666666666671" width="60" height="18"/>
|
<rect key="frame" x="204" y="87.666666666666671" width="60" height="18"/>
|
||||||
<constraints>
|
<constraints>
|
||||||
<constraint firstAttribute="height" constant="18" id="05u-LP-7ec"/>
|
<constraint firstAttribute="height" constant="18" id="05u-LP-7ec"/>
|
||||||
|
|||||||
@@ -51,8 +51,9 @@
|
|||||||
|
|
||||||
|
|
||||||
UICollectionViewFlowLayout *layout = [[UICollectionViewFlowLayout alloc] init];
|
UICollectionViewFlowLayout *layout = [[UICollectionViewFlowLayout alloc] init];
|
||||||
layout.minimumLineSpacing = 20;
|
// layout.minimumLineSpacing = 20;
|
||||||
layout.minimumInteritemSpacing = 20;
|
// layout.minimumInteritemSpacing = 20;
|
||||||
|
|
||||||
layout.sectionInset = UIEdgeInsetsMake(0, 50, 0, 50);
|
layout.sectionInset = UIEdgeInsetsMake(0, 50, 0, 50);
|
||||||
layout.scrollDirection = UICollectionViewScrollDirectionVertical;
|
layout.scrollDirection = UICollectionViewScrollDirectionVertical;
|
||||||
self.collectionView = [[UICollectionView alloc] initWithFrame:CGRectMake(0, self.titleLabel.bottom+10, self.bgView.width, self.bgView.height-self.titleLabel.bottom-20) collectionViewLayout:layout];
|
self.collectionView = [[UICollectionView alloc] initWithFrame:CGRectMake(0, self.titleLabel.bottom+10, self.bgView.width, self.bgView.height-self.titleLabel.bottom-20) collectionViewLayout:layout];
|
||||||
@@ -73,7 +74,14 @@
|
|||||||
}
|
}
|
||||||
-(void)getGiftList{
|
-(void)getGiftList{
|
||||||
MJWeakSelf
|
MJWeakSelf
|
||||||
[QXMineNetwork giftListWithLabel:@"99" roomId:self.roomId successBlock:^(NSArray<QXGiftModel *> * _Nonnull list) {
|
// [QXMineNetwork giftListWithLabel:@"99" roomId:self.roomId successBlock:^(NSArray<QXGiftModel *> * _Nonnull list) {
|
||||||
|
// [weakSelf.dataArray removeAllObjects];
|
||||||
|
// [weakSelf.dataArray addObjectsFromArray:list];
|
||||||
|
// [weakSelf.collectionView reloadData];
|
||||||
|
// } failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||||
|
//
|
||||||
|
// }];
|
||||||
|
[QXMineNetwork roomBarCabinRoomListWithRoomId:self.roomId successBlock:^(NSArray * _Nonnull list) {
|
||||||
[weakSelf.dataArray removeAllObjects];
|
[weakSelf.dataArray removeAllObjects];
|
||||||
[weakSelf.dataArray addObjectsFromArray:list];
|
[weakSelf.dataArray addObjectsFromArray:list];
|
||||||
[weakSelf.collectionView reloadData];
|
[weakSelf.collectionView reloadData];
|
||||||
@@ -94,8 +102,7 @@
|
|||||||
return cell;
|
return cell;
|
||||||
}
|
}
|
||||||
- (CGSize)collectionView:(UICollectionView *)collectionView layout:(UICollectionViewLayout*)collectionViewLayout sizeForItemAtIndexPath:(NSIndexPath *)indexPath{
|
- (CGSize)collectionView:(UICollectionView *)collectionView layout:(UICollectionViewLayout*)collectionViewLayout sizeForItemAtIndexPath:(NSIndexPath *)indexPath{
|
||||||
NSInteger itemWidth = (NSInteger)(SCREEN_WIDTH-50*2-20)/4;
|
return CGSizeMake(ScaleWidth(128), ScaleWidth(128));
|
||||||
return CGSizeMake(itemWidth, itemWidth);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
-(NSMutableArray *)dataArray{
|
-(NSMutableArray *)dataArray{
|
||||||
|
|||||||
@@ -244,7 +244,7 @@
|
|||||||
[self getGiftList];
|
[self getGiftList];
|
||||||
}
|
}
|
||||||
-(void)getGiftList{
|
-(void)getGiftList{
|
||||||
// MJWeakSelf
|
MJWeakSelf
|
||||||
// [QXMineNetwork giftListWithLabel:@"99" roomId:self.roomModel.room_info.room_id successBlock:^(NSArray<QXGiftModel *> * _Nonnull list) {
|
// [QXMineNetwork giftListWithLabel:@"99" roomId:self.roomModel.room_info.room_id successBlock:^(NSArray<QXGiftModel *> * _Nonnull list) {
|
||||||
// [weakSelf.dataArray removeAllObjects];
|
// [weakSelf.dataArray removeAllObjects];
|
||||||
// [weakSelf.dataArray addObjectsFromArray:list];
|
// [weakSelf.dataArray addObjectsFromArray:list];
|
||||||
@@ -259,7 +259,7 @@
|
|||||||
// } failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
// } failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||||
//
|
//
|
||||||
// }];
|
// }];
|
||||||
MJWeakSelf
|
// MJWeakSelf
|
||||||
[QXMineNetwork getRoomNewGiftListWithLabel:@"16" type:@"6" successBlock:^(NSArray<QXGiftModel *> * _Nonnull list) {
|
[QXMineNetwork getRoomNewGiftListWithLabel:@"16" type:@"6" successBlock:^(NSArray<QXGiftModel *> * _Nonnull list) {
|
||||||
[weakSelf.dataArray removeAllObjects];
|
[weakSelf.dataArray removeAllObjects];
|
||||||
[weakSelf.dataArray addObjectsFromArray:list];
|
[weakSelf.dataArray addObjectsFromArray:list];
|
||||||
@@ -277,6 +277,17 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
-(void)didSendGiftWithGiftModel:(QXGiftModel *)giftModel giftView:(QXRoomSeatBarCabinGiftView *)giftView{
|
-(void)didSendGiftWithGiftModel:(QXGiftModel *)giftModel giftView:(QXRoomSeatBarCabinGiftView *)giftView{
|
||||||
|
NSString *to_uid = @"";
|
||||||
|
if ([self.roomModel.cp_user.user_id isEqualToString:QXGlobal.shareGlobal.loginModel.user_id]) {
|
||||||
|
to_uid = self.roomModel.cp_user.user_id1;
|
||||||
|
}else{
|
||||||
|
to_uid = self.roomModel.cp_user.user_id;
|
||||||
|
}
|
||||||
|
[QXMineNetwork roomSendGiftWithRoomId:self.roomModel.room_info.room_id gift_id:giftModel.gift_id gift_num:@"1" to_uid:to_uid heart_id:@"" type:@"1" pit_number:@"" gift_bag_id:giftModel.gift_bag successBlock:^(NSDictionary * _Nonnull dict) {
|
||||||
|
|
||||||
|
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||||
|
showToast(msg);
|
||||||
|
}];
|
||||||
[giftView stopFloatingAnimation];
|
[giftView stopFloatingAnimation];
|
||||||
[UIView animateWithDuration:0.3 animations:^{
|
[UIView animateWithDuration:0.3 animations:^{
|
||||||
giftView.alpha = 0;
|
giftView.alpha = 0;
|
||||||
@@ -306,6 +317,7 @@
|
|||||||
}
|
}
|
||||||
-(void)friendCabinRoomTimeDelayWithTime:(NSString*)end_time{
|
-(void)friendCabinRoomTimeDelayWithTime:(NSString*)end_time{
|
||||||
self.roomModel.cp_user.time_day = end_time;
|
self.roomModel.cp_user.time_day = end_time;
|
||||||
|
[self stopTimer];
|
||||||
[self startTimer];
|
[self startTimer];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -77,6 +77,7 @@
|
|||||||
|
|
||||||
self.ruleBtn = [[UIButton alloc] init];
|
self.ruleBtn = [[UIButton alloc] init];
|
||||||
[self.rightSettingView addSubview:self.ruleBtn];
|
[self.rightSettingView addSubview:self.ruleBtn];
|
||||||
|
[self.ruleBtn addTarget:self action:@selector(ruleAction) forControlEvents:(UIControlEventTouchUpInside)];
|
||||||
[self.ruleBtn setBackgroundImage:[UIImage imageNamed:@"nobility_help_icon"] forState:(UIControlStateNormal)];
|
[self.ruleBtn setBackgroundImage:[UIImage imageNamed:@"nobility_help_icon"] forState:(UIControlStateNormal)];
|
||||||
|
|
||||||
self.giftBtn = [[UIButton alloc] init];
|
self.giftBtn = [[UIButton alloc] init];
|
||||||
@@ -285,6 +286,14 @@
|
|||||||
[giftView showInView:self.viewController.view];
|
[giftView showInView:self.viewController.view];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
-(void)ruleAction{
|
||||||
|
NSString *server = QXGlobal.shareGlobal.currentServer;
|
||||||
|
NSString *urlString = [NSString stringWithFormat:@"%@api/Page/page_show?id=%@",server,@"36"];
|
||||||
|
QXBaseWebViewController *vc = [[QXBaseWebViewController alloc] init];
|
||||||
|
vc.urlStr = urlString;
|
||||||
|
[self.viewController.navigationController pushViewController:vc animated:YES];
|
||||||
|
}
|
||||||
|
|
||||||
-(void)everyOneFollowMe{
|
-(void)everyOneFollowMe{
|
||||||
NSInteger count = 0;
|
NSInteger count = 0;
|
||||||
for (int i = 0 ; i < self.seatArray.count;i++) {
|
for (int i = 0 ; i < self.seatArray.count;i++) {
|
||||||
|
|||||||
@@ -302,6 +302,7 @@
|
|||||||
}
|
}
|
||||||
-(void)friendCabinRoomTimeDelayWithTime:(NSString*)end_time{
|
-(void)friendCabinRoomTimeDelayWithTime:(NSString*)end_time{
|
||||||
self.roomModel.cp_user.time_day = end_time;
|
self.roomModel.cp_user.time_day = end_time;
|
||||||
|
[self stopTimer];
|
||||||
[self startTimer];
|
[self startTimer];
|
||||||
}
|
}
|
||||||
-(void)closeAction{
|
-(void)closeAction{
|
||||||
|
|||||||
Reference in New Issue
Block a user