最后调整
This commit is contained in:
@@ -50,7 +50,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@property (nonatomic,copy)void(^sendSuccessBlock)(NSString*dynamicId);
|
||||
|
||||
@property (nonatomic,copy)void(^roomSendSuccessBlock)(QXSendGiftViewType sendType, QXGiftModel*giftModel,NSString*userId, NSString*optionId);
|
||||
@property (nonatomic,copy)void(^roomSendSuccessBlock)(QXSendGiftViewType sendType, QXGiftModel*giftModel,NSString*giftCount,NSString*userId, NSString*optionId);
|
||||
-(void)reloadData;
|
||||
|
||||
-(void)showInView:(UIView *)view;
|
||||
@@ -123,6 +123,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
@property (nonatomic,strong)NSString *auctionId;
|
||||
@property (nonatomic,strong)NSString *heartId;
|
||||
@property (nonatomic,strong)NSString *roomId;
|
||||
@property (nonatomic,strong)NSString *giftCount;
|
||||
|
||||
@property (nonatomic,strong)CABasicAnimation *animation;
|
||||
@property (nonatomic,copy)void(^dissMissBlock)(QXGiftModel *gift);
|
||||
|
||||
@@ -56,6 +56,8 @@
|
||||
@implementation QXSendGiftView
|
||||
|
||||
-(void)showInView:(UIView *)view{
|
||||
self.giftCount = @"1";
|
||||
[self.countBtn setTitle:@"X1" forState:(UIControlStateNormal)];
|
||||
self.bgView.y = SCREEN_HEIGHT;
|
||||
[view addSubview:self];
|
||||
[UIView animateWithDuration:0.3 animations:^{
|
||||
@@ -322,7 +324,7 @@
|
||||
-(void)selectedCount:(UIButton*)sender{
|
||||
QXMenuPopView *popView = [[QXMenuPopView alloc] initWithPoint:CGPointMake(SCREEN_WIDTH-16-60-30, SCREEN_HEIGHT-kSafeAreaBottom-50-225) width:88 height:225];
|
||||
popView.type = QXMenuPopViewTypeArrowBottom;
|
||||
popView.dataArray = @[@"X99",@"X66",@"X30",@"10",@"5",@"3",@"1"];
|
||||
popView.dataArray = @[@"X20",@"X15",@"X10",@"X5",@"X1"];
|
||||
popView.delegate = self;
|
||||
[popView showInView:KEYWINDOW];
|
||||
}
|
||||
@@ -378,7 +380,7 @@
|
||||
[QXMineNetwork roomSendGiftWithRoomId:self.roomId gift_id:self.giftModel.gift_id gift_num:self.giftCount to_uid:userId heart_id:self.heartId type:type pit_number:@"" successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
if (type.intValue == 1) {
|
||||
if (weakSelf.roomSendSuccessBlock) {
|
||||
weakSelf.roomSendSuccessBlock(self.type,weakSelf.giftModel,userId,@"");
|
||||
weakSelf.roomSendSuccessBlock(self.type,weakSelf.giftModel,weakSelf.giftCount,userId,@"");
|
||||
}
|
||||
[weakSelf hide];
|
||||
}else{
|
||||
@@ -398,7 +400,7 @@
|
||||
if (type.intValue == 1) {
|
||||
[weakSelf hide];
|
||||
if (weakSelf.roomSendSuccessBlock) {
|
||||
weakSelf.roomSendSuccessBlock(weakSelf.type,weakSelf.giftModel,[QXGlobal shareGlobal].loginModel.user_id,weakSelf.auctionId);
|
||||
weakSelf.roomSendSuccessBlock(weakSelf.type,weakSelf.giftModel,weakSelf.giftCount,[QXGlobal shareGlobal].loginModel.user_id,weakSelf.auctionId);
|
||||
}
|
||||
}else{
|
||||
[weakSelf.bagGiftView reloadData];
|
||||
@@ -419,7 +421,7 @@
|
||||
if (type.intValue == 1) {
|
||||
[weakSelf hide];
|
||||
if (weakSelf.roomSendSuccessBlock) {
|
||||
weakSelf.roomSendSuccessBlock(self.type,weakSelf.giftModel,userId,weakSelf.heartId);
|
||||
weakSelf.roomSendSuccessBlock(self.type,weakSelf.giftModel,weakSelf.giftCount,userId,weakSelf.heartId);
|
||||
}
|
||||
}else{
|
||||
[weakSelf.bagGiftView reloadData];
|
||||
@@ -1195,21 +1197,21 @@
|
||||
[[QXGlobal shareGlobal] vibrationFeedback];
|
||||
switch (self.sendType) {
|
||||
case QXSendGiftViewTypeRoom:
|
||||
[QXMineNetwork roomSendGiftWithRoomId:self.roomId gift_id:self.giftModel.gift_id gift_num:@"1" to_uid:self.userId heart_id:self.heartId type:@"1" pit_number:@"" successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
[QXMineNetwork roomSendGiftWithRoomId:self.roomId gift_id:self.giftModel.gift_id gift_num:self.giftCount to_uid:self.userId heart_id:self.heartId type:@"1" pit_number:@"" successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
|
||||
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||
showToast(msg)
|
||||
}];
|
||||
break;
|
||||
case QXSendGiftViewTypeAuction:
|
||||
[QXMineNetwork roomAuctionJoinWithAuctionId:self.auctionId user_id:self.userId gift_id:self.giftModel.gift_id num:@"1" type:@"1" successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
[QXMineNetwork roomAuctionJoinWithAuctionId:self.auctionId user_id:self.userId gift_id:self.giftModel.gift_id num:self.giftCount type:@"1" successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
|
||||
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||
showToast(msg)
|
||||
}];
|
||||
break;
|
||||
case QXSendGiftViewTypeFriend:
|
||||
[QXMineNetwork roomSendGiftWithRoomId:self.roomId gift_id:self.giftModel.gift_id gift_num:@"1" to_uid:self.userId heart_id:self.heartId type:@"1" pit_number:@"" successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
[QXMineNetwork roomSendGiftWithRoomId:self.roomId gift_id:self.giftModel.gift_id gift_num:self.giftCount to_uid:self.userId heart_id:self.heartId type:@"1" pit_number:@"" successBlock:^(NSDictionary * _Nonnull dict) {
|
||||
|
||||
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
|
||||
showToast(msg)
|
||||
|
||||
Reference in New Issue
Block a user