diff --git a/xplan-ios.xcodeproj/project.pbxproj b/xplan-ios.xcodeproj/project.pbxproj index a9e89c84..50a5bf59 100644 --- a/xplan-ios.xcodeproj/project.pbxproj +++ b/xplan-ios.xcodeproj/project.pbxproj @@ -113,6 +113,7 @@ 9B0086C627BA392B0032BD2B /* AnchorStageView.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B0086C527BA392B0032BD2B /* AnchorStageView.m */; }; 9B0086CA27BA4F570032BD2B /* AnchorMicroView.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B0086C927BA4F570032BD2B /* AnchorMicroView.m */; }; 9B044D9D282D2A6400DE4859 /* XPRoomAnchorRankEnterView.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B044D9C282D2A6400DE4859 /* XPRoomAnchorRankEnterView.m */; }; + 9B044DA0282D32F700DE4859 /* MicroInviteExtModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B044D9F282D32F700DE4859 /* MicroInviteExtModel.m */; }; 9B060B5827BCAEE20001B767 /* AnchorGiftValueView.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B060B5727BCAEE20001B767 /* AnchorGiftValueView.m */; }; 9B0997A127F19D8A00EB8F14 /* README.md in Resources */ = {isa = PBXBuildFile; fileRef = 9B0997A027F19D8900EB8F14 /* README.md */; }; 9B0997A327F19DE500EB8F14 /* QGHWDShaders.metal in Sources */ = {isa = PBXBuildFile; fileRef = 9B0997A227F19DE500EB8F14 /* QGHWDShaders.metal */; }; @@ -944,6 +945,8 @@ 9B0086C927BA4F570032BD2B /* AnchorMicroView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AnchorMicroView.m; sourceTree = ""; }; 9B044D9B282D2A6400DE4859 /* XPRoomAnchorRankEnterView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPRoomAnchorRankEnterView.h; sourceTree = ""; }; 9B044D9C282D2A6400DE4859 /* XPRoomAnchorRankEnterView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPRoomAnchorRankEnterView.m; sourceTree = ""; }; + 9B044D9E282D32F700DE4859 /* MicroInviteExtModel.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MicroInviteExtModel.h; sourceTree = ""; }; + 9B044D9F282D32F700DE4859 /* MicroInviteExtModel.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MicroInviteExtModel.m; sourceTree = ""; }; 9B060B5627BCAEE20001B767 /* AnchorGiftValueView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AnchorGiftValueView.h; sourceTree = ""; }; 9B060B5727BCAEE20001B767 /* AnchorGiftValueView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AnchorGiftValueView.m; sourceTree = ""; }; 9B0997A027F19D8900EB8F14 /* README.md */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = net.daringfireball.markdown; path = README.md; sourceTree = ""; }; @@ -4487,6 +4490,8 @@ E874B88A27215EAF003954B9 /* MicroQueueModel.m */, E87E91502796A15500A7B3F2 /* MicroExtModel.h */, E87E91512796A15500A7B3F2 /* MicroExtModel.m */, + 9B044D9E282D32F700DE4859 /* MicroInviteExtModel.h */, + 9B044D9F282D32F700DE4859 /* MicroInviteExtModel.m */, ); path = Model; sourceTree = ""; @@ -6543,6 +6548,7 @@ 9BCF585C279909D7008401A4 /* XPSkillCardEditPropCell.m in Sources */, E88863C6278EAFC3004BCFAB /* XPAcrossRoomPKResultView.m in Sources */, E8AC722C26F49580007D6E91 /* XPMineNotificaViewController.m in Sources */, + 9B044DA0282D32F700DE4859 /* MicroInviteExtModel.m in Sources */, E8D34D5A28082357009C4835 /* UserGiftWallInfoModel.m in Sources */, 189DD52E26DE255300AB55B1 /* AppDelegate.m in Sources */, E83DB4842746661800D8CBD1 /* XPRoomGiftBroadcastView.m in Sources */, diff --git a/xplan-ios/Main/Room/View/StageView/Model/MicroInviteExtModel.h b/xplan-ios/Main/Room/View/StageView/Model/MicroInviteExtModel.h new file mode 100644 index 00000000..00751a6c --- /dev/null +++ b/xplan-ios/Main/Room/View/StageView/Model/MicroInviteExtModel.h @@ -0,0 +1,20 @@ +// +// MicroInviteExtModel.h +// xplan-ios +// +// Created by GreenLand on 2022/5/12. +// + +#import + +NS_ASSUME_NONNULL_BEGIN + +@interface MicroInviteExtModel : NSObject + +@property (nonatomic, copy) NSString *uid; + +@property (nonatomic, copy) NSString *micPosition; + +@end + +NS_ASSUME_NONNULL_END diff --git a/xplan-ios/Main/Room/View/StageView/Model/MicroInviteExtModel.m b/xplan-ios/Main/Room/View/StageView/Model/MicroInviteExtModel.m new file mode 100644 index 00000000..01297eec --- /dev/null +++ b/xplan-ios/Main/Room/View/StageView/Model/MicroInviteExtModel.m @@ -0,0 +1,12 @@ +// +// MicroInviteExtModel.m +// xplan-ios +// +// Created by GreenLand on 2022/5/12. +// + +#import "MicroInviteExtModel.h" + +@implementation MicroInviteExtModel + +@end diff --git a/xplan-ios/Main/Room/View/StageView/StageView.m b/xplan-ios/Main/Room/View/StageView/StageView.m index 515828e0..1a8e7e8f 100644 --- a/xplan-ios/Main/Room/View/StageView/StageView.m +++ b/xplan-ios/Main/Room/View/StageView/StageView.m @@ -29,6 +29,7 @@ #import "GiftValueInfoModel.h" #import "MicroExtModel.h" #import "RoomFaceSendInfoModel.h" +#import "MicroInviteExtModel.h" // Views #import "NetImageView.h" #import "XPUserCardViewController.h" @@ -366,11 +367,9 @@ AttachmentModel *attachment = (AttachmentModel *)obj.attachment; if(attachment.first == CustomMessageType_Queue && attachment.second == Custom_Message_Sub_Queue_Invite) { NSDictionary *dic = attachment.data; - - NSString *uid = dic[@"uid"]; - if (uid.integerValue == self.hostDelegate.getUserInfo.uid) { - NSNumber *micPosition = dic[@"micPosition"]; - NSString *position = micPosition.stringValue; + MicroInviteExtModel *inviteModel = [MicroInviteExtModel modelWithDictionary:dic]; + if (inviteModel.uid.integerValue == self.hostDelegate.getUserInfo.uid) { + NSString *position = inviteModel.micPosition; MicroQueueModel *micro = [self.micQueue objectForKey:position]; if (!micro || micro.userInfo) return; // 当前麦位有人,什么都不做。