完成礼物功能
This commit is contained in:
@@ -52,6 +52,7 @@
|
||||
@property (nonatomic,strong)NSString *giftCount;
|
||||
|
||||
@property (nonatomic,strong)QXSendGiftCollectionView *bagGiftView;
|
||||
@property (nonatomic,strong)QXSendGiftCollectionView *roomHotCardView;
|
||||
|
||||
@property (nonatomic,strong)NSString *giftBagPrice;
|
||||
@property (nonatomic,strong)NSString *coin;
|
||||
@@ -347,6 +348,18 @@
|
||||
[self getMyWallet];
|
||||
}
|
||||
-(void)sendAllAction{
|
||||
if ([self.giftModel.label isEqualToString:@"1013"]) {
|
||||
MJWeakSelf
|
||||
QXCustomAlertView *alertView = [[QXCustomAlertView alloc] init];
|
||||
alertView.cancelBlock = ^{
|
||||
|
||||
};
|
||||
alertView.commitBlock = ^{
|
||||
[weakSelf sendAllRoomHotCardNetwork];
|
||||
};
|
||||
[alertView showInView:self.vc.view title:@"温馨提示" message:@"是否确认将房间热度卡全部送出" cancleTitle:nil commitTitle:nil];
|
||||
return;
|
||||
}
|
||||
if (self.pitUserListView.selectedArray.count == 0) {
|
||||
showToast(@"请选择送礼对象");
|
||||
return;
|
||||
@@ -366,6 +379,15 @@
|
||||
[alertView showInView:self.vc.view title:@"温馨提示" message:@"是否确认将背包礼物全部送出" cancleTitle:nil commitTitle:nil];
|
||||
|
||||
}
|
||||
-(void)sendAllRoomHotCardNetwork{
|
||||
MJWeakSelf
|
||||
[QXMineNetwork roomHotCardUseWithUdid:@"" room_id:self.roomId num:@"" successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
[weakSelf hide];
|
||||
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||
showToast(msg);
|
||||
}];
|
||||
}
|
||||
|
||||
// 一键清空网络请求
|
||||
-(void)sendAllNetWork{
|
||||
NSString *userId = [self.pitUserListView.selectedArray componentsJoinedByString:@","];
|
||||
@@ -385,8 +407,20 @@
|
||||
showToast(@"请选择礼物");
|
||||
return;
|
||||
}
|
||||
if (self.pitUserListView.selectedArray.count == 0) {
|
||||
showToast(@"请选择送礼对象");
|
||||
if (self.pitUserListView.isHidden == NO) {
|
||||
if (self.pitUserListView.selectedArray.count == 0) {
|
||||
showToast(@"请选择送礼对象");
|
||||
return;
|
||||
}
|
||||
}
|
||||
if ([self.giftModel.label isEqualToString:@"1013"]) {
|
||||
@weakify(self)
|
||||
[QXMineNetwork roomHotCardUseWithUdid:self.giftModel.gift_id room_id:self.roomId num:self.giftCount successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
@strongify(self)
|
||||
[self.roomHotCardView reloadData];
|
||||
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||
showToast(msg);
|
||||
}];
|
||||
return;
|
||||
}
|
||||
self.heartId = @"";
|
||||
@@ -552,33 +586,34 @@
|
||||
[self.bgView addSubview:self.pitUserListView];
|
||||
}
|
||||
-(void)getCategoryList{
|
||||
|
||||
NSString *type = @"1";
|
||||
if (self.type == QXSendGiftViewTypeFind) {
|
||||
type = @"2";
|
||||
}
|
||||
MJWeakSelf
|
||||
[QXMineNetwork giftLabelSuccessBlock:^(NSArray<QXGiftLabelModel *> * _Nonnull list) {
|
||||
[QXMineNetwork giftLabelWithType:type successBlock:^(NSArray<QXGiftLabelModel *> * _Nonnull list) {
|
||||
[weakSelf.titles removeAllObjects];
|
||||
[weakSelf.titles addObjectsFromArray:list];
|
||||
NSMutableArray *arr = [NSMutableArray array];
|
||||
|
||||
if (weakSelf.type != QXSendGiftViewTypeFind) {
|
||||
QXGiftLabelModel *model = [[QXGiftLabelModel alloc] init];
|
||||
model.name = @"背包";
|
||||
model.id = @"-10";
|
||||
[weakSelf.titles insertObject:model atIndex:0];
|
||||
weakSelf.categoryView.titles = arr;
|
||||
BOOL haveRoomHot = NO;
|
||||
for (QXGiftLabelModel*md in weakSelf.titles) {
|
||||
if ([md.id isEqualToString:@"1013"]) {
|
||||
haveRoomHot = YES;
|
||||
}
|
||||
[arr addObject:md.name];
|
||||
}
|
||||
[weakSelf.categoryView setDefaultSelectedIndex:1];
|
||||
[weakSelf.categoryView setDefaultSelectedIndex:haveRoomHot?2:1];
|
||||
[weakSelf.categoryView reloadData];
|
||||
}else{
|
||||
/// 在发现打赏时 不需要趣味 循环中剔除
|
||||
for (QXGiftLabelModel*md in list) {
|
||||
if ([md.id isEqualToString:@"2"]) {
|
||||
[weakSelf.titles removeObject:md];
|
||||
continue;
|
||||
}else{
|
||||
[arr addObject:md.name];
|
||||
}
|
||||
[arr addObject:md.name];
|
||||
}
|
||||
weakSelf.categoryView.titles = arr;
|
||||
[weakSelf.categoryView setDefaultSelectedIndex:0];
|
||||
@@ -626,13 +661,31 @@
|
||||
return;
|
||||
}
|
||||
if (index == 0) {
|
||||
[self.sendAllBtn setTitle:@"一键全送" forState:(UIControlStateNormal)];
|
||||
[self.sendBtn setTitle:@"赠送" forState:(UIControlStateNormal)];
|
||||
self.sendAllBtn.hidden = NO;
|
||||
self.cornLabel.text = self.giftBagPrice;
|
||||
self.rechargeBtn.hidden = YES;
|
||||
[self.rechargeBtn setTitle:@"去充值" forState:(UIControlStateNormal)];
|
||||
self.pitUserListView.hidden = NO;
|
||||
}else{
|
||||
self.cornLabel.text = self.coin;
|
||||
self.sendAllBtn.hidden = YES;
|
||||
self.rechargeBtn.hidden = !QXGlobal.shareGlobal.isOpenRecharge;
|
||||
QXGiftLabelModel *typeModel = self.titles[index];
|
||||
if ([typeModel.id isEqualToString:@"1013"]) {
|
||||
self.sendAllBtn.hidden = NO;
|
||||
[self.sendAllBtn setTitle:@"一键全用" forState:(UIControlStateNormal)];
|
||||
[self.sendBtn setTitle:@"使用" forState:(UIControlStateNormal)];
|
||||
self.rechargeBtn.hidden = NO;
|
||||
[self.rechargeBtn setTitle:@"去购买" forState:(UIControlStateNormal)];
|
||||
self.pitUserListView.hidden = YES;
|
||||
}else{
|
||||
self.pitUserListView.hidden = NO;
|
||||
[self.rechargeBtn setTitle:@"去充值" forState:(UIControlStateNormal)];
|
||||
[self.sendAllBtn setTitle:@"一键全送" forState:(UIControlStateNormal)];
|
||||
[self.sendBtn setTitle:@"赠送" forState:(UIControlStateNormal)];
|
||||
self.cornLabel.text = self.coin;
|
||||
self.sendAllBtn.hidden = YES;
|
||||
self.rechargeBtn.hidden = !QXGlobal.shareGlobal.isOpenRecharge;
|
||||
}
|
||||
}
|
||||
}
|
||||
- (NSInteger)numberOfListsInlistContainerView:(JXCategoryListContainerView *)listContainerView{
|
||||
@@ -645,6 +698,9 @@
|
||||
self.bagGiftView = subGiftView;
|
||||
}
|
||||
QXGiftLabelModel *md = self.titles[index];
|
||||
if ([md.id isEqualToString:@"1013"]) {
|
||||
self.roomHotCardView = subGiftView;
|
||||
}
|
||||
subGiftView.roomId = self.roomId;
|
||||
subGiftView.giftLabelId = md.id;
|
||||
subGiftView.type = self.type;
|
||||
|
||||
@@ -33,6 +33,8 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
@property (nonatomic,strong)NSString *label_icon;
|
||||
|
||||
@property (nonatomic,strong)NSString *hot_value;
|
||||
/// 房间密码
|
||||
@property (nonatomic,strong)NSString *room_password;
|
||||
@end
|
||||
|
||||
|
||||
|
||||
@@ -20,6 +20,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
@property (weak, nonatomic) IBOutlet UILabel *countLabel;
|
||||
@property (weak, nonatomic) IBOutlet UIImageView *roomTypeView;
|
||||
@property (weak, nonatomic) IBOutlet UIImageView *animateImageView;
|
||||
@property (weak, nonatomic) IBOutlet UIImageView *lockImageView;
|
||||
@property (strong, nonatomic) QXRoomListModel *model;
|
||||
@property (strong, nonatomic) QXMyRoomHistory *historyModel;
|
||||
|
||||
|
||||
@@ -17,6 +17,11 @@
|
||||
self.nameLabel.text = [NSString stringWithFormat:@"%@",model.room_name];
|
||||
self.appStoreNameLabel.text = [NSString stringWithFormat:@"%@",model.room_name];
|
||||
self.countLabel.text = [NSString qx_showHotCountNum:model.hot_value.longLongValue];
|
||||
if (model.room_password.length > 0) {
|
||||
self.lockImageView.hidden = NO;
|
||||
}else{
|
||||
self.lockImageView.hidden = YES;
|
||||
}
|
||||
// if ([model.label_id isEqualToString:@"23"]) {
|
||||
// self.roomTypeView.image = [UIImage imageNamed:@"Group 7153"];
|
||||
// }else if ([model.label_id isEqualToString:@"108"]){
|
||||
@@ -45,6 +50,11 @@
|
||||
self.nameLabel.text = [NSString stringWithFormat:@"%@",historyModel.room_name];
|
||||
self.countLabel.text = [NSString qx_showHotCountNum:historyModel.hot_value.longLongValue];
|
||||
[self.roomTypeView sd_setImageWithURL:[NSURL URLWithString:historyModel.label_icon]];
|
||||
if (historyModel.room_password.length > 0) {
|
||||
self.lockImageView.hidden = NO;
|
||||
}else{
|
||||
self.lockImageView.hidden = YES;
|
||||
}
|
||||
}
|
||||
-(void)setSearchModel:(QXSearchModel *)searchModel{
|
||||
_searchModel = searchModel;
|
||||
@@ -53,6 +63,11 @@
|
||||
self.nameLabel.text = [NSString stringWithFormat:@"%@",searchModel.name];
|
||||
self.countLabel.text = [NSString qx_showHotCountNum:searchModel.hot_value.longLongValue];
|
||||
[self.roomTypeView sd_setImageWithURL:[NSURL URLWithString:searchModel.label_icon]];
|
||||
if (searchModel.room_password.length > 0) {
|
||||
self.lockImageView.hidden = NO;
|
||||
}else{
|
||||
self.lockImageView.hidden = YES;
|
||||
}
|
||||
}
|
||||
-(void)setIsAppStore:(BOOL)isAppStore{
|
||||
_isAppStore = isAppStore;
|
||||
|
||||
@@ -134,6 +134,13 @@
|
||||
</userDefinedRuntimeAttribute>
|
||||
</userDefinedRuntimeAttributes>
|
||||
</label>
|
||||
<imageView hidden="YES" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="room_lock" translatesAutoresizingMaskIntoConstraints="NO" id="b7H-DA-VT1">
|
||||
<rect key="frame" x="117" y="124.66666666666669" width="60" height="60"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="width" constant="60" id="0VC-Nk-qpi"/>
|
||||
<constraint firstAttribute="height" constant="60" id="Grm-pw-rVy"/>
|
||||
</constraints>
|
||||
</imageView>
|
||||
</subviews>
|
||||
</view>
|
||||
<viewLayoutGuide key="safeArea" id="SEy-5g-ep8"/>
|
||||
@@ -151,10 +158,12 @@
|
||||
<constraint firstAttribute="trailing" secondItem="FdH-8c-jAP" secondAttribute="trailing" constant="12" id="Vg4-Bv-qiW"/>
|
||||
<constraint firstItem="nPz-Ym-vpk" firstAttribute="top" secondItem="gTV-IL-0wX" secondAttribute="top" id="WJN-ti-QhO"/>
|
||||
<constraint firstAttribute="bottom" secondItem="nPz-Ym-vpk" secondAttribute="bottom" id="aif-M8-0Jh"/>
|
||||
<constraint firstItem="b7H-DA-VT1" firstAttribute="centerX" secondItem="SEy-5g-ep8" secondAttribute="centerX" id="c4A-uP-tyu"/>
|
||||
<constraint firstAttribute="trailing" secondItem="EgE-mA-IY6" secondAttribute="trailing" constant="10" id="dhp-tQ-3T6"/>
|
||||
<constraint firstAttribute="bottom" secondItem="raq-XK-qhh" secondAttribute="bottom" id="eE2-ef-bWE"/>
|
||||
<constraint firstItem="qsd-Ig-Nmi" firstAttribute="top" secondItem="gTV-IL-0wX" secondAttribute="top" constant="8" id="gwT-Kf-zHQ"/>
|
||||
<constraint firstAttribute="trailing" secondItem="GYb-S9-FB8" secondAttribute="trailing" id="mDi-oS-hhJ"/>
|
||||
<constraint firstItem="b7H-DA-VT1" firstAttribute="centerY" secondItem="SEy-5g-ep8" secondAttribute="centerY" id="n2e-ZW-QaC"/>
|
||||
<constraint firstAttribute="trailing" secondItem="nPz-Ym-vpk" secondAttribute="trailing" id="nMO-wi-Ic7"/>
|
||||
<constraint firstItem="raq-XK-qhh" firstAttribute="leading" secondItem="gTV-IL-0wX" secondAttribute="leading" id="qAp-bv-ObA"/>
|
||||
<constraint firstAttribute="bottom" secondItem="074-Lr-sTa" secondAttribute="bottom" constant="10" id="wAO-bU-aoJ"/>
|
||||
@@ -168,6 +177,7 @@
|
||||
<outlet property="countLabel" destination="BSc-rv-bf4" id="3DZ-sZ-CCV"/>
|
||||
<outlet property="coverImageView" destination="nPz-Ym-vpk" id="3tk-L4-05N"/>
|
||||
<outlet property="displayMaskView" destination="raq-XK-qhh" id="gYi-Af-gep"/>
|
||||
<outlet property="lockImageView" destination="b7H-DA-VT1" id="hwD-BK-2VC"/>
|
||||
<outlet property="nameLabel" destination="V8F-du-Rah" id="Ah9-Wd-QZJ"/>
|
||||
<outlet property="roomTypeView" destination="GYb-S9-FB8" id="Tgr-f6-Qla"/>
|
||||
</connections>
|
||||
@@ -177,5 +187,6 @@
|
||||
<resources>
|
||||
<image name="Flow 10001.png" width="150" height="115"/>
|
||||
<image name="room_hot_icon" width="14" height="14"/>
|
||||
<image name="room_lock" width="40" height="40"/>
|
||||
</resources>
|
||||
</document>
|
||||
|
||||
@@ -12,6 +12,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
@interface QXHomeTopRoomCell : UICollectionViewCell
|
||||
@property (weak, nonatomic) IBOutlet UIImageView *roomImageView;
|
||||
@property (weak, nonatomic) IBOutlet UILabel *roomNameLabel;
|
||||
@property (weak, nonatomic) IBOutlet UIImageView *lockImageView;
|
||||
@property (strong, nonatomic)QXRoomListModel *model ;
|
||||
@end
|
||||
|
||||
|
||||
@@ -12,6 +12,11 @@
|
||||
_model = model;
|
||||
[self.roomImageView sd_setImageWithURL:[NSURL URLWithString:model.room_cover]];
|
||||
self.roomNameLabel.text = model.room_name;
|
||||
if (model.room_password.length > 0) {
|
||||
self.lockImageView.hidden = NO;
|
||||
}else{
|
||||
self.lockImageView.hidden = YES;
|
||||
}
|
||||
}
|
||||
- (void)awakeFromNib {
|
||||
[super awakeFromNib];
|
||||
|
||||
@@ -38,23 +38,36 @@
|
||||
</userDefinedRuntimeAttribute>
|
||||
</userDefinedRuntimeAttributes>
|
||||
</imageView>
|
||||
<imageView hidden="YES" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="room_lock" translatesAutoresizingMaskIntoConstraints="NO" id="YUp-7L-lc8">
|
||||
<rect key="frame" x="115" y="88.666666666666671" width="60" height="60.000000000000014"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="width" constant="60" id="aX0-46-fMv"/>
|
||||
<constraint firstAttribute="height" constant="60" id="nk1-hA-uPY"/>
|
||||
</constraints>
|
||||
</imageView>
|
||||
</subviews>
|
||||
</view>
|
||||
<viewLayoutGuide key="safeArea" id="SEy-5g-ep8"/>
|
||||
<constraints>
|
||||
<constraint firstItem="AMc-ga-z0u" firstAttribute="top" secondItem="IPW-qC-f1g" secondAttribute="bottom" constant="8" id="1ZJ-sM-LA1"/>
|
||||
<constraint firstItem="IPW-qC-f1g" firstAttribute="centerX" secondItem="SEy-5g-ep8" secondAttribute="centerX" id="6SI-qJ-0va"/>
|
||||
<constraint firstItem="YUp-7L-lc8" firstAttribute="centerX" secondItem="IPW-qC-f1g" secondAttribute="centerX" id="Eqv-La-nLc"/>
|
||||
<constraint firstItem="IPW-qC-f1g" firstAttribute="top" secondItem="gTV-IL-0wX" secondAttribute="top" id="Jl7-NF-LFZ"/>
|
||||
<constraint firstAttribute="trailing" secondItem="AMc-ga-z0u" secondAttribute="trailing" constant="8" id="hbX-iy-3L1"/>
|
||||
<constraint firstItem="YUp-7L-lc8" firstAttribute="centerY" secondItem="IPW-qC-f1g" secondAttribute="centerY" id="jbx-Pj-cFH"/>
|
||||
<constraint firstAttribute="bottom" secondItem="AMc-ga-z0u" secondAttribute="bottom" constant="8" id="lMB-en-E1D"/>
|
||||
<constraint firstItem="AMc-ga-z0u" firstAttribute="leading" secondItem="gTV-IL-0wX" secondAttribute="leading" constant="8" id="zX4-9M-96x"/>
|
||||
</constraints>
|
||||
<size key="customSize" width="290" height="267"/>
|
||||
<connections>
|
||||
<outlet property="lockImageView" destination="YUp-7L-lc8" id="vte-w2-IGo"/>
|
||||
<outlet property="roomImageView" destination="IPW-qC-f1g" id="Aub-Kv-UEF"/>
|
||||
<outlet property="roomNameLabel" destination="AMc-ga-z0u" id="3nx-VQ-OCq"/>
|
||||
</connections>
|
||||
<point key="canvasLocation" x="320.61068702290078" y="96.126760563380287"/>
|
||||
</collectionViewCell>
|
||||
</objects>
|
||||
<resources>
|
||||
<image name="room_lock" width="40" height="40"/>
|
||||
</resources>
|
||||
</document>
|
||||
|
||||
@@ -42,6 +42,12 @@
|
||||
//@property (nonatomic,strong) UILabel *lineLabel;
|
||||
//@property (nonatomic,strong) UILabel *endLabel;
|
||||
|
||||
@property (nonatomic,strong)UILabel *priviteLabel;
|
||||
@property (nonatomic,strong)UIButton *priviteBtn;
|
||||
@property (nonatomic,strong)UIView *bottomBgView;
|
||||
@property (nonatomic,strong)UITextField *passwordTextField;
|
||||
@property (nonatomic,strong) UIButton *pwdDeleteBtn;
|
||||
|
||||
@property (nonatomic,strong) QXTimer *timer;
|
||||
//@property (nonatomic,strong)QXDatePickerView* pickerView;
|
||||
@end
|
||||
@@ -173,6 +179,60 @@
|
||||
make.bottom.mas_equalTo(-5);
|
||||
}];
|
||||
|
||||
self.priviteLabel = [[UILabel alloc] init];
|
||||
self.priviteLabel.font = [UIFont boldSystemFontOfSize:15];
|
||||
self.priviteLabel.textColor = RGB16A(0x000000, 0.45);
|
||||
self.priviteLabel.text = QXText(@"是否设置密码");
|
||||
[self.view addSubview:self.priviteLabel];
|
||||
[self.priviteLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.top.equalTo(self.noticeBgView.mas_bottom).offset(12);
|
||||
make.left.equalTo(self.roomNameLabel);
|
||||
make.height.mas_equalTo(24);
|
||||
}];
|
||||
|
||||
self.priviteBtn = [[UIButton alloc] init];
|
||||
[self.priviteBtn setImage:[UIImage imageNamed:@"home_switch_off"] forState:(UIControlStateNormal)];
|
||||
[self.priviteBtn setImage:[UIImage imageNamed:@"home_switch_on"] forState:(UIControlStateSelected)];
|
||||
[self.priviteBtn addTarget:self action:@selector(priviteAction) forControlEvents:(UIControlEventTouchUpInside)];
|
||||
[self.view addSubview:self.priviteBtn];
|
||||
[self.priviteBtn mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.right.mas_equalTo(-16);
|
||||
make.width.mas_equalTo(40);
|
||||
make.height.mas_equalTo(35);
|
||||
make.centerY.equalTo(self.priviteLabel);
|
||||
}];
|
||||
|
||||
|
||||
self.bottomBgView = [[UIView alloc] init];
|
||||
[self.bottomBgView addRoundedCornersWithRadius:11];
|
||||
self.bottomBgView.backgroundColor = RGB16(0xEFF2F8);
|
||||
[self.view addSubview:self.bottomBgView];
|
||||
self.passwordTextField = [[UITextField alloc] initWithFrame:CGRectMake(12, 0, self.bottomBgView.width-34, 44)];
|
||||
self.passwordTextField.placeholder = @"请输入房间密码(4位数字)";
|
||||
self.passwordTextField.font = [UIFont systemFontOfSize:16];
|
||||
// self.passwordTextField.secureTextEntry = YES;
|
||||
self.passwordTextField.keyboardType = UIKeyboardTypeNumberPad;
|
||||
self.passwordTextField.delegate = self;
|
||||
[self.passwordTextField addTarget:self action:@selector(textFieldDidChanged:) forControlEvents:UIControlEventEditingChanged];
|
||||
[self.bottomBgView addSubview:self.passwordTextField];
|
||||
[self.bottomBgView addSubview:self.pwdDeleteBtn];
|
||||
self.bottomBgView.hidden = YES;
|
||||
[self.bottomBgView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.top.equalTo(self.priviteLabel.mas_bottom).offset(12);
|
||||
make.left.equalTo(self.roomNameLabel);
|
||||
make.right.mas_equalTo(-16);
|
||||
make.height.mas_equalTo(44);
|
||||
}];
|
||||
[self.pwdDeleteBtn mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.top.bottom.equalTo(self.bottomBgView);
|
||||
make.right.equalTo(self.bottomBgView).offset(-12);
|
||||
make.width.mas_equalTo(44);
|
||||
}];
|
||||
[self.passwordTextField mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.top.bottom.equalTo(self.bottomBgView);
|
||||
make.left.equalTo(self.bottomBgView).offset(12);
|
||||
make.right.equalTo(self.pwdDeleteBtn.mas_left).offset(-4);
|
||||
}];
|
||||
|
||||
|
||||
[self.view addSubview:self.submitBtn];
|
||||
@@ -207,6 +267,15 @@
|
||||
if ([self.roomModel.room_info.room_intro isExist]) {
|
||||
self.textView.placehoulderLabel.hidden = YES;
|
||||
}
|
||||
if (self.roomModel.room_info.room_password.length > 0) {
|
||||
self.bottomBgView.hidden = NO;
|
||||
self.priviteBtn.selected = YES;
|
||||
self.passwordTextField.text = self.roomModel.room_info.room_password;
|
||||
}else{
|
||||
self.priviteBtn.selected = NO;
|
||||
self.bottomBgView.hidden = YES;
|
||||
self.passwordTextField.text = @"";
|
||||
}
|
||||
self.roomCoverUrl = self.roomModel.room_info.room_cover;
|
||||
[self.submitBtn setTitle:QXText(@"确认修改") forState:UIControlStateNormal];
|
||||
self.warningLabel.hidden = YES;
|
||||
@@ -218,8 +287,18 @@
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
-(void)priviteAction{
|
||||
self.priviteBtn.selected = !self.priviteBtn.selected;
|
||||
if (self.priviteBtn.selected) {
|
||||
self.bottomBgView.hidden = NO;
|
||||
}else{
|
||||
self.bottomBgView.hidden = YES;
|
||||
self.passwordTextField.text = @"";
|
||||
}
|
||||
}
|
||||
-(void)clearPwdAction{
|
||||
self.passwordTextField.text = @"";
|
||||
}
|
||||
-(void)getRandomName{
|
||||
MJWeakSelf
|
||||
[QXMineNetwork getRoomRandomNameSuccessBlock:^(NSString * _Nonnull name) {
|
||||
@@ -238,13 +317,24 @@
|
||||
showToast(@"请上传房间封面");
|
||||
return;
|
||||
}
|
||||
if (self.priviteBtn.selected == YES) {
|
||||
if (self.passwordTextField.text.length == 0) {
|
||||
showToast(@"请输入房间密码");
|
||||
return;
|
||||
}
|
||||
if (self.passwordTextField.text.length > 4) {
|
||||
showToast(@"房间密码只能是4位数字组成");
|
||||
return;
|
||||
}
|
||||
}
|
||||
MJWeakSelf
|
||||
if (self.roomModel) {
|
||||
[QXMineNetwork roomInfoEditWithRoomId:self.roomModel.room_info.room_id room_name:self.textField.text room_cover:self.roomCoverUrl room_intro:self.textView.text room_background:@"" successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
[QXMineNetwork roomInfoEditWithRoomId:self.roomModel.room_info.room_id room_name:self.textField.text room_cover:self.roomCoverUrl room_intro:self.textView.text room_background:self.roomModel.room_info.room_background room_password:self.passwordTextField.text successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
if (weakSelf.editSucceessBlock) {
|
||||
weakSelf.roomModel.room_info.room_name = weakSelf.textField.text;
|
||||
weakSelf.roomModel.room_info.room_cover = weakSelf.roomCoverUrl;
|
||||
weakSelf.roomModel.room_info.room_intro = weakSelf.textView.text;
|
||||
weakSelf.roomModel.room_info.room_password = weakSelf.passwordTextField.text;
|
||||
weakSelf.editSucceessBlock(weakSelf.roomModel);
|
||||
}
|
||||
[weakSelf.navigationController popViewControllerAnimated:YES];
|
||||
@@ -252,7 +342,7 @@
|
||||
showToast(msg)
|
||||
}];
|
||||
}else{
|
||||
[QXMineNetwork createRoomWithName:self.textField.text room_cover:self.roomCoverUrl room_intro:self.textView.text successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
[QXMineNetwork createRoomWithName:self.textField.text room_cover:self.roomCoverUrl room_intro:self.textView.text room_password:self.passwordTextField.text successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
if (weakSelf.createSucceessBlock) {
|
||||
weakSelf.createSucceessBlock();
|
||||
}
|
||||
@@ -335,12 +425,34 @@
|
||||
|
||||
#pragma mark - UITextFieldDelegate
|
||||
- (BOOL)textFieldShouldReturn:(UITextField *)textField {
|
||||
return [self.textField resignFirstResponder];
|
||||
[textField resignFirstResponder];
|
||||
return YES;
|
||||
}
|
||||
//-(void)textFieldDidBeginEditing:(UITextField *)textField{
|
||||
// if (textField == self.passwordTextField) {
|
||||
// [UIView animateWithDuration:0.1 animations:^{
|
||||
// self.view.y = 550;
|
||||
// }];
|
||||
// }
|
||||
//}
|
||||
//-(void)textFieldDidEndEditing:(UITextField *)textField{
|
||||
// if (textField == self.passwordTextField) {
|
||||
// [UIView animateWithDuration:0.1 animations:^{
|
||||
// self.view.y = 0;
|
||||
// }];
|
||||
// }
|
||||
//}
|
||||
- (void)textFieldDidChanged:(UITextField *)textField {
|
||||
if (textField.text.length > 20) {
|
||||
[textField deleteBackward];
|
||||
if (textField == self.textField) {
|
||||
if (textField.text.length > 20) {
|
||||
[textField deleteBackward];
|
||||
}
|
||||
}else{
|
||||
if (textField.text.length == 4) {
|
||||
[textField resignFirstResponder];
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#pragma mark - Btn Click
|
||||
@@ -397,6 +509,14 @@
|
||||
}
|
||||
return _deleteBtn;
|
||||
}
|
||||
-(UIButton *)pwdDeleteBtn{
|
||||
if (!_pwdDeleteBtn) {
|
||||
_pwdDeleteBtn = [[UIButton alloc] init];
|
||||
[_pwdDeleteBtn setImage:[UIImage imageNamed:@"Plus Circle"] forState:(UIControlStateNormal)];
|
||||
[_pwdDeleteBtn addTarget:self action:@selector(clearPwdAction) forControlEvents:(UIControlEventTouchUpInside)];
|
||||
}
|
||||
return _pwdDeleteBtn;
|
||||
}
|
||||
- (UITextField *)textField {
|
||||
if (!_textField) {
|
||||
_textField = [[UITextField alloc] init];
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
#import "QXGiftCell.h"
|
||||
#import "QXBackpackRecordCell.h"
|
||||
#import "QXMineNetwork.h"
|
||||
#import "QXDressCell.h"
|
||||
|
||||
@interface QXBackpackSubViewController ()<UICollectionViewDelegate,UICollectionViewDataSource,UICollectionViewDelegateFlowLayout>
|
||||
@property (nonatomic,strong)UICollectionView *collectionView;
|
||||
@@ -29,7 +30,7 @@
|
||||
[self getBagList];
|
||||
self.collectionView.frame = CGRectMake(0, 12, SCREEN_WIDTH, SCREEN_HEIGHT-NavContentHeight-44-10);
|
||||
}else if(self.type == 1){
|
||||
[self getBagList];
|
||||
[self getHotCardList];
|
||||
self.collectionView.frame = CGRectMake(0, 12, SCREEN_WIDTH, SCREEN_HEIGHT-NavContentHeight-44-10);
|
||||
}else if(self.type == 2){
|
||||
[self getGiftRecordListIsIncome:YES];
|
||||
@@ -57,7 +58,21 @@
|
||||
[weakSelf.collectionView.mj_footer endRefreshing];
|
||||
}];
|
||||
}
|
||||
|
||||
-(void)getHotCardList{
|
||||
@weakify(self)
|
||||
[QXMineNetwork userDressListWithType:@"13" successBlock:^(NSArray<QXUserDressModel *> * _Nonnull list) {
|
||||
@strongify(self);
|
||||
[self.dataArray removeAllObjects];
|
||||
[self.dataArray addObjectsFromArray:list];
|
||||
[self.collectionView reloadData];
|
||||
[self.collectionView.mj_header endRefreshing];
|
||||
[self.collectionView.mj_footer endRefreshing];
|
||||
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||
@strongify(self);
|
||||
[self.collectionView.mj_header endRefreshing];
|
||||
[self.collectionView.mj_footer endRefreshing];
|
||||
}];
|
||||
}
|
||||
-(void)getGiftRecordListIsIncome:(BOOL)isIncom{
|
||||
MJWeakSelf
|
||||
if (isIncom) {
|
||||
@@ -103,11 +118,15 @@
|
||||
return self.dataArray.count;
|
||||
}
|
||||
-(__kindof UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath{
|
||||
if (self.type == 0 || self.type == 1) {
|
||||
if (self.type == 0) {
|
||||
QXGiftCell *cell = [collectionView dequeueReusableCellWithReuseIdentifier:@"QXGiftCell" forIndexPath:indexPath];
|
||||
cell.roomGiftModel = self.dataArray[indexPath.row];
|
||||
cell.cellType = QXGiftCellTypeBackpack;
|
||||
return cell;
|
||||
}else if(self.type == 1){
|
||||
QXDressCell *cell = [collectionView dequeueReusableCellWithReuseIdentifier:@"QXDressCell" forIndexPath:indexPath];
|
||||
cell.model = self.dataArray[indexPath.row];
|
||||
return cell;
|
||||
}else{
|
||||
QXBackpackRecordCell *cell = [collectionView dequeueReusableCellWithReuseIdentifier:@"QXBackpackRecordCell" forIndexPath:indexPath];
|
||||
if (indexPath.row == (self.dataArray.count - 1)) {
|
||||
@@ -150,6 +169,7 @@
|
||||
_collectionView.dataSource = self;
|
||||
_collectionView.backgroundColor = [UIColor clearColor];
|
||||
[_collectionView registerNib:[UINib nibWithNibName:@"QXGiftCell" bundle:[NSBundle mainBundle]] forCellWithReuseIdentifier:@"QXGiftCell"];
|
||||
[_collectionView registerNib:[UINib nibWithNibName:@"QXDressCell" bundle:[NSBundle mainBundle]] forCellWithReuseIdentifier:@"QXDressCell"];
|
||||
[_collectionView registerNib:[UINib nibWithNibName:@"QXBackpackRecordCell" bundle:[NSBundle mainBundle]] forCellWithReuseIdentifier:@"QXBackpackRecordCell"];
|
||||
MJWeakSelf
|
||||
_collectionView.mj_header = [MJRefreshNormalHeader headerWithRefreshingBlock:^{
|
||||
|
||||
@@ -69,7 +69,7 @@
|
||||
}
|
||||
-(void)getData{
|
||||
MJWeakSelf
|
||||
[QXMineNetwork getDressTypeListWithFrom:@"2" successBlock:^(NSArray<QXUserDressTypeModel *> * _Nonnull list) {
|
||||
[QXMineNetwork getDressTypeListWithFrom:@"1" successBlock:^(NSArray<QXUserDressTypeModel *> * _Nonnull list) {
|
||||
[weakSelf.dataArray removeAllObjects];
|
||||
[weakSelf.dataArray addObjectsFromArray:list];
|
||||
for (QXUserDressTypeModel*model in list) {
|
||||
|
||||
@@ -45,6 +45,8 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
/// 当前钱包余额
|
||||
@property (nonatomic,strong)NSString *user_wallet_coin;
|
||||
/// 当前礼物所在标签 (只针对热度卡)
|
||||
@property (nonatomic,strong)NSString *label;
|
||||
|
||||
@property (nonatomic,assign)BOOL isSelected;
|
||||
@end
|
||||
|
||||
@@ -88,6 +88,8 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
@property (nonatomic,strong)NSString *start_time;
|
||||
/// 酒吧房撩人所需金币数
|
||||
@property (nonatomic,strong)NSString *end_time;
|
||||
/// 房间密码
|
||||
@property (nonatomic,strong)NSString *room_password;
|
||||
@end
|
||||
|
||||
|
||||
|
||||
@@ -278,6 +278,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
+(void)createRoomWithName:(NSString*)name
|
||||
room_cover:(NSString*)room_cover
|
||||
room_intro:(NSString*)room_intro
|
||||
room_password:(NSString*)room_password
|
||||
successBlock:(void (^)(NSDictionary* dict))successBlock
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock;
|
||||
|
||||
@@ -334,8 +335,9 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
/**
|
||||
礼物标签列表
|
||||
*/
|
||||
+(void)giftLabelSuccessBlock:(void (^)(NSArray<QXGiftLabelModel*>* list))successBlock
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock;
|
||||
+(void)giftLabelWithType:(NSString*)type
|
||||
successBlock:(void (^)(NSArray<QXGiftLabelModel*>* list))successBlock
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock;
|
||||
|
||||
|
||||
/**
|
||||
@@ -578,6 +580,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
room_cover:(NSString*)room_cover
|
||||
room_intro:(NSString*)room_intro
|
||||
room_background:(NSString*)room_background
|
||||
room_password:(NSString*)room_password
|
||||
successBlock:(void (^)(NSDictionary* dict))successBlock
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock;
|
||||
|
||||
@@ -1618,6 +1621,14 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
successBlock:(void (^)(NSArray<QXUserHomeModel*>* list,NSString*count))successBlock
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock;
|
||||
|
||||
/**
|
||||
用户房间热度卡使用
|
||||
*/
|
||||
+(void)roomHotCardUseWithUdid:(NSString*)udid
|
||||
room_id:(NSString*)room_id
|
||||
num:(NSString*)num
|
||||
successBlock:(void (^)(NSDictionary* dict))successBlock
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock;
|
||||
@end
|
||||
|
||||
|
||||
|
||||
@@ -490,7 +490,7 @@
|
||||
+(void)getDressTypeListWithFrom:(NSString*)type
|
||||
successBlock:(void (^)(NSArray<QXUserDressTypeModel *> * _Nonnull))successBlock
|
||||
failBlock:(void (^)(NSError * _Nonnull, NSString * _Nonnull))failBlock{
|
||||
[[QXRequset shareInstance] postWithUrl:QXDressTypeList parameters:@{@"type":type?type:@""} needCache:NO success:^(id responseObject) {
|
||||
[[QXRequset shareInstance] postWithUrl:QXDressTypeList parameters:@{@"from":type?type:@""} needCache:NO success:^(id responseObject) {
|
||||
if (successBlock) {
|
||||
NSArray *list = [NSArray yy_modelArrayWithClass:[QXUserDressTypeModel class] json:responseObject[@"data"]];
|
||||
successBlock(list);
|
||||
@@ -546,11 +546,12 @@
|
||||
}
|
||||
|
||||
|
||||
+(void)createRoomWithName:(NSString *)name room_cover:(NSString *)room_cover room_intro:(NSString *)room_intro successBlock:(void (^)(NSDictionary * _Nonnull))successBlock failBlock:(void (^)(NSError * _Nonnull, NSString * _Nonnull))failBlock{
|
||||
+(void)createRoomWithName:(NSString *)name room_cover:(NSString *)room_cover room_intro:(NSString *)room_intro room_password:(NSString*)room_password successBlock:(void (^)(NSDictionary * _Nonnull))successBlock failBlock:(void (^)(NSError * _Nonnull, NSString * _Nonnull))failBlock{
|
||||
NSDictionary *parameters =@{
|
||||
@"room_name":name,
|
||||
@"room_cover":room_cover?room_cover:@"",
|
||||
@"room_intro":room_intro?room_intro:@"",
|
||||
@"room_password":room_password?:@""
|
||||
};
|
||||
[[QXRequset shareInstance] getWithUrl:QXCreatRoom parameters:parameters needCache:NO success:^(id responseObject) {
|
||||
if (successBlock) {
|
||||
@@ -684,11 +685,12 @@
|
||||
|
||||
/**
|
||||
礼物标签列表
|
||||
type 房间 1 动态打赏 2
|
||||
*/
|
||||
+(void)giftLabelSuccessBlock:(void (^)(NSArray<QXGiftLabelModel*>* list))successBlock
|
||||
+(void)giftLabelWithType:(NSString*)type
|
||||
successBlock:(void (^)(NSArray<QXGiftLabelModel*>* list))successBlock
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock{
|
||||
|
||||
[[QXRequset shareInstance] getWithUrl:QXGiftLabel parameters:@{} needCache:NO success:^(id responseObject) {
|
||||
[[QXRequset shareInstance] getWithUrl:QXGiftLabel parameters:@{@"type":type?:@""} needCache:NO success:^(id responseObject) {
|
||||
NSArray *list = [NSArray yy_modelArrayWithClass:[QXGiftLabelModel class] json:responseObject[@"data"]];
|
||||
successBlock(list);
|
||||
} fail:^(NSError *error, NSString *msg, NSURLSessionDataTask *task) {
|
||||
@@ -699,6 +701,8 @@
|
||||
|
||||
/**
|
||||
礼物列表
|
||||
排麦插队礼物,id传递的是0,
|
||||
歌单礼物,传递的id是100
|
||||
*/
|
||||
+(void)giftListWithLabel:(NSString*)label
|
||||
roomId:(NSString*)roomId
|
||||
@@ -1175,13 +1179,16 @@
|
||||
room_name:(NSString *)room_name
|
||||
room_cover:(NSString *)room_cover
|
||||
room_intro:(NSString *)room_intro
|
||||
room_background:(NSString *)room_background successBlock:(void (^)(NSDictionary * _Nonnull))successBlock failBlock:(void (^)(NSError * _Nonnull, NSString * _Nonnull))failBlock{
|
||||
room_background:(NSString *)room_background
|
||||
room_password:(NSString*)room_password
|
||||
successBlock:(void (^)(NSDictionary * _Nonnull))successBlock failBlock:(void (^)(NSError * _Nonnull, NSString * _Nonnull))failBlock{
|
||||
NSDictionary *parameters =@{
|
||||
@"room_id":roomId,
|
||||
@"room_name":room_name?room_name:@"",
|
||||
@"room_cover":room_cover?room_cover:@"",
|
||||
@"room_intro":room_name?room_intro:@"",
|
||||
@"room_background":room_background?room_background:@"",
|
||||
@"room_password":room_password?:@""
|
||||
};
|
||||
[[QXRequset shareInstance] postWithUrl:QXRoomInfoEdit parameters:parameters needCache:NO success:^(id responseObject) {
|
||||
if (successBlock) {
|
||||
@@ -3323,5 +3330,26 @@
|
||||
failBlock(error,msg);
|
||||
}];
|
||||
}
|
||||
/**
|
||||
用户房间热度卡使用
|
||||
*/
|
||||
+(void)roomHotCardUseWithUdid:(NSString*)udid
|
||||
room_id:(NSString*)room_id
|
||||
num:(NSString*)num
|
||||
successBlock:(void (^)(NSDictionary* dict))successBlock
|
||||
failBlock:(void (^)(NSError * error, NSString * msg))failBlock{
|
||||
NSDictionary *parameters =@{
|
||||
@"udid":udid?:@"",
|
||||
@"room_id":room_id?:@"",
|
||||
@"num":num?:@""
|
||||
};
|
||||
[[QXRequset shareInstance] postWithUrl:QXUseRoomHotCard parameters:parameters needCache:NO success:^(id responseObject) {
|
||||
if (successBlock) {
|
||||
successBlock(responseObject[@"data"]);
|
||||
}
|
||||
} fail:^(NSError *error, NSString *msg, NSURLSessionDataTask *task) {
|
||||
failBlock(error,msg);
|
||||
}];
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
_model = model;
|
||||
self.nameLabel.text = model.title;
|
||||
[self.dressImageView sd_setImageWithURL:[NSURL URLWithString:model.base_image]];
|
||||
if ([model.type isEqualToString:@"12"]) {
|
||||
if ([model.type isEqualToString:@"12"] || [model.type isEqualToString:@"13"]) {
|
||||
self.timeLabel.text = [NSString stringWithFormat:@"x%@",model.num];
|
||||
}else{
|
||||
self.timeLabel.text = [NSString stringWithFormat:@"%@%@",model.remaining_day,QXText(@"天")];
|
||||
|
||||
@@ -150,7 +150,7 @@
|
||||
|
||||
-(void)getGiftList{
|
||||
MJWeakSelf
|
||||
[QXMineNetwork giftListWithLabel:@"1" roomId:@"" successBlock:^(NSArray<QXGiftModel *> * _Nonnull list) {
|
||||
[QXMineNetwork giftListWithLabel:@"100" roomId:@"" successBlock:^(NSArray<QXGiftModel *> * _Nonnull list) {
|
||||
[weakSelf.dataArray removeAllObjects];
|
||||
[weakSelf.dataArray addObjectsFromArray:list];
|
||||
[weakSelf.collectionView reloadData];
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
self.userCountLabel.text = [NSString stringWithFormat:@"等%@人",model.top_users_count];
|
||||
|
||||
if (model.top_users.count > 0) {
|
||||
// self.countLabel.hidden = NO;
|
||||
self.countLabel.hidden = NO;
|
||||
self.userCountLabel.hidden = NO;
|
||||
QXUserHomeModel *md1;
|
||||
QXUserHomeModel *md2;
|
||||
@@ -89,7 +89,7 @@
|
||||
}
|
||||
|
||||
}else{
|
||||
// self.countLabel.hidden = YES;
|
||||
self.countLabel.hidden = YES;
|
||||
self.userCountLabel.hidden = YES;
|
||||
self.userImageView1.hidden = YES;
|
||||
self.userImageView2.hidden = YES;
|
||||
|
||||
22
QXLive/Other/Assets.xcassets/home/room_lock.imageset/Contents.json
vendored
Normal file
22
QXLive/Other/Assets.xcassets/home/room_lock.imageset/Contents.json
vendored
Normal file
@@ -0,0 +1,22 @@
|
||||
{
|
||||
"images" : [
|
||||
{
|
||||
"idiom" : "universal",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"filename" : "room_lock@2x.png",
|
||||
"idiom" : "universal",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"filename" : "room_lock@3x.png",
|
||||
"idiom" : "universal",
|
||||
"scale" : "3x"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"author" : "xcode",
|
||||
"version" : 1
|
||||
}
|
||||
}
|
||||
BIN
QXLive/Other/Assets.xcassets/home/room_lock.imageset/room_lock@2x.png
vendored
Normal file
BIN
QXLive/Other/Assets.xcassets/home/room_lock.imageset/room_lock@2x.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 13 KiB |
BIN
QXLive/Other/Assets.xcassets/home/room_lock.imageset/room_lock@3x.png
vendored
Normal file
BIN
QXLive/Other/Assets.xcassets/home/room_lock.imageset/room_lock@3x.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 26 KiB |
@@ -630,4 +630,6 @@ static NSString * QXRoomSetTime = @"api/Room/set_room_business_time";
|
||||
static NSString * QXRoomPKCloseMic = @"api/RoomPk/close_pk_mic";
|
||||
/// 礼物墙用户列表
|
||||
static NSString * QXUserGiftWallUserList = @"api/User/gift_wall_user_list";
|
||||
/// 热度卡使用
|
||||
static NSString * QXUseRoomHotCard = @"api/Decorate/room_hot_card";
|
||||
#endif /* Api_h */
|
||||
|
||||
@@ -1655,6 +1655,7 @@ QXUpSeatViewDelegate
|
||||
break;
|
||||
case QXRoomSettingTypeRoomBgImage:{
|
||||
self.roomBgSetView.roomId = self.roomId;
|
||||
self.roomBgSetView.roomPassword = self.roomModel.room_info.room_password;
|
||||
[self.roomBgSetView showInView:self.view];
|
||||
[self.settingView hide];
|
||||
}
|
||||
|
||||
@@ -11,6 +11,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@interface QXRoomBgSettingView : UIView
|
||||
@property (nonatomic,strong)NSString *roomId;
|
||||
@property (nonatomic,strong)NSString *roomPassword;
|
||||
-(void)showInView:(UIView *)view;
|
||||
@end
|
||||
|
||||
|
||||
@@ -163,7 +163,7 @@
|
||||
|
||||
-(void)changeRoomBgWithUrl:(NSString*)imageUrl{
|
||||
MJWeakSelf
|
||||
[QXMineNetwork roomInfoEditWithRoomId:self.roomId room_name:@"" room_cover:@"" room_intro:@"" room_background:imageUrl successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
[QXMineNetwork roomInfoEditWithRoomId:self.roomId room_name:@"" room_cover:@"" room_intro:@"" room_background:imageUrl room_password:self.roomPassword successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
[weakSelf hide];
|
||||
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||
showToast(msg);
|
||||
|
||||
@@ -91,7 +91,7 @@
|
||||
showToast(@"请输入房间公告");
|
||||
return;
|
||||
}
|
||||
[QXMineNetwork roomInfoEditWithRoomId:self.roomId room_name:@"" room_cover:@"" room_intro:self.textView.text room_background:@"" successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
[QXMineNetwork roomInfoEditWithRoomId:self.roomId room_name:@"" room_cover:@"" room_intro:self.textView.text room_background:@"" room_password:@"" successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
if (self.setIntroduceBlock) {
|
||||
self.setIntroduceBlock(weakSelf.textView.text);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user