房间内贵族礼物面板
This commit is contained in:
@@ -118,6 +118,7 @@
|
|||||||
9B7B605B27BB53060070BB72 /* XPAnchorAudienceUpMicView.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B7B605A27BB53060070BB72 /* XPAnchorAudienceUpMicView.m */; };
|
9B7B605B27BB53060070BB72 /* XPAnchorAudienceUpMicView.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B7B605A27BB53060070BB72 /* XPAnchorAudienceUpMicView.m */; };
|
||||||
9B7B606227BB96E40070BB72 /* XPRoomAnchorInfoCardView.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B7B606127BB96E40070BB72 /* XPRoomAnchorInfoCardView.m */; };
|
9B7B606227BB96E40070BB72 /* XPRoomAnchorInfoCardView.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B7B606127BB96E40070BB72 /* XPRoomAnchorInfoCardView.m */; };
|
||||||
9B7B606627BBA0EE0070BB72 /* XPAnchorAttentSendInfo.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B7B606527BBA0EE0070BB72 /* XPAnchorAttentSendInfo.m */; };
|
9B7B606627BBA0EE0070BB72 /* XPAnchorAttentSendInfo.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B7B606527BBA0EE0070BB72 /* XPAnchorAttentSendInfo.m */; };
|
||||||
|
9B208A362779B50100F9E54A /* GiftNobleInfoModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B208A352779B50100F9E54A /* GiftNobleInfoModel.m */; };
|
||||||
9B7D804A2753783D003DAC0C /* SessionViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B7D80492753783D003DAC0C /* SessionViewController.m */; };
|
9B7D804A2753783D003DAC0C /* SessionViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B7D80492753783D003DAC0C /* SessionViewController.m */; };
|
||||||
9B7D804D27537950003DAC0C /* MessageCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B7D804C27537950003DAC0C /* MessageCell.m */; };
|
9B7D804D27537950003DAC0C /* MessageCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B7D804C27537950003DAC0C /* MessageCell.m */; };
|
||||||
9B7D80502753AA9D003DAC0C /* UITableView+NIMScrollToBottom.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B7D804E2753AA9D003DAC0C /* UITableView+NIMScrollToBottom.m */; };
|
9B7D80502753AA9D003DAC0C /* UITableView+NIMScrollToBottom.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B7D804E2753AA9D003DAC0C /* UITableView+NIMScrollToBottom.m */; };
|
||||||
@@ -684,6 +685,8 @@
|
|||||||
9B7B606127BB96E40070BB72 /* XPRoomAnchorInfoCardView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XPRoomAnchorInfoCardView.m; sourceTree = "<group>"; };
|
9B7B606127BB96E40070BB72 /* XPRoomAnchorInfoCardView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XPRoomAnchorInfoCardView.m; sourceTree = "<group>"; };
|
||||||
9B7B606427BBA0EE0070BB72 /* XPAnchorAttentSendInfo.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPAnchorAttentSendInfo.h; sourceTree = "<group>"; };
|
9B7B606427BBA0EE0070BB72 /* XPAnchorAttentSendInfo.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPAnchorAttentSendInfo.h; sourceTree = "<group>"; };
|
||||||
9B7B606527BBA0EE0070BB72 /* XPAnchorAttentSendInfo.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPAnchorAttentSendInfo.m; sourceTree = "<group>"; };
|
9B7B606527BBA0EE0070BB72 /* XPAnchorAttentSendInfo.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPAnchorAttentSendInfo.m; sourceTree = "<group>"; };
|
||||||
|
9B208A342779B50100F9E54A /* GiftNobleInfoModel.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GiftNobleInfoModel.h; sourceTree = "<group>"; };
|
||||||
|
9B208A352779B50100F9E54A /* GiftNobleInfoModel.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GiftNobleInfoModel.m; sourceTree = "<group>"; };
|
||||||
9B7D80482753783D003DAC0C /* SessionViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SessionViewController.h; sourceTree = "<group>"; };
|
9B7D80482753783D003DAC0C /* SessionViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SessionViewController.h; sourceTree = "<group>"; };
|
||||||
9B7D80492753783D003DAC0C /* SessionViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SessionViewController.m; sourceTree = "<group>"; };
|
9B7D80492753783D003DAC0C /* SessionViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SessionViewController.m; sourceTree = "<group>"; };
|
||||||
9B7D804B27537950003DAC0C /* MessageCell.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MessageCell.h; sourceTree = "<group>"; };
|
9B7D804B27537950003DAC0C /* MessageCell.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MessageCell.h; sourceTree = "<group>"; };
|
||||||
@@ -2781,6 +2784,8 @@
|
|||||||
E8E7DAEA2745158500C631CC /* XPGiftUserInfoModel.m */,
|
E8E7DAEA2745158500C631CC /* XPGiftUserInfoModel.m */,
|
||||||
E8DACCFC27673F870052092C /* GiftValueInfoModel.h */,
|
E8DACCFC27673F870052092C /* GiftValueInfoModel.h */,
|
||||||
E8DACCFD27673F870052092C /* GiftValueInfoModel.m */,
|
E8DACCFD27673F870052092C /* GiftValueInfoModel.m */,
|
||||||
|
9B208A342779B50100F9E54A /* GiftNobleInfoModel.h */,
|
||||||
|
9B208A352779B50100F9E54A /* GiftNobleInfoModel.m */,
|
||||||
);
|
);
|
||||||
path = Model;
|
path = Model;
|
||||||
sourceTree = "<group>";
|
sourceTree = "<group>";
|
||||||
@@ -4180,6 +4185,7 @@
|
|||||||
E88B5CAD26FB16A800DA9178 /* XPMineTeenagerDesView.m in Sources */,
|
E88B5CAD26FB16A800DA9178 /* XPMineTeenagerDesView.m in Sources */,
|
||||||
E896EF972771AAE400AD2CC1 /* XPMineAttentionPresenter.m in Sources */,
|
E896EF972771AAE400AD2CC1 /* XPMineAttentionPresenter.m in Sources */,
|
||||||
E8E5E19127C369F000F457D8 /* XPHomeRecommendListView.m in Sources */,
|
E8E5E19127C369F000F457D8 /* XPHomeRecommendListView.m in Sources */,
|
||||||
|
9B208A362779B50100F9E54A /* GiftNobleInfoModel.m in Sources */,
|
||||||
E8C6FFDA2754BE81004DC9F0 /* ThemeColor+Home.m in Sources */,
|
E8C6FFDA2754BE81004DC9F0 /* ThemeColor+Home.m in Sources */,
|
||||||
E824545126F5CE6E00BE8163 /* XPMineModifPayPwdPresenter.m in Sources */,
|
E824545126F5CE6E00BE8163 /* XPMineModifPayPwdPresenter.m in Sources */,
|
||||||
E8EEB90F26FC6AB8007C6EBA /* XPMineUserInfoEditPresenter.m in Sources */,
|
E8EEB90F26FC6AB8007C6EBA /* XPMineUserInfoEditPresenter.m in Sources */,
|
||||||
|
@@ -22,7 +22,7 @@
|
|||||||
/// @param complection 完成
|
/// @param complection 完成
|
||||||
/// @param roomUid 房间的roomuid
|
/// @param roomUid 房间的roomuid
|
||||||
+ (void)requestNormalGiftList:(HttpRequestHelperCompletion)complection roomUid:(NSString *)roomUid {
|
+ (void)requestNormalGiftList:(HttpRequestHelperCompletion)complection roomUid:(NSString *)roomUid {
|
||||||
[self makeRequest:@"gift/listV3" method:HttpRequestHelperMethodGET completion:complection, __FUNCTION__, roomUid, nil];
|
[self makeRequest:@"gift/listV4" method:HttpRequestHelperMethodGET completion:complection, __FUNCTION__, roomUid, nil];
|
||||||
}
|
}
|
||||||
|
|
||||||
/// 送礼物的接口
|
/// 送礼物的接口
|
||||||
|
@@ -6,12 +6,15 @@
|
|||||||
//
|
//
|
||||||
|
|
||||||
#import <Foundation/Foundation.h>
|
#import <Foundation/Foundation.h>
|
||||||
|
#import "GiftNobleInfoModel.h"
|
||||||
|
|
||||||
NS_ASSUME_NONNULL_BEGIN
|
NS_ASSUME_NONNULL_BEGIN
|
||||||
//礼物类型
|
//礼物类型
|
||||||
typedef NS_ENUM(NSUInteger, GiftType) {
|
typedef NS_ENUM(NSUInteger, GiftType) {
|
||||||
GiftType_Game = 2, // 游戏轰趴礼物
|
GiftType_Game = 2, // 游戏轰趴礼物
|
||||||
GiftType_Lucky = 3, // 福袋礼物
|
GiftType_Lucky = 3, // 福袋礼物
|
||||||
|
GiftType_LuckyPool = 5, //福袋奖池礼物
|
||||||
|
GiftType_Noble = 7, // 贵族礼物
|
||||||
};
|
};
|
||||||
|
|
||||||
//礼物类型
|
//礼物类型
|
||||||
@@ -86,6 +89,9 @@ typedef NS_ENUM(NSUInteger, RoomSendGiftType) {
|
|||||||
@property (nonatomic,assign) BOOL isSelected;//是否被选中
|
@property (nonatomic,assign) BOOL isSelected;//是否被选中
|
||||||
///礼物来源
|
///礼物来源
|
||||||
@property (nonatomic,assign) GiftSourceType sourceType;
|
@property (nonatomic,assign) GiftSourceType sourceType;
|
||||||
|
///贵族礼物专属信息
|
||||||
|
@property (nonatomic, strong) GiftNobleInfoModel *giftVipInfo;
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
NS_ASSUME_NONNULL_END
|
NS_ASSUME_NONNULL_END
|
||||||
|
@@ -0,0 +1,21 @@
|
|||||||
|
//
|
||||||
|
// GiftNobleInfoModel.h
|
||||||
|
// xplan-ios
|
||||||
|
//
|
||||||
|
// Created by GreenLand on 2021/12/27.
|
||||||
|
//
|
||||||
|
|
||||||
|
#import <Foundation/Foundation.h>
|
||||||
|
|
||||||
|
NS_ASSUME_NONNULL_BEGIN
|
||||||
|
|
||||||
|
@interface GiftNobleInfoModel : NSObject
|
||||||
|
|
||||||
|
///贵族图标
|
||||||
|
@property (nonatomic, copy)NSString *vipIcon;
|
||||||
|
///可用贵族等级
|
||||||
|
@property (nonatomic, assign) NSInteger vipLevel;
|
||||||
|
|
||||||
|
@end
|
||||||
|
|
||||||
|
NS_ASSUME_NONNULL_END
|
@@ -0,0 +1,12 @@
|
|||||||
|
//
|
||||||
|
// GiftNobleInfoModel.m
|
||||||
|
// xplan-ios
|
||||||
|
//
|
||||||
|
// Created by GreenLand on 2021/12/27.
|
||||||
|
//
|
||||||
|
|
||||||
|
#import "GiftNobleInfoModel.h"
|
||||||
|
|
||||||
|
@implementation GiftNobleInfoModel
|
||||||
|
|
||||||
|
@end
|
@@ -12,6 +12,7 @@ NS_ASSUME_NONNULL_BEGIN
|
|||||||
typedef NS_ENUM(NSInteger, GiftSegmentType) {
|
typedef NS_ENUM(NSInteger, GiftSegmentType) {
|
||||||
GiftSegmentType_Normal = 1, ///普通的礼物
|
GiftSegmentType_Normal = 1, ///普通的礼物
|
||||||
GiftSegmentType_Lucky,///幸运礼物
|
GiftSegmentType_Lucky,///幸运礼物
|
||||||
|
GiftSegmentType_Noble,///贵族礼物
|
||||||
GiftSegmentType_Pack,///背包礼物
|
GiftSegmentType_Pack,///背包礼物
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -29,7 +30,7 @@ typedef NS_ENUM(NSInteger, GiftSegmentType) {
|
|||||||
|
|
||||||
@interface XPGiftInfoView : UIView
|
@interface XPGiftInfoView : UIView
|
||||||
|
|
||||||
///普通礼物/幸运礼物
|
///普通礼物/幸运礼物/贵族礼物
|
||||||
@property (nonatomic,strong) NSArray *normalOriginArray;
|
@property (nonatomic,strong) NSArray *normalOriginArray;
|
||||||
///背包礼物
|
///背包礼物
|
||||||
@property (nonatomic,strong) NSArray *packOriginArray;
|
@property (nonatomic,strong) NSArray *packOriginArray;
|
||||||
|
@@ -27,6 +27,8 @@
|
|||||||
@property (nonatomic,strong) UIButton *packGiftButton;
|
@property (nonatomic,strong) UIButton *packGiftButton;
|
||||||
///幸运礼物
|
///幸运礼物
|
||||||
@property (nonatomic,strong) UIButton *luckyGiftButton;
|
@property (nonatomic,strong) UIButton *luckyGiftButton;
|
||||||
|
///贵族礼物
|
||||||
|
@property (nonatomic,strong) UIButton *nobleGiftButton;
|
||||||
///占位的
|
///占位的
|
||||||
@property (nonatomic,strong) UIView * segmentPlaceView;
|
@property (nonatomic,strong) UIView * segmentPlaceView;
|
||||||
///玩法规则的
|
///玩法规则的
|
||||||
@@ -45,6 +47,8 @@
|
|||||||
@property (nonatomic,strong) NSArray<GiftInfoModel *> *giftArray;
|
@property (nonatomic,strong) NSArray<GiftInfoModel *> *giftArray;
|
||||||
/////幸运礼物的数据源
|
/////幸运礼物的数据源
|
||||||
@property (nonatomic,strong) NSArray<GiftInfoModel *> *giftLuckyArray;
|
@property (nonatomic,strong) NSArray<GiftInfoModel *> *giftLuckyArray;
|
||||||
|
///贵族礼物的数据源
|
||||||
|
@property (nonatomic, strong) NSArray<GiftInfoModel *> *giftNobleArray;
|
||||||
/////背包礼物的数据源
|
/////背包礼物的数据源
|
||||||
@property (nonatomic,strong) NSArray<GiftInfoModel *> *giftPackArray;
|
@property (nonatomic,strong) NSArray<GiftInfoModel *> *giftPackArray;
|
||||||
///总的价值
|
///总的价值
|
||||||
@@ -71,6 +75,7 @@
|
|||||||
- (void)didClickGiftSegmentAction:(UIButton *)sender {
|
- (void)didClickGiftSegmentAction:(UIButton *)sender {
|
||||||
self.normalGiftButton.selected = NO;
|
self.normalGiftButton.selected = NO;
|
||||||
self.luckyGiftButton.selected = NO;
|
self.luckyGiftButton.selected = NO;
|
||||||
|
self.nobleGiftButton.selected = NO;
|
||||||
self.packGiftButton.selected = NO;
|
self.packGiftButton.selected = NO;
|
||||||
sender.selected = !sender.selected;
|
sender.selected = !sender.selected;
|
||||||
self.segmentType = sender.tag;
|
self.segmentType = sender.tag;
|
||||||
@@ -100,6 +105,7 @@
|
|||||||
///分段控制
|
///分段控制
|
||||||
[self.segmentStackView addArrangedSubview:self.normalGiftButton];
|
[self.segmentStackView addArrangedSubview:self.normalGiftButton];
|
||||||
[self.segmentStackView addArrangedSubview:self.luckyGiftButton];
|
[self.segmentStackView addArrangedSubview:self.luckyGiftButton];
|
||||||
|
[self.segmentStackView addArrangedSubview:self.nobleGiftButton];
|
||||||
[self.segmentStackView addArrangedSubview:self.packGiftButton];
|
[self.segmentStackView addArrangedSubview:self.packGiftButton];
|
||||||
[self.segmentStackView addArrangedSubview:self.segmentPlaceView];
|
[self.segmentStackView addArrangedSubview:self.segmentPlaceView];
|
||||||
[self.segmentStackView addArrangedSubview:self.playRuleButton];
|
[self.segmentStackView addArrangedSubview:self.playRuleButton];
|
||||||
@@ -253,6 +259,7 @@
|
|||||||
[self resetSelectGift:self.giftArray];
|
[self resetSelectGift:self.giftArray];
|
||||||
[self resetSelectGift:self.packOriginArray];
|
[self resetSelectGift:self.packOriginArray];
|
||||||
[self resetSelectGift:self.giftLuckyArray];
|
[self resetSelectGift:self.giftLuckyArray];
|
||||||
|
[self resetSelectGift:self.giftNobleArray];
|
||||||
self.totalValueLabel.hidden = YES;
|
self.totalValueLabel.hidden = YES;
|
||||||
switch (_segmentType) {
|
switch (_segmentType) {
|
||||||
case GiftSegmentType_Normal:
|
case GiftSegmentType_Normal:
|
||||||
@@ -261,6 +268,9 @@
|
|||||||
case GiftSegmentType_Lucky:
|
case GiftSegmentType_Lucky:
|
||||||
[self.datasource addObjectsFromArray:self.giftLuckyArray];
|
[self.datasource addObjectsFromArray:self.giftLuckyArray];
|
||||||
break;
|
break;
|
||||||
|
case GiftSegmentType_Noble:
|
||||||
|
[self.datasource addObjectsFromArray:self.giftNobleArray];
|
||||||
|
break;
|
||||||
case GiftSegmentType_Pack:
|
case GiftSegmentType_Pack:
|
||||||
{
|
{
|
||||||
[self.datasource addObjectsFromArray:self.packOriginArray];
|
[self.datasource addObjectsFromArray:self.packOriginArray];
|
||||||
@@ -293,15 +303,19 @@
|
|||||||
_normalOriginArray = normalOriginArray;
|
_normalOriginArray = normalOriginArray;
|
||||||
NSMutableArray * luckyArray = [NSMutableArray array];
|
NSMutableArray * luckyArray = [NSMutableArray array];
|
||||||
NSMutableArray * normaleArray = [NSMutableArray array];
|
NSMutableArray * normaleArray = [NSMutableArray array];
|
||||||
|
NSMutableArray * nobleArray = [NSMutableArray array];
|
||||||
[_normalOriginArray enumerateObjectsUsingBlock:^(GiftInfoModel * _Nonnull obj, NSUInteger idx, BOOL * _Nonnull stop) {
|
[_normalOriginArray enumerateObjectsUsingBlock:^(GiftInfoModel * _Nonnull obj, NSUInteger idx, BOOL * _Nonnull stop) {
|
||||||
if (obj.giftType == GiftType_Lucky) {
|
if (obj.giftType == GiftType_Lucky) {
|
||||||
[luckyArray addObject:obj];
|
[luckyArray addObject:obj];
|
||||||
} else if(obj.giftType == GiftType_Game) {
|
} else if(obj.giftType == GiftType_Game) {
|
||||||
[normaleArray addObject:obj];
|
[normaleArray addObject:obj];
|
||||||
|
} else if (obj.giftType == GiftType_Noble) {
|
||||||
|
[nobleArray addObject:obj];
|
||||||
}
|
}
|
||||||
}];
|
}];
|
||||||
self.giftArray = normaleArray;
|
self.giftArray = normaleArray;
|
||||||
self.giftLuckyArray = luckyArray;
|
self.giftLuckyArray = luckyArray;
|
||||||
|
self.giftNobleArray = nobleArray;
|
||||||
self.segmentType = GiftSegmentType_Normal;
|
self.segmentType = GiftSegmentType_Normal;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -357,11 +371,25 @@
|
|||||||
_luckyGiftButton.titleLabel.font = [UIFont systemFontOfSize:14];
|
_luckyGiftButton.titleLabel.font = [UIFont systemFontOfSize:14];
|
||||||
_luckyGiftButton.tag = GiftSegmentType_Lucky;
|
_luckyGiftButton.tag = GiftSegmentType_Lucky;
|
||||||
_luckyGiftButton.selected = NO;
|
_luckyGiftButton.selected = NO;
|
||||||
[_luckyGiftButton addTarget:self action:@ selector(didClickGiftSegmentAction:) forControlEvents:UIControlEventTouchUpInside];
|
[_luckyGiftButton addTarget:self action:@selector(didClickGiftSegmentAction:) forControlEvents:UIControlEventTouchUpInside];
|
||||||
}
|
}
|
||||||
return _luckyGiftButton;
|
return _luckyGiftButton;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
- (UIButton *)nobleGiftButton {
|
||||||
|
if (!_nobleGiftButton) {
|
||||||
|
_nobleGiftButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
||||||
|
[_nobleGiftButton setTitle:@"贵族礼物" forState:UIControlStateNormal];
|
||||||
|
[_nobleGiftButton setTitleColor:[ThemeColor giftSegmentSelectTitleColor] forState:UIControlStateSelected];
|
||||||
|
[_nobleGiftButton setTitleColor:[ThemeColor giftSegmentNormalTitleColor] forState:UIControlStateNormal];
|
||||||
|
_nobleGiftButton.titleLabel.font = [UIFont systemFontOfSize:14];
|
||||||
|
_nobleGiftButton.tag = GiftSegmentType_Noble;
|
||||||
|
_nobleGiftButton.selected = NO;
|
||||||
|
[_nobleGiftButton addTarget:self action:@selector(didClickGiftSegmentAction:) forControlEvents:UIControlEventTouchUpInside];
|
||||||
|
}
|
||||||
|
return _nobleGiftButton;
|
||||||
|
}
|
||||||
|
|
||||||
- (UIButton *)packGiftButton {
|
- (UIButton *)packGiftButton {
|
||||||
if (!_packGiftButton) {
|
if (!_packGiftButton) {
|
||||||
_packGiftButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
_packGiftButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
||||||
|
@@ -130,7 +130,15 @@
|
|||||||
///先不请求接口 从缓存中获取
|
///先不请求接口 从缓存中获取
|
||||||
[[XPGiftStorage shareStorage] getGiftDatasource:roomUid];
|
[[XPGiftStorage shareStorage] getGiftDatasource:roomUid];
|
||||||
[Api requestNormalGiftList:^(BaseModel * _Nullable data, NSInteger code, NSString * _Nullable msg) {
|
[Api requestNormalGiftList:^(BaseModel * _Nullable data, NSInteger code, NSString * _Nullable msg) {
|
||||||
NSArray * info = [GiftInfoModel modelsWithArray:data.data[@"gift"]];
|
NSArray *luckyBagGift = [GiftInfoModel modelsWithArray:data.data[@"luckyBagGift"]]; // 福袋礼物
|
||||||
|
NSArray *vipGift = [GiftInfoModel modelsWithArray:data.data[@"vipGift"]]; // 贵族礼物
|
||||||
|
NSArray *luckyPoolGift = [GiftInfoModel modelsWithArray:data.data[@"luckyPoolGift"]];// 福袋奖池礼物
|
||||||
|
NSArray *normalGift = [GiftInfoModel modelsWithArray:data.data[@"normalGift"]]; // 普通面板礼物
|
||||||
|
NSMutableArray *info = [NSMutableArray array];
|
||||||
|
[info addObjectsFromArray:luckyBagGift];
|
||||||
|
[info addObjectsFromArray:vipGift];
|
||||||
|
[info addObjectsFromArray:luckyPoolGift];
|
||||||
|
[info addObjectsFromArray:normalGift];
|
||||||
///把礼物信息保存一下
|
///把礼物信息保存一下
|
||||||
[[XPGiftStorage shareStorage] saveGiftDatasource:info roomUid:roomUid];
|
[[XPGiftStorage shareStorage] saveGiftDatasource:info roomUid:roomUid];
|
||||||
} roomUid:roomUid];
|
} roomUid:roomUid];
|
||||||
|
Reference in New Issue
Block a user