新增声音卡
@@ -274,6 +274,10 @@
|
|||||||
23E9EB152A84D02400B792F2 /* XPMineUserInfoEditPickView.m in Sources */ = {isa = PBXBuildFile; fileRef = 23E9EB142A84D02400B792F2 /* XPMineUserInfoEditPickView.m */; };
|
23E9EB152A84D02400B792F2 /* XPMineUserInfoEditPickView.m in Sources */ = {isa = PBXBuildFile; fileRef = 23E9EB142A84D02400B792F2 /* XPMineUserInfoEditPickView.m */; };
|
||||||
23E9EB182A84D0E700B792F2 /* XPMineUserInfoEditMainTagView.m in Sources */ = {isa = PBXBuildFile; fileRef = 23E9EB162A84D0E700B792F2 /* XPMineUserInfoEditMainTagView.m */; };
|
23E9EB182A84D0E700B792F2 /* XPMineUserInfoEditMainTagView.m in Sources */ = {isa = PBXBuildFile; fileRef = 23E9EB162A84D0E700B792F2 /* XPMineUserInfoEditMainTagView.m */; };
|
||||||
23E9EB1B2A84D28A00B792F2 /* XPMineUserInfoEditTagView.m in Sources */ = {isa = PBXBuildFile; fileRef = 23E9EB1A2A84D28A00B792F2 /* XPMineUserInfoEditTagView.m */; };
|
23E9EB1B2A84D28A00B792F2 /* XPMineUserInfoEditTagView.m in Sources */ = {isa = PBXBuildFile; fileRef = 23E9EB1A2A84D28A00B792F2 /* XPMineUserInfoEditTagView.m */; };
|
||||||
|
23E9EB1E2A84DA5F00B792F2 /* XPMineUserInfoNavView.m in Sources */ = {isa = PBXBuildFile; fileRef = 23E9EB1C2A84DA5F00B792F2 /* XPMineUserInfoNavView.m */; };
|
||||||
|
23E9EB242A84E98300B792F2 /* pi_new_mine_info_sound_play.svga in Resources */ = {isa = PBXBuildFile; fileRef = 23E9EB222A84E98300B792F2 /* pi_new_mine_info_sound_play.svga */; };
|
||||||
|
23E9EB252A84E98300B792F2 /* pi_new_mine_info_online.svga in Resources */ = {isa = PBXBuildFile; fileRef = 23E9EB232A84E98300B792F2 /* pi_new_mine_info_online.svga */; };
|
||||||
|
23E9EB292A84F18000B792F2 /* pi_app_logo_bg.png in Resources */ = {isa = PBXBuildFile; fileRef = 23E9EB282A84F18000B792F2 /* pi_app_logo_bg.png */; };
|
||||||
73FFADDC93E195344047A2EC /* Pods_YuMi.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = CACF623970097D653132D69A /* Pods_YuMi.framework */; };
|
73FFADDC93E195344047A2EC /* Pods_YuMi.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = CACF623970097D653132D69A /* Pods_YuMi.framework */; };
|
||||||
9B0086C627BA392B0032BD2B /* AnchorStageView.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B0086C527BA392B0032BD2B /* AnchorStageView.m */; };
|
9B0086C627BA392B0032BD2B /* AnchorStageView.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B0086C527BA392B0032BD2B /* AnchorStageView.m */; };
|
||||||
9B0086CA27BA4F570032BD2B /* AnchorMicroView.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B0086C927BA4F570032BD2B /* AnchorMicroView.m */; };
|
9B0086CA27BA4F570032BD2B /* AnchorMicroView.m in Sources */ = {isa = PBXBuildFile; fileRef = 9B0086C927BA4F570032BD2B /* AnchorMicroView.m */; };
|
||||||
@@ -790,7 +794,6 @@
|
|||||||
E84A2EA82A5288FD00D6AF8A /* XPGoldDetailsChooseRoomCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E84A2EA72A5288FD00D6AF8A /* XPGoldDetailsChooseRoomCell.m */; };
|
E84A2EA82A5288FD00D6AF8A /* XPGoldDetailsChooseRoomCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E84A2EA72A5288FD00D6AF8A /* XPGoldDetailsChooseRoomCell.m */; };
|
||||||
E84A2EAB2A528A4100D6AF8A /* XPIncomeRecordGoldDetailsPickViewView.m in Sources */ = {isa = PBXBuildFile; fileRef = E84A2EA92A528A4100D6AF8A /* XPIncomeRecordGoldDetailsPickViewView.m */; };
|
E84A2EAB2A528A4100D6AF8A /* XPIncomeRecordGoldDetailsPickViewView.m in Sources */ = {isa = PBXBuildFile; fileRef = E84A2EA92A528A4100D6AF8A /* XPIncomeRecordGoldDetailsPickViewView.m */; };
|
||||||
E84A2EAD2A52F20900D6AF8A /* Launch Screen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = E84A2EAC2A52F20900D6AF8A /* Launch Screen.storyboard */; };
|
E84A2EAD2A52F20900D6AF8A /* Launch Screen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = E84A2EAC2A52F20900D6AF8A /* Launch Screen.storyboard */; };
|
||||||
E84A2EAF2A52F27000D6AF8A /* 1242.png in Resources */ = {isa = PBXBuildFile; fileRef = E84A2EAE2A52F27000D6AF8A /* 1242.png */; };
|
|
||||||
E84B0E3F2727EDF6008818C6 /* XPRoomMessageTableViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E84B0E3E2727EDF6008818C6 /* XPRoomMessageTableViewCell.m */; };
|
E84B0E3F2727EDF6008818C6 /* XPRoomMessageTableViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E84B0E3E2727EDF6008818C6 /* XPRoomMessageTableViewCell.m */; };
|
||||||
E84B0E422727EE0A008818C6 /* XPRoomMessageHeaderView.m in Sources */ = {isa = PBXBuildFile; fileRef = E84B0E412727EE0A008818C6 /* XPRoomMessageHeaderView.m */; };
|
E84B0E422727EE0A008818C6 /* XPRoomMessageHeaderView.m in Sources */ = {isa = PBXBuildFile; fileRef = E84B0E412727EE0A008818C6 /* XPRoomMessageHeaderView.m */; };
|
||||||
E84B0E462727EF9D008818C6 /* XPRoomMessageParser.m in Sources */ = {isa = PBXBuildFile; fileRef = E84B0E452727EF9D008818C6 /* XPRoomMessageParser.m */; };
|
E84B0E462727EF9D008818C6 /* XPRoomMessageParser.m in Sources */ = {isa = PBXBuildFile; fileRef = E84B0E452727EF9D008818C6 /* XPRoomMessageParser.m */; };
|
||||||
@@ -1283,7 +1286,6 @@
|
|||||||
E8EEB8F326FC2050007C6EBA /* SDWaitingView.m in Sources */ = {isa = PBXBuildFile; fileRef = E8EEB8ED26FC2050007C6EBA /* SDWaitingView.m */; };
|
E8EEB8F326FC2050007C6EBA /* SDWaitingView.m in Sources */ = {isa = PBXBuildFile; fileRef = E8EEB8ED26FC2050007C6EBA /* SDWaitingView.m */; };
|
||||||
E8EEB8F426FC2050007C6EBA /* SDBrowserImageView.m in Sources */ = {isa = PBXBuildFile; fileRef = E8EEB8EE26FC2050007C6EBA /* SDBrowserImageView.m */; };
|
E8EEB8F426FC2050007C6EBA /* SDBrowserImageView.m in Sources */ = {isa = PBXBuildFile; fileRef = E8EEB8EE26FC2050007C6EBA /* SDBrowserImageView.m */; };
|
||||||
E8EEB8F726FC2673007C6EBA /* UserPhoto.m in Sources */ = {isa = PBXBuildFile; fileRef = E8EEB8F626FC2673007C6EBA /* UserPhoto.m */; };
|
E8EEB8F726FC2673007C6EBA /* UserPhoto.m in Sources */ = {isa = PBXBuildFile; fileRef = E8EEB8F626FC2673007C6EBA /* UserPhoto.m */; };
|
||||||
E8EEB8FB26FC2874007C6EBA /* XPMineUserInfoTableViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E8EEB8FA26FC2874007C6EBA /* XPMineUserInfoTableViewCell.m */; };
|
|
||||||
E8EEB8FE26FC2DF8007C6EBA /* XPMineUserInfoCustomNavView.m in Sources */ = {isa = PBXBuildFile; fileRef = E8EEB8FD26FC2DF8007C6EBA /* XPMineUserInfoCustomNavView.m */; };
|
E8EEB8FE26FC2DF8007C6EBA /* XPMineUserInfoCustomNavView.m in Sources */ = {isa = PBXBuildFile; fileRef = E8EEB8FD26FC2DF8007C6EBA /* XPMineUserInfoCustomNavView.m */; };
|
||||||
E8EEB90126FC31B6007C6EBA /* XPMineUserInfoPresenter.m in Sources */ = {isa = PBXBuildFile; fileRef = E8EEB90026FC31B6007C6EBA /* XPMineUserInfoPresenter.m */; };
|
E8EEB90126FC31B6007C6EBA /* XPMineUserInfoPresenter.m in Sources */ = {isa = PBXBuildFile; fileRef = E8EEB90026FC31B6007C6EBA /* XPMineUserInfoPresenter.m */; };
|
||||||
E8EEB90326FC31DC007C6EBA /* XPMineUserInfoProtocol.h in Sources */ = {isa = PBXBuildFile; fileRef = E8EEB90226FC31CE007C6EBA /* XPMineUserInfoProtocol.h */; };
|
E8EEB90326FC31DC007C6EBA /* XPMineUserInfoProtocol.h in Sources */ = {isa = PBXBuildFile; fileRef = E8EEB90226FC31CE007C6EBA /* XPMineUserInfoProtocol.h */; };
|
||||||
@@ -1870,6 +1872,11 @@
|
|||||||
23E9EB172A84D0E700B792F2 /* XPMineUserInfoEditMainTagView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XPMineUserInfoEditMainTagView.h; sourceTree = "<group>"; };
|
23E9EB172A84D0E700B792F2 /* XPMineUserInfoEditMainTagView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XPMineUserInfoEditMainTagView.h; sourceTree = "<group>"; };
|
||||||
23E9EB192A84D28900B792F2 /* XPMineUserInfoEditTagView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XPMineUserInfoEditTagView.h; sourceTree = "<group>"; };
|
23E9EB192A84D28900B792F2 /* XPMineUserInfoEditTagView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XPMineUserInfoEditTagView.h; sourceTree = "<group>"; };
|
||||||
23E9EB1A2A84D28A00B792F2 /* XPMineUserInfoEditTagView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XPMineUserInfoEditTagView.m; sourceTree = "<group>"; };
|
23E9EB1A2A84D28A00B792F2 /* XPMineUserInfoEditTagView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XPMineUserInfoEditTagView.m; sourceTree = "<group>"; };
|
||||||
|
23E9EB1C2A84DA5F00B792F2 /* XPMineUserInfoNavView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XPMineUserInfoNavView.m; sourceTree = "<group>"; };
|
||||||
|
23E9EB1D2A84DA5F00B792F2 /* XPMineUserInfoNavView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XPMineUserInfoNavView.h; sourceTree = "<group>"; };
|
||||||
|
23E9EB222A84E98300B792F2 /* pi_new_mine_info_sound_play.svga */ = {isa = PBXFileReference; lastKnownFileType = file; path = pi_new_mine_info_sound_play.svga; sourceTree = "<group>"; };
|
||||||
|
23E9EB232A84E98300B792F2 /* pi_new_mine_info_online.svga */ = {isa = PBXFileReference; lastKnownFileType = file; path = pi_new_mine_info_online.svga; sourceTree = "<group>"; };
|
||||||
|
23E9EB282A84F18000B792F2 /* pi_app_logo_bg.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = pi_app_logo_bg.png; sourceTree = "<group>"; };
|
||||||
7DB00EC07F1D0ADFF900B38D /* Pods-YuMi.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-YuMi.debug.xcconfig"; path = "Target Support Files/Pods-YuMi/Pods-YuMi.debug.xcconfig"; sourceTree = "<group>"; };
|
7DB00EC07F1D0ADFF900B38D /* Pods-YuMi.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-YuMi.debug.xcconfig"; path = "Target Support Files/Pods-YuMi/Pods-YuMi.debug.xcconfig"; sourceTree = "<group>"; };
|
||||||
9B0086C427BA392B0032BD2B /* AnchorStageView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AnchorStageView.h; sourceTree = "<group>"; };
|
9B0086C427BA392B0032BD2B /* AnchorStageView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AnchorStageView.h; sourceTree = "<group>"; };
|
||||||
9B0086C527BA392B0032BD2B /* AnchorStageView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AnchorStageView.m; sourceTree = "<group>"; };
|
9B0086C527BA392B0032BD2B /* AnchorStageView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AnchorStageView.m; sourceTree = "<group>"; };
|
||||||
@@ -2747,7 +2754,6 @@
|
|||||||
E84A2EA92A528A4100D6AF8A /* XPIncomeRecordGoldDetailsPickViewView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XPIncomeRecordGoldDetailsPickViewView.m; sourceTree = "<group>"; };
|
E84A2EA92A528A4100D6AF8A /* XPIncomeRecordGoldDetailsPickViewView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XPIncomeRecordGoldDetailsPickViewView.m; sourceTree = "<group>"; };
|
||||||
E84A2EAA2A528A4100D6AF8A /* XPIncomeRecordGoldDetailsPickViewView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XPIncomeRecordGoldDetailsPickViewView.h; sourceTree = "<group>"; };
|
E84A2EAA2A528A4100D6AF8A /* XPIncomeRecordGoldDetailsPickViewView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XPIncomeRecordGoldDetailsPickViewView.h; sourceTree = "<group>"; };
|
||||||
E84A2EAC2A52F20900D6AF8A /* Launch Screen.storyboard */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; path = "Launch Screen.storyboard"; sourceTree = "<group>"; };
|
E84A2EAC2A52F20900D6AF8A /* Launch Screen.storyboard */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; path = "Launch Screen.storyboard"; sourceTree = "<group>"; };
|
||||||
E84A2EAE2A52F27000D6AF8A /* 1242.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = 1242.png; sourceTree = "<group>"; };
|
|
||||||
E84B0E3D2727EDF6008818C6 /* XPRoomMessageTableViewCell.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPRoomMessageTableViewCell.h; sourceTree = "<group>"; };
|
E84B0E3D2727EDF6008818C6 /* XPRoomMessageTableViewCell.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPRoomMessageTableViewCell.h; sourceTree = "<group>"; };
|
||||||
E84B0E3E2727EDF6008818C6 /* XPRoomMessageTableViewCell.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPRoomMessageTableViewCell.m; sourceTree = "<group>"; };
|
E84B0E3E2727EDF6008818C6 /* XPRoomMessageTableViewCell.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPRoomMessageTableViewCell.m; sourceTree = "<group>"; };
|
||||||
E84B0E402727EE0A008818C6 /* XPRoomMessageHeaderView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPRoomMessageHeaderView.h; sourceTree = "<group>"; };
|
E84B0E402727EE0A008818C6 /* XPRoomMessageHeaderView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPRoomMessageHeaderView.h; sourceTree = "<group>"; };
|
||||||
@@ -3770,8 +3776,6 @@
|
|||||||
E8EEB8F126FC2050007C6EBA /* SDBrowserImageView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDBrowserImageView.h; sourceTree = "<group>"; };
|
E8EEB8F126FC2050007C6EBA /* SDBrowserImageView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDBrowserImageView.h; sourceTree = "<group>"; };
|
||||||
E8EEB8F526FC2673007C6EBA /* UserPhoto.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = UserPhoto.h; sourceTree = "<group>"; };
|
E8EEB8F526FC2673007C6EBA /* UserPhoto.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = UserPhoto.h; sourceTree = "<group>"; };
|
||||||
E8EEB8F626FC2673007C6EBA /* UserPhoto.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = UserPhoto.m; sourceTree = "<group>"; };
|
E8EEB8F626FC2673007C6EBA /* UserPhoto.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = UserPhoto.m; sourceTree = "<group>"; };
|
||||||
E8EEB8F926FC2874007C6EBA /* XPMineUserInfoTableViewCell.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPMineUserInfoTableViewCell.h; sourceTree = "<group>"; };
|
|
||||||
E8EEB8FA26FC2874007C6EBA /* XPMineUserInfoTableViewCell.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPMineUserInfoTableViewCell.m; sourceTree = "<group>"; };
|
|
||||||
E8EEB8FC26FC2DF8007C6EBA /* XPMineUserInfoCustomNavView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPMineUserInfoCustomNavView.h; sourceTree = "<group>"; };
|
E8EEB8FC26FC2DF8007C6EBA /* XPMineUserInfoCustomNavView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPMineUserInfoCustomNavView.h; sourceTree = "<group>"; };
|
||||||
E8EEB8FD26FC2DF8007C6EBA /* XPMineUserInfoCustomNavView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPMineUserInfoCustomNavView.m; sourceTree = "<group>"; };
|
E8EEB8FD26FC2DF8007C6EBA /* XPMineUserInfoCustomNavView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPMineUserInfoCustomNavView.m; sourceTree = "<group>"; };
|
||||||
E8EEB8FF26FC31B6007C6EBA /* XPMineUserInfoPresenter.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPMineUserInfoPresenter.h; sourceTree = "<group>"; };
|
E8EEB8FF26FC31B6007C6EBA /* XPMineUserInfoPresenter.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPMineUserInfoPresenter.h; sourceTree = "<group>"; };
|
||||||
@@ -4006,7 +4010,6 @@
|
|||||||
14D8768129A751E100E1DD7F /* Image */ = {
|
14D8768129A751E100E1DD7F /* Image */ = {
|
||||||
isa = PBXGroup;
|
isa = PBXGroup;
|
||||||
children = (
|
children = (
|
||||||
E84A2EAE2A52F27000D6AF8A /* 1242.png */,
|
|
||||||
);
|
);
|
||||||
path = Image;
|
path = Image;
|
||||||
sourceTree = "<group>";
|
sourceTree = "<group>";
|
||||||
@@ -4240,6 +4243,7 @@
|
|||||||
E81C27AF26EF39B00031E639 /* AppDelegate */,
|
E81C27AF26EF39B00031E639 /* AppDelegate */,
|
||||||
189DD53826DE255600AB55B1 /* Assets.xcassets */,
|
189DD53826DE255600AB55B1 /* Assets.xcassets */,
|
||||||
E84A2EAC2A52F20900D6AF8A /* Launch Screen.storyboard */,
|
E84A2EAC2A52F20900D6AF8A /* Launch Screen.storyboard */,
|
||||||
|
23E9EB282A84F18000B792F2 /* pi_app_logo_bg.png */,
|
||||||
189DD53D26DE255600AB55B1 /* Info.plist */,
|
189DD53D26DE255600AB55B1 /* Info.plist */,
|
||||||
E80E09AB2A40B70100CD2BE7 /* Localizable.strings */,
|
E80E09AB2A40B70100CD2BE7 /* Localizable.strings */,
|
||||||
189DD53E26DE255600AB55B1 /* main.m */,
|
189DD53E26DE255600AB55B1 /* main.m */,
|
||||||
@@ -8280,6 +8284,8 @@
|
|||||||
23E9EAA82A84C9B700B792F2 /* XPMineUserInfoTagItemView.m */,
|
23E9EAA82A84C9B700B792F2 /* XPMineUserInfoTagItemView.m */,
|
||||||
23E9EAB42A84CB2600B792F2 /* XPMineUserInfoTagEmptyView.h */,
|
23E9EAB42A84CB2600B792F2 /* XPMineUserInfoTagEmptyView.h */,
|
||||||
23E9EAB32A84CB2600B792F2 /* XPMineUserInfoTagEmptyView.m */,
|
23E9EAB32A84CB2600B792F2 /* XPMineUserInfoTagEmptyView.m */,
|
||||||
|
23E9EB1D2A84DA5F00B792F2 /* XPMineUserInfoNavView.h */,
|
||||||
|
23E9EB1C2A84DA5F00B792F2 /* XPMineUserInfoNavView.m */,
|
||||||
23E9EAA92A84C9B700B792F2 /* XPMineUserInfoTagView.h */,
|
23E9EAA92A84C9B700B792F2 /* XPMineUserInfoTagView.h */,
|
||||||
23E9EAAA2A84C9B700B792F2 /* XPMineUserInfoTagView.m */,
|
23E9EAAA2A84C9B700B792F2 /* XPMineUserInfoTagView.m */,
|
||||||
23E9EAB02A84C9DD00B792F2 /* XPMineUserInfoTagViewCell.h */,
|
23E9EAB02A84C9DD00B792F2 /* XPMineUserInfoTagViewCell.h */,
|
||||||
@@ -8429,6 +8435,8 @@
|
|||||||
E8A1E45C276220B100B294CA /* Resources */ = {
|
E8A1E45C276220B100B294CA /* Resources */ = {
|
||||||
isa = PBXGroup;
|
isa = PBXGroup;
|
||||||
children = (
|
children = (
|
||||||
|
23E9EB232A84E98300B792F2 /* pi_new_mine_info_online.svga */,
|
||||||
|
23E9EB222A84E98300B792F2 /* pi_new_mine_info_sound_play.svga */,
|
||||||
23E9EAA22A84C80300B792F2 /* pi_new_loading.svga */,
|
23E9EAA22A84C80300B792F2 /* pi_new_loading.svga */,
|
||||||
23E9EA6C2A83813000B792F2 /* fairy */,
|
23E9EA6C2A83813000B792F2 /* fairy */,
|
||||||
14D8768129A751E100E1DD7F /* Image */,
|
14D8768129A751E100E1DD7F /* Image */,
|
||||||
@@ -9485,8 +9493,6 @@
|
|||||||
E8EEB8F826FC285B007C6EBA /* MineInfo */ = {
|
E8EEB8F826FC285B007C6EBA /* MineInfo */ = {
|
||||||
isa = PBXGroup;
|
isa = PBXGroup;
|
||||||
children = (
|
children = (
|
||||||
E8EEB8F926FC2874007C6EBA /* XPMineUserInfoTableViewCell.h */,
|
|
||||||
E8EEB8FA26FC2874007C6EBA /* XPMineUserInfoTableViewCell.m */,
|
|
||||||
E8EEB90726FC579A007C6EBA /* XPMineUserInfoEditTableViewCell.h */,
|
E8EEB90726FC579A007C6EBA /* XPMineUserInfoEditTableViewCell.h */,
|
||||||
E8EEB90826FC579A007C6EBA /* XPMineUserInfoEditTableViewCell.m */,
|
E8EEB90826FC579A007C6EBA /* XPMineUserInfoEditTableViewCell.m */,
|
||||||
23E9EB172A84D0E700B792F2 /* XPMineUserInfoEditMainTagView.h */,
|
23E9EB172A84D0E700B792F2 /* XPMineUserInfoEditMainTagView.h */,
|
||||||
@@ -9664,7 +9670,6 @@
|
|||||||
E8729EF02A3B34D30076D80A /* js in Resources */,
|
E8729EF02A3B34D30076D80A /* js in Resources */,
|
||||||
E80EC88328ACD84000D133C5 /* emoji_70@2x.png in Resources */,
|
E80EC88328ACD84000D133C5 /* emoji_70@2x.png in Resources */,
|
||||||
E80EC89528ACD84000D133C5 /* emoji_99@2x.png in Resources */,
|
E80EC89528ACD84000D133C5 /* emoji_99@2x.png in Resources */,
|
||||||
E84A2EAF2A52F27000D6AF8A /* 1242.png in Resources */,
|
|
||||||
E80EC89128ACD84000D133C5 /* emoji_133@2x.png in Resources */,
|
E80EC89128ACD84000D133C5 /* emoji_133@2x.png in Resources */,
|
||||||
E80EC87F28ACD84000D133C5 /* emoji_137@2x.png in Resources */,
|
E80EC87F28ACD84000D133C5 /* emoji_137@2x.png in Resources */,
|
||||||
E80EC8B028ACD84100D133C5 /* emoji_152@2x.png in Resources */,
|
E80EC8B028ACD84100D133C5 /* emoji_152@2x.png in Resources */,
|
||||||
@@ -9679,6 +9684,7 @@
|
|||||||
E80EC8B428ACD84100D133C5 /* emoji_89@2x.png in Resources */,
|
E80EC8B428ACD84100D133C5 /* emoji_89@2x.png in Resources */,
|
||||||
E80EC89F28ACD84000D133C5 /* emoji_66@2x.png in Resources */,
|
E80EC89F28ACD84000D133C5 /* emoji_66@2x.png in Resources */,
|
||||||
E80EC87128ACD84000D133C5 /* emoji_160@2x.png in Resources */,
|
E80EC87128ACD84000D133C5 /* emoji_160@2x.png in Resources */,
|
||||||
|
23E9EB252A84E98300B792F2 /* pi_new_mine_info_online.svga in Resources */,
|
||||||
E80EC86D28ACD84000D133C5 /* emoji_35@2x.png in Resources */,
|
E80EC86D28ACD84000D133C5 /* emoji_35@2x.png in Resources */,
|
||||||
E80EC86528ACD84000D133C5 /* emoji_03@2x.png in Resources */,
|
E80EC86528ACD84000D133C5 /* emoji_03@2x.png in Resources */,
|
||||||
E80EC85B28ACD84000D133C5 /* emoji_69@2x.png in Resources */,
|
E80EC85B28ACD84000D133C5 /* emoji_69@2x.png in Resources */,
|
||||||
@@ -9697,6 +9703,7 @@
|
|||||||
E80EC84128ACD84000D133C5 /* emoji_16@2x.png in Resources */,
|
E80EC84128ACD84000D133C5 /* emoji_16@2x.png in Resources */,
|
||||||
E80EC83C28ACD84000D133C5 /* emoji_67@2x.png in Resources */,
|
E80EC83C28ACD84000D133C5 /* emoji_67@2x.png in Resources */,
|
||||||
E80EC8B928ACD84100D133C5 /* emoji_164@2x.png in Resources */,
|
E80EC8B928ACD84100D133C5 /* emoji_164@2x.png in Resources */,
|
||||||
|
23E9EB292A84F18000B792F2 /* pi_app_logo_bg.png in Resources */,
|
||||||
E80EC87028ACD84000D133C5 /* emoji_81@2x.png in Resources */,
|
E80EC87028ACD84000D133C5 /* emoji_81@2x.png in Resources */,
|
||||||
E80EC8AA28ACD84100D133C5 /* emoji_15@2x.png in Resources */,
|
E80EC8AA28ACD84100D133C5 /* emoji_15@2x.png in Resources */,
|
||||||
E80EC85628ACD84000D133C5 /* emoji_106@2x.png in Resources */,
|
E80EC85628ACD84000D133C5 /* emoji_106@2x.png in Resources */,
|
||||||
@@ -9766,6 +9773,7 @@
|
|||||||
E80EC84C28ACD84000D133C5 /* emoji_120@2x.png in Resources */,
|
E80EC84C28ACD84000D133C5 /* emoji_120@2x.png in Resources */,
|
||||||
23E9EAA32A84C80300B792F2 /* pi_new_loading.svga in Resources */,
|
23E9EAA32A84C80300B792F2 /* pi_new_loading.svga in Resources */,
|
||||||
E80EC83628ACD84000D133C5 /* emoji_147@2x.png in Resources */,
|
E80EC83628ACD84000D133C5 /* emoji_147@2x.png in Resources */,
|
||||||
|
23E9EB242A84E98300B792F2 /* pi_new_mine_info_sound_play.svga in Resources */,
|
||||||
E80EC86B28ACD84000D133C5 /* emoji_200@2x.png in Resources */,
|
E80EC86B28ACD84000D133C5 /* emoji_200@2x.png in Resources */,
|
||||||
E80EC88F28ACD84000D133C5 /* emoji_121@2x.png in Resources */,
|
E80EC88F28ACD84000D133C5 /* emoji_121@2x.png in Resources */,
|
||||||
E80EC87C28ACD84000D133C5 /* emoji_162@2x.png in Resources */,
|
E80EC87C28ACD84000D133C5 /* emoji_162@2x.png in Resources */,
|
||||||
@@ -10644,6 +10652,7 @@
|
|||||||
23B2AEC42A6516C200543D17 /* LoginForgetPasswordViewController.m in Sources */,
|
23B2AEC42A6516C200543D17 /* LoginForgetPasswordViewController.m in Sources */,
|
||||||
186A534C26FC6ED900D67B2C /* TTAlertView.m in Sources */,
|
186A534C26FC6ED900D67B2C /* TTAlertView.m in Sources */,
|
||||||
E8A3540428FEB7100014A784 /* XPWishGiftHistoryViewController.m in Sources */,
|
E8A3540428FEB7100014A784 /* XPWishGiftHistoryViewController.m in Sources */,
|
||||||
|
23E9EB1E2A84DA5F00B792F2 /* XPMineUserInfoNavView.m in Sources */,
|
||||||
23E9EA342A837BE400B792F2 /* TreasureFairyLimitModel.m in Sources */,
|
23E9EA342A837BE400B792F2 /* TreasureFairyLimitModel.m in Sources */,
|
||||||
E85E7B332A4EB0D300B6D00A /* XPGuildIncomeSectionView.m in Sources */,
|
E85E7B332A4EB0D300B6D00A /* XPGuildIncomeSectionView.m in Sources */,
|
||||||
E85E7B0F2A4EB0D200B6D00A /* GuildRoomInfoModel.m in Sources */,
|
E85E7B0F2A4EB0D200B6D00A /* GuildRoomInfoModel.m in Sources */,
|
||||||
@@ -10807,7 +10816,6 @@
|
|||||||
2331C0DC2A5E9E9000E1D940 /* PIFullScreenBannerAnimation.m in Sources */,
|
2331C0DC2A5E9E9000E1D940 /* PIFullScreenBannerAnimation.m in Sources */,
|
||||||
E8232600274E48EA003A3332 /* XPUserCardItemCollectionViewCell.m in Sources */,
|
E8232600274E48EA003A3332 /* XPUserCardItemCollectionViewCell.m in Sources */,
|
||||||
E88B5CC526FB42B000DA9178 /* XPMineUserInfoHeaderView.m in Sources */,
|
E88B5CC526FB42B000DA9178 /* XPMineUserInfoHeaderView.m in Sources */,
|
||||||
E8EEB8FB26FC2874007C6EBA /* XPMineUserInfoTableViewCell.m in Sources */,
|
|
||||||
E8AC721626F46B06007D6E91 /* XPMineSettingTableViewCell.m in Sources */,
|
E8AC721626F46B06007D6E91 /* XPMineSettingTableViewCell.m in Sources */,
|
||||||
18EE3FDF2750C1F700A452BF /* SessionListCell.m in Sources */,
|
18EE3FDF2750C1F700A452BF /* SessionListCell.m in Sources */,
|
||||||
9BD798B72926362F003E03E6 /* XPSessionListHeadItem.m in Sources */,
|
9BD798B72926362F003E03E6 /* XPSessionListHeadItem.m in Sources */,
|
||||||
|
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 28 KiB |
Before Width: | Height: | Size: 34 KiB After Width: | Height: | Size: 32 KiB |
Before Width: | Height: | Size: 149 B After Width: | Height: | Size: 259 B |
Before Width: | Height: | Size: 262 B After Width: | Height: | Size: 415 B |
22
YuMi/Assets.xcassets/jm/mine_user_info_edit_self.imageset/Contents.json
vendored
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
{
|
||||||
|
"images" : [
|
||||||
|
{
|
||||||
|
"idiom" : "universal",
|
||||||
|
"scale" : "1x"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename" : "mine_user_info_edit_self@2x.png",
|
||||||
|
"idiom" : "universal",
|
||||||
|
"scale" : "2x"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename" : "mine_user_info_edit_self@3x.png",
|
||||||
|
"idiom" : "universal",
|
||||||
|
"scale" : "3x"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"info" : {
|
||||||
|
"author" : "xcode",
|
||||||
|
"version" : 1
|
||||||
|
}
|
||||||
|
}
|
BIN
YuMi/Assets.xcassets/jm/mine_user_info_edit_self.imageset/mine_user_info_edit_self@2x.png
vendored
Normal file
After Width: | Height: | Size: 517 B |
BIN
YuMi/Assets.xcassets/jm/mine_user_info_edit_self.imageset/mine_user_info_edit_self@3x.png
vendored
Normal file
After Width: | Height: | Size: 875 B |
@@ -19,7 +19,7 @@ UIKIT_EXTERN NSString * const kTuWenMessageHistory;///图文消息已读记录
|
|||||||
UIKIT_EXTERN NSString * const kTeenagerStatusChange;
|
UIKIT_EXTERN NSString * const kTeenagerStatusChange;
|
||||||
UIKIT_EXTERN NSString * const kRoomQuickMessageCloseCount;
|
UIKIT_EXTERN NSString * const kRoomQuickMessageCloseCount;
|
||||||
UIKIT_EXTERN NSString * const kLoginMethod;
|
UIKIT_EXTERN NSString * const kLoginMethod;
|
||||||
typedef NS_ENUM(NSUInteger, KeyType) {
|
typedef NS_ENUM(NSUInteger, Pi_KeyType) {
|
||||||
KeyType_PasswordEncode,///密码 des 加密的
|
KeyType_PasswordEncode,///密码 des 加密的
|
||||||
KeyType_NTESQuickLoginBusinessId,///网易易盾 快捷登录 id
|
KeyType_NTESQuickLoginBusinessId,///网易易盾 快捷登录 id
|
||||||
KeyType_Agora,///声网 key
|
KeyType_Agora,///声网 key
|
||||||
@@ -38,7 +38,7 @@ typedef NS_ENUM(NSUInteger, KeyType) {
|
|||||||
};
|
};
|
||||||
|
|
||||||
/// 获取当前项目中所用到的 type 所对应的 value 的值 type 类型
|
/// 获取当前项目中所用到的 type 所对应的 value 的值 type 类型
|
||||||
NSString * const KeyWithType(KeyType type);
|
NSString * const KeyWithType(Pi_KeyType type);
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
|
@@ -38,8 +38,10 @@ NSString * const kInviteMemeberSuccess = @"a0ludml0ZU1lbWViZXJTdWNjZXNz";
|
|||||||
///登录方式
|
///登录方式
|
||||||
NSString * const kLoginMethod = @"a0xvZ2luTWV0aG9k";
|
NSString * const kLoginMethod = @"a0xvZ2luTWV0aG9k";
|
||||||
NSString * const kRequestRicket = @"a1JlcXVlc3RSaWNrZXQ=";
|
NSString * const kRequestRicket = @"a1JlcXVlc3RSaWNrZXQ=";
|
||||||
|
NSString * const kUpdateSoundInfo = @"kUpdateSoundInfo";
|
||||||
|
NSString * const kMineInfoDelTag = @"kMineInfoDelTag";
|
||||||
///在里面进行判断当前环境是什么
|
///在里面进行判断当前环境是什么
|
||||||
NSString * const KeyWithType(KeyType type) {
|
NSString * const KeyWithType(Pi_KeyType type) {
|
||||||
BOOL isRelase = NO;
|
BOOL isRelase = NO;
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
isRelase = NO;
|
isRelase = NO;
|
||||||
|
@@ -1,9 +1,9 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="21507" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="01J-lp-oVM">
|
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="21701" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="01J-lp-oVM">
|
||||||
<device id="retina6_12" orientation="portrait" appearance="light"/>
|
<device id="retina6_12" orientation="portrait" appearance="light"/>
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<deployment identifier="iOS"/>
|
<deployment identifier="iOS"/>
|
||||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21505"/>
|
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21678"/>
|
||||||
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
|
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
|
||||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
@@ -16,16 +16,41 @@
|
|||||||
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
|
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
|
||||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||||
<subviews>
|
<subviews>
|
||||||
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="1242.png" translatesAutoresizingMaskIntoConstraints="NO" id="sON-N7-5Wv">
|
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="pi_app_logo_bg.png" translatesAutoresizingMaskIntoConstraints="NO" id="sON-N7-5Wv">
|
||||||
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
|
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
|
||||||
</imageView>
|
</imageView>
|
||||||
|
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="邂逅你的專屬聲音~" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="o5T-sv-tDU">
|
||||||
|
<rect key="frame" x="117.66666666666669" y="410" width="158" height="22"/>
|
||||||
|
<fontDescription key="fontDescription" type="system" pointSize="18"/>
|
||||||
|
<color key="textColor" red="0.023529411760000001" green="0.043137254899999998" blue="0.090196078430000007" alpha="1" colorSpace="calibratedRGB"/>
|
||||||
|
<nil key="highlightedColor"/>
|
||||||
|
</label>
|
||||||
|
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="ming_setting_about_us" translatesAutoresizingMaskIntoConstraints="NO" id="v2t-MR-31f">
|
||||||
|
<rect key="frame" x="147.66666666666666" y="246.66666666666666" width="97.666666666666657" height="97.333333333333343"/>
|
||||||
|
<constraints>
|
||||||
|
<constraint firstAttribute="width" secondItem="v2t-MR-31f" secondAttribute="height" multiplier="1:1" id="7Yl-KK-KgD"/>
|
||||||
|
</constraints>
|
||||||
|
</imageView>
|
||||||
|
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Piko" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="BLt-qv-lx2">
|
||||||
|
<rect key="frame" x="168.33333333333334" y="362.66666666666669" width="56.666666666666657" height="33"/>
|
||||||
|
<fontDescription key="fontDescription" type="system" weight="heavy" pointSize="27"/>
|
||||||
|
<color key="textColor" red="0.023529411760000001" green="0.043137254899999998" blue="0.090196078430000007" alpha="1" colorSpace="calibratedRGB"/>
|
||||||
|
<nil key="highlightedColor"/>
|
||||||
|
</label>
|
||||||
</subviews>
|
</subviews>
|
||||||
<viewLayoutGuide key="safeArea" id="r4O-Vu-IrR"/>
|
<viewLayoutGuide key="safeArea" id="r4O-Vu-IrR"/>
|
||||||
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||||
<constraints>
|
<constraints>
|
||||||
<constraint firstAttribute="bottom" secondItem="sON-N7-5Wv" secondAttribute="bottom" id="4Vv-qk-e25"/>
|
<constraint firstAttribute="bottom" secondItem="sON-N7-5Wv" secondAttribute="bottom" id="4Vv-qk-e25"/>
|
||||||
|
<constraint firstItem="v2t-MR-31f" firstAttribute="centerX" secondItem="Ze5-6b-2t3" secondAttribute="centerX" id="4gc-t8-g81"/>
|
||||||
|
<constraint firstItem="v2t-MR-31f" firstAttribute="top" secondItem="Ze5-6b-2t3" secondAttribute="bottom" multiplier="193/667" id="BdJ-dM-Fdd"/>
|
||||||
|
<constraint firstItem="BLt-qv-lx2" firstAttribute="top" secondItem="Ze5-6b-2t3" secondAttribute="bottom" multiplier="284/667" id="GUO-Sj-fzX"/>
|
||||||
|
<constraint firstItem="o5T-sv-tDU" firstAttribute="top" secondItem="Ze5-6b-2t3" secondAttribute="bottom" multiplier="321/667" id="Hca-mS-0vk"/>
|
||||||
|
<constraint firstItem="BLt-qv-lx2" firstAttribute="centerX" secondItem="Ze5-6b-2t3" secondAttribute="centerX" id="JbL-ge-b1e"/>
|
||||||
<constraint firstItem="sON-N7-5Wv" firstAttribute="top" secondItem="Ze5-6b-2t3" secondAttribute="top" id="Ki6-l8-8JM"/>
|
<constraint firstItem="sON-N7-5Wv" firstAttribute="top" secondItem="Ze5-6b-2t3" secondAttribute="top" id="Ki6-l8-8JM"/>
|
||||||
|
<constraint firstItem="v2t-MR-31f" firstAttribute="width" secondItem="Ze5-6b-2t3" secondAttribute="width" multiplier="93/375" id="LgX-Hp-VwW"/>
|
||||||
<constraint firstItem="sON-N7-5Wv" firstAttribute="trailing" secondItem="r4O-Vu-IrR" secondAttribute="trailing" id="Y7p-jQ-Nff"/>
|
<constraint firstItem="sON-N7-5Wv" firstAttribute="trailing" secondItem="r4O-Vu-IrR" secondAttribute="trailing" id="Y7p-jQ-Nff"/>
|
||||||
|
<constraint firstItem="o5T-sv-tDU" firstAttribute="centerX" secondItem="Ze5-6b-2t3" secondAttribute="centerX" id="Yej-IY-emP"/>
|
||||||
<constraint firstItem="sON-N7-5Wv" firstAttribute="leading" secondItem="r4O-Vu-IrR" secondAttribute="leading" id="rva-mD-Vhe"/>
|
<constraint firstItem="sON-N7-5Wv" firstAttribute="leading" secondItem="r4O-Vu-IrR" secondAttribute="leading" id="rva-mD-Vhe"/>
|
||||||
</constraints>
|
</constraints>
|
||||||
</view>
|
</view>
|
||||||
@@ -36,6 +61,7 @@
|
|||||||
</scene>
|
</scene>
|
||||||
</scenes>
|
</scenes>
|
||||||
<resources>
|
<resources>
|
||||||
<image name="1242.png" width="1242" height="2690"/>
|
<image name="ming_setting_about_us" width="96" height="96"/>
|
||||||
|
<image name="pi_app_logo_bg.png" width="428" height="761"/>
|
||||||
</resources>
|
</resources>
|
||||||
</document>
|
</document>
|
||||||
|
@@ -287,7 +287,7 @@
|
|||||||
nick = [NSString stringWithFormat:@"%@...", nick];
|
nick = [NSString stringWithFormat:@"%@...", nick];
|
||||||
}
|
}
|
||||||
self.nickLabel.text = nick;
|
self.nickLabel.text = nick;
|
||||||
self.signLabel.text = _userInfo.userDesc.length > 0 ? _userInfo.userDesc : YMLocalizedString(@"SessionUserInfoTableViewCell5");
|
self.signLabel.text = _userInfo.userDesc.length > 0 ? _userInfo.userDesc : YMLocalizedString(@"XPTreasureFairyFriendCell0");
|
||||||
self.nobleImageView.imageUrl = _userInfo.userVipInfoVO.vipIcon;
|
self.nobleImageView.imageUrl = _userInfo.userVipInfoVO.vipIcon;
|
||||||
self.nobleImageView.hidden = _userInfo.userVipInfoVO.vipIcon.length > 0 ? NO : YES;
|
self.nobleImageView.hidden = _userInfo.userVipInfoVO.vipIcon.length > 0 ? NO : YES;
|
||||||
NSString * headurl = userInfo.headwearEffect.length > 0 ? userInfo.headwearEffect : userInfo.headwearPic;
|
NSString * headurl = userInfo.headwearEffect.length > 0 ? userInfo.headwearEffect : userInfo.headwearPic;
|
||||||
|
@@ -21,6 +21,19 @@ NS_ASSUME_NONNULL_BEGIN
|
|||||||
- (void)memberApplyHall:(NSString *)hallId;
|
- (void)memberApplyHall:(NSString *)hallId;
|
||||||
|
|
||||||
- (void)getUserInfo:(NSString *)uid success:(void(^)(UserInfoModel * info))success;
|
- (void)getUserInfo:(NSString *)uid success:(void(^)(UserInfoModel * info))success;
|
||||||
|
/// 动态点赞
|
||||||
|
/// @param dynamicId 动态id
|
||||||
|
/// @param status yes 点赞 NO 取消
|
||||||
|
/// @param likedUid 点赞人的uid
|
||||||
|
/// @param worldId 话题的id
|
||||||
|
- (void)likeMonent:(NSString *)dynamicId status:(BOOL)status likedUid:(NSString *)likedUid worldId:(NSString *)worldId;
|
||||||
|
|
||||||
|
/// 删除动态
|
||||||
|
/// @param dynamicId 动态id
|
||||||
|
/// @param worldId 话题id
|
||||||
|
- (void)deleteMonents:(NSString *)dynamicId worldId:(NSString *)worldId;
|
||||||
|
///屏蔽
|
||||||
|
- (void)requesstShieldingWtihType:(NSString *)type objId:(NSString *)objId;
|
||||||
@end
|
@end
|
||||||
|
|
||||||
NS_ASSUME_NONNULL_END
|
NS_ASSUME_NONNULL_END
|
||||||
|
@@ -13,6 +13,9 @@
|
|||||||
#import "MineSkillCardListInfoModel.h"
|
#import "MineSkillCardListInfoModel.h"
|
||||||
#import "XPMineUserDataProtocol.h"
|
#import "XPMineUserDataProtocol.h"
|
||||||
#import "UserInfoModel.h"
|
#import "UserInfoModel.h"
|
||||||
|
#import "Api+Monents.h"
|
||||||
|
#import "Api+Room.h"
|
||||||
|
#import "XPMonentsMineProtocol.h"
|
||||||
@implementation XPMineUserDataPresenter
|
@implementation XPMineUserDataPresenter
|
||||||
|
|
||||||
/// 获取会长和当前用户家族详细的信息
|
/// 获取会长和当前用户家族详细的信息
|
||||||
@@ -65,5 +68,31 @@
|
|||||||
}
|
}
|
||||||
}] uid:uid];
|
}] uid:uid];
|
||||||
}
|
}
|
||||||
|
/// 动态点赞
|
||||||
|
/// @param dynamicId 动态id
|
||||||
|
/// @param status yes 点赞 NO 取消
|
||||||
|
/// @param likedUid 点赞人的uid
|
||||||
|
/// @param worldId 话题的id
|
||||||
|
- (void)likeMonent:(NSString *)dynamicId status:(BOOL)status likedUid:(NSString *)likedUid worldId:(NSString *)worldId {
|
||||||
|
NSString * uid = [AccountInfoStorage instance].getUid;
|
||||||
|
NSString * statusStr = status ? @"1" : @"0";
|
||||||
|
[Api monentsLike:[self createHttpCompletion:^(BaseModel * _Nonnull data) {
|
||||||
|
[[self getView] likeMonentsSuccess:dynamicId status:status];
|
||||||
|
} showLoading:YES] dynamicId:dynamicId uid:uid status:statusStr likedUid:likedUid worldId:worldId];
|
||||||
|
}
|
||||||
|
|
||||||
|
/// 删除动态
|
||||||
|
/// @param dynamicId 动态id
|
||||||
|
/// @param worldId 话题id
|
||||||
|
- (void)deleteMonents:(NSString *)dynamicId worldId:(NSString *)worldId {
|
||||||
|
NSString * uid = [AccountInfoStorage instance].getUid;
|
||||||
|
[Api monentsDelete:^(BaseModel * _Nullable data, NSInteger code, NSString * _Nullable msg) {
|
||||||
|
[[self getView] deleteMonentsSuccess:dynamicId];
|
||||||
|
} uid:uid dynamicId:dynamicId worldId:worldId];
|
||||||
|
}
|
||||||
|
- (void)requesstShieldingWtihType:(NSString *)type objId:(NSString *)objId{
|
||||||
|
[Api requesstShielding:[self createHttpCompletion:^(BaseModel * _Nonnull data) {
|
||||||
|
[[self getView] requesstShieldingSuccess:objId];
|
||||||
|
}] type:type objId:objId];
|
||||||
|
}
|
||||||
@end
|
@end
|
||||||
|
@@ -1,11 +1,12 @@
|
|||||||
//
|
//
|
||||||
// YMMineDataClanTableViewCell.h
|
// XPMineDataClanTableViewCell.h
|
||||||
// YUMI
|
// xplan-ios
|
||||||
//
|
//
|
||||||
// Created by YUMI on 2022/4/14.
|
// Created by 冯硕 on 2022/4/14.
|
||||||
//
|
//
|
||||||
|
|
||||||
#import <UIKit/UIKit.h>
|
#import <UIKit/UIKit.h>
|
||||||
|
#import "UserInfoModel.h"
|
||||||
|
|
||||||
NS_ASSUME_NONNULL_BEGIN
|
NS_ASSUME_NONNULL_BEGIN
|
||||||
@class ClanDetailInfoModel, XPMineDataClanTableViewCell;
|
@class ClanDetailInfoModel, XPMineDataClanTableViewCell;
|
||||||
@@ -18,12 +19,16 @@ NS_ASSUME_NONNULL_BEGIN
|
|||||||
- (void)xPMineDataClanTableViewCell:(XPMineDataClanTableViewCell *)view didClickClanView:(ClanDetailInfoModel *)clanInfo;
|
- (void)xPMineDataClanTableViewCell:(XPMineDataClanTableViewCell *)view didClickClanView:(ClanDetailInfoModel *)clanInfo;
|
||||||
///点击了公会房间
|
///点击了公会房间
|
||||||
- (void)xPMineDataClanTableViewCell:(XPMineDataClanTableViewCell *)view didClickHallView:(ClanDetailInfoModel *)clanInfo;
|
- (void)xPMineDataClanTableViewCell:(XPMineDataClanTableViewCell *)view didClickHallView:(ClanDetailInfoModel *)clanInfo;
|
||||||
|
///点击了展开
|
||||||
|
- (void)xPMineDataClanTableViewCell:(XPMineDataClanTableViewCell *)view didClickOpen:(ClanDetailInfoModel *)clanInfo;
|
||||||
@end
|
@end
|
||||||
@interface XPMineDataClanTableViewCell : UITableViewCell
|
@interface XPMineDataClanTableViewCell : UITableViewCell
|
||||||
///是否展示加入公会
|
///是否展示加入公会
|
||||||
@property (nonatomic,assign) BOOL isShowEnterHall;
|
@property (nonatomic,assign) BOOL isShowEnterHall;
|
||||||
|
|
||||||
@property (nonatomic,strong) ClanDetailInfoModel *clanInfo;
|
@property (nonatomic,strong) ClanDetailInfoModel *clanInfo;
|
||||||
|
@property (nonatomic,strong) UserInfoModel *userInfo;
|
||||||
|
@property (nonatomic,assign) BOOL isOpne;
|
||||||
///代理
|
///代理
|
||||||
@property (nonatomic,weak) id<XPMineDataClanTableViewCellDelegate> delegate;
|
@property (nonatomic,weak) id<XPMineDataClanTableViewCellDelegate> delegate;
|
||||||
@end
|
@end
|
||||||
|
@@ -1,357 +1,447 @@
|
|||||||
//
|
//
|
||||||
// YMMineDataClanTableViewCell.m
|
// XPMineDataClanTableViewCell.m
|
||||||
// YUMI
|
// xplan-ios
|
||||||
//
|
//
|
||||||
// Created by YUMI on 2022/4/14.
|
// Created by 冯硕 on 2022/4/14.
|
||||||
//
|
//
|
||||||
|
|
||||||
#import "XPMineDataClanTableViewCell.h"
|
#import "XPMineDataClanTableViewCell.h"
|
||||||
///Third
|
///Third
|
||||||
#import <Masonry/Masonry.h>
|
#import <Masonry/Masonry.h>
|
||||||
|
#import <YYText/YYText.h>
|
||||||
///Tool
|
///Tool
|
||||||
#import "DJDKMIMOMColor.h"
|
|
||||||
#import "NetImageView.h"
|
#import "NetImageView.h"
|
||||||
#import "UIButton+EnlargeTouchArea.h"
|
#import "UIButton+EnlargeTouchArea.h"
|
||||||
///Model
|
///Model
|
||||||
#import "ClanDetailInfoModel.h"
|
#import "ClanDetailInfoModel.h"
|
||||||
|
|
||||||
@interface XPMineDataClanTableViewCell ()
|
@interface XPMineDataClanTableViewCell ()
|
||||||
///背景
|
/////背景
|
||||||
@property (nonatomic,strong) UIView *backView;
|
@property (nonatomic,strong) UIView *backView;
|
||||||
///显示标题
|
/////显示标题
|
||||||
@property (nonatomic,strong) UILabel *titleLabel;
|
@property (nonatomic,strong) UILabel *titleLabel;
|
||||||
///容器
|
|
||||||
@property (nonatomic,strong) UIStackView *stackView;
|
///星座
|
||||||
///家族
|
@property (nonatomic,strong) UILabel *starView;
|
||||||
@property (nonatomic,strong) UIView * clanView;
|
///星座背景图片
|
||||||
///家族头像
|
@property (nonatomic,strong) UIImageView *starIconView;
|
||||||
@property (nonatomic,strong) NetImageView *clanImageView;
|
///星座
|
||||||
///家族昵称
|
@property (nonatomic,strong) UILabel *starTitleView;
|
||||||
@property (nonatomic,strong) UILabel *clanNickLabel;
|
///生日
|
||||||
///展开
|
@property (nonatomic,strong) UILabel *birthdayHeadView;
|
||||||
@property (nonatomic,strong) UIButton *foldButton;
|
@property (nonatomic,strong) UILabel *birthdayView;
|
||||||
///分割线
|
///地区
|
||||||
@property (nonatomic,strong) UIView * lineView;
|
@property (nonatomic,strong) UILabel *areaHeadView;
|
||||||
|
@property (nonatomic,strong) UILabel *areaView;
|
||||||
|
@property (nonatomic,strong) UIButton *areaMornBnt;
|
||||||
|
@property (nonatomic,strong) UIButton *areaIconView;
|
||||||
|
///房间
|
||||||
|
@property (nonatomic,strong) UILabel *roomHeadView;
|
||||||
|
@property (nonatomic,strong) UILabel *roomView;
|
||||||
|
@property (nonatomic,strong) UIButton *roomIconView;
|
||||||
|
|
||||||
///公会
|
///公会
|
||||||
@property (nonatomic,strong) UIView * hallView;
|
@property (nonatomic,strong) UILabel *clanHeadView;
|
||||||
///公会头像
|
@property (nonatomic,strong) UILabel *clanView;
|
||||||
@property (nonatomic,strong) NetImageView *hallImageView;
|
@property (nonatomic,strong) UIButton *clanIconView;
|
||||||
///公会昵称
|
|
||||||
@property (nonatomic,strong) UILabel *hallNickLabel;
|
|
||||||
///加入
|
|
||||||
@property (nonatomic,strong) UIButton *enterButton;
|
|
||||||
///是否折叠
|
|
||||||
@property (nonatomic,assign) BOOL isfold;
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
@implementation XPMineDataClanTableViewCell
|
@implementation XPMineDataClanTableViewCell
|
||||||
|
|
||||||
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
|
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
|
||||||
if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
|
if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
|
||||||
[self initSubViews];
|
[self initSubViews];
|
||||||
[self initSubViewConstraints];
|
[self initSubViewConstraints];
|
||||||
}
|
}
|
||||||
return self;
|
return self;
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - Private Method
|
#pragma mark - Private Method
|
||||||
- (void)initSubViews {
|
- (void)initSubViews {
|
||||||
self.isfold = YES;
|
self.backgroundColor = [UIColor clearColor];
|
||||||
self.backgroundColor = [UIColor clearColor];
|
self.selectionStyle = UITableViewCellSelectionStyleNone;
|
||||||
self.selectionStyle = UITableViewCellSelectionStyleNone;
|
[self.contentView addSubview:self.backView];
|
||||||
[self.contentView addSubview:self.backView];
|
[self.backView addSubview:self.titleLabel];
|
||||||
[self.backView addSubview:self.titleLabel];
|
[self.backView addSubview:self.starView];
|
||||||
[self.backView addSubview:self.stackView];
|
[self.backView addSubview:self.starIconView];
|
||||||
[self.stackView addArrangedSubview:self.clanView];
|
[self.starIconView addSubview:self.starTitleView];
|
||||||
[self.stackView addArrangedSubview:self.hallView];
|
[self.backView addSubview:self.birthdayHeadView];
|
||||||
|
[self.backView addSubview:self.birthdayView];
|
||||||
[self.clanView addSubview:self.clanImageView];
|
[self.backView addSubview:self.areaHeadView];
|
||||||
[self.clanView addSubview:self.clanNickLabel];
|
[self.backView addSubview:self.areaView];
|
||||||
[self.clanView addSubview:self.foldButton];
|
[self.backView addSubview:self.areaMornBnt];
|
||||||
[self.clanView addSubview:self.lineView];
|
[self.backView addSubview:self.areaIconView];
|
||||||
|
|
||||||
[self.hallView addSubview:self.hallImageView];
|
[self.backView addSubview:self.roomHeadView];
|
||||||
[self.hallView addSubview:self.hallNickLabel];
|
[self.backView addSubview:self.roomView];
|
||||||
[self.hallView addSubview:self.enterButton];
|
[self.backView addSubview:self.roomIconView];
|
||||||
|
[self.backView addSubview:self.clanHeadView];
|
||||||
|
[self.backView addSubview:self.clanView];
|
||||||
|
[self.backView addSubview:self.clanIconView];
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)initSubViewConstraints {
|
- (void)initSubViewConstraints {
|
||||||
[self.backView mas_makeConstraints:^(MASConstraintMaker *make) {
|
[self.backView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.left.right.mas_equalTo(self.contentView).inset(15);
|
make.left.right.mas_equalTo(self.contentView).inset(kGetScaleWidth(15));
|
||||||
make.top.mas_equalTo(self.contentView);
|
make.top.mas_equalTo(self.contentView);
|
||||||
make.bottom.mas_equalTo(self.contentView).offset(-15);
|
make.bottom.mas_equalTo(self.contentView).mas_offset(-kGetScaleWidth(12));
|
||||||
}];
|
}];
|
||||||
|
|
||||||
[self.titleLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
[self.titleLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.left.mas_equalTo(self.backView).offset(12);
|
make.left.mas_equalTo(self.backView).offset(kGetScaleWidth(12));
|
||||||
make.top.mas_equalTo(self.backView).offset(10);
|
make.top.mas_equalTo(self.backView).offset(kGetScaleWidth(10));
|
||||||
}];
|
make.height.mas_equalTo(kGetScaleWidth(17));
|
||||||
|
}];
|
||||||
[self.stackView mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.left.mas_equalTo(self.backView).offset(10);
|
[self.starView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.top.mas_equalTo(self.titleLabel.mas_bottom).offset(5);
|
make.left.height.equalTo(self.titleLabel);
|
||||||
make.right.mas_equalTo(self.backView).offset(-10);
|
make.top.equalTo(self.titleLabel.mas_bottom).mas_offset(kGetScaleWidth(12));
|
||||||
}];
|
|
||||||
|
}];
|
||||||
[self.clanView mas_makeConstraints:^(MASConstraintMaker *make) {
|
[self.starIconView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.height.mas_equalTo(68);
|
make.height.mas_equalTo(kGetScaleWidth(13));
|
||||||
}];
|
make.width.mas_equalTo(kGetScaleWidth(38));
|
||||||
|
make.centerY.equalTo(self.starView);
|
||||||
|
make.left.equalTo(self.starView.mas_right).mas_offset(kGetScaleWidth(10));
|
||||||
[self.clanImageView mas_makeConstraints:^(MASConstraintMaker *make) {
|
}];
|
||||||
make.size.mas_equalTo(CGSizeMake(48, 48));
|
[self.starTitleView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.left.centerY.mas_equalTo(self.clanView);
|
make.left.mas_equalTo(kGetScaleWidth(5));
|
||||||
}];
|
make.right.mas_equalTo(-kGetScaleWidth(5));
|
||||||
|
make.top.bottom.equalTo(self.starIconView);
|
||||||
[self.clanNickLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
}];
|
||||||
make.left.mas_equalTo(self.clanImageView.mas_right).offset(10);
|
[self.birthdayHeadView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.centerY.mas_equalTo(self.clanImageView.mas_centerY);
|
make.left.height.equalTo(self.titleLabel);
|
||||||
}];
|
make.top.equalTo(self.starView.mas_bottom).mas_offset(kGetScaleWidth(5));
|
||||||
|
}];
|
||||||
[self.foldButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
[self.birthdayView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.size.mas_equalTo(CGSizeMake(13, 22));
|
make.centerY.equalTo(self.birthdayHeadView);
|
||||||
make.right.mas_equalTo(self.clanView);
|
make.left.equalTo(self.starIconView);
|
||||||
make.centerY.mas_equalTo(self.clanView);
|
}];
|
||||||
}];
|
|
||||||
|
|
||||||
[self.lineView mas_makeConstraints:^(MASConstraintMaker *make) {
|
[self.areaHeadView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.bottom.left.right.mas_equalTo(self.clanView);
|
make.left.height.equalTo(self.titleLabel);
|
||||||
make.height.mas_equalTo(1);
|
make.top.mas_equalTo(kGetScaleWidth(84));
|
||||||
}];
|
}];
|
||||||
|
[self.areaView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
[self.hallView mas_makeConstraints:^(MASConstraintMaker *make) {
|
make.height.centerY.equalTo(self.areaHeadView);
|
||||||
make.height.mas_equalTo(60);
|
make.left.equalTo(self.starIconView);
|
||||||
}];
|
}];
|
||||||
|
[self.areaMornBnt mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
[self.hallImageView mas_makeConstraints:^(MASConstraintMaker *make) {
|
make.width.mas_equalTo(kGetScaleWidth(25));
|
||||||
make.size.mas_equalTo(CGSizeMake(40, 40));
|
make.height.mas_equalTo(kGetScaleWidth(17));
|
||||||
make.centerY.mas_equalTo(self.hallView);
|
make.left.equalTo(self.areaView.mas_right).mas_offset(kGetScaleWidth(8));
|
||||||
make.left.mas_equalTo(self.hallView);
|
make.centerY.equalTo(self.areaView);
|
||||||
}];
|
}];
|
||||||
|
|
||||||
[self.hallNickLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.centerY.mas_equalTo(self.hallView);
|
[self.areaIconView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.left.mas_equalTo(self.hallImageView.mas_right).offset(10);
|
make.width.height.mas_equalTo(kGetScaleWidth(20));
|
||||||
make.right.mas_lessThanOrEqualTo(self.enterButton.mas_left).offset(-5);
|
make.centerY.equalTo(self.areaView);
|
||||||
}];
|
make.left.equalTo(self.areaMornBnt.mas_right);
|
||||||
|
}];
|
||||||
[self.enterButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.size.mas_equalTo(CGSizeMake(56, 20));
|
|
||||||
make.centerY.mas_equalTo(self.hallView);
|
[self.roomHeadView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.right.mas_equalTo(self.hallView);
|
make.left.height.equalTo(self.titleLabel);
|
||||||
}];
|
make.top.mas_equalTo(kGetScaleWidth(106));
|
||||||
|
}];
|
||||||
|
[self.roomView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.height.centerY.equalTo(self.roomHeadView);
|
||||||
|
make.left.equalTo(self.starIconView);
|
||||||
|
}];
|
||||||
|
[self.roomIconView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.width.height.mas_equalTo(kGetScaleWidth(20));
|
||||||
|
make.centerY.equalTo(self.roomHeadView);
|
||||||
|
make.left.equalTo(self.roomView.mas_right);
|
||||||
|
}];
|
||||||
|
[self.clanHeadView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.left.height.equalTo(self.titleLabel);
|
||||||
|
make.top.mas_equalTo(kGetScaleWidth(130));
|
||||||
|
}];
|
||||||
|
[self.clanView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.centerY.equalTo(self.clanHeadView);
|
||||||
|
make.left.equalTo(self.starIconView);
|
||||||
|
}];
|
||||||
|
[self.clanIconView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.width.height.mas_equalTo(kGetScaleWidth(20));
|
||||||
|
make.centerY.equalTo(self.clanHeadView);
|
||||||
|
make.left.equalTo(self.clanView.mas_right);
|
||||||
|
}];
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - Event Response
|
#pragma mark - Event Response
|
||||||
- (void)enterButtonAction:(UIButton *)sender {
|
- (void)enterButtonAction:(UIButton *)sender {
|
||||||
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMineDataClanTableViewCell:didClickEnter:)]) {
|
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMineDataClanTableViewCell:didClickEnter:)]) {
|
||||||
[self.delegate xPMineDataClanTableViewCell:self didClickEnter:self.clanInfo];
|
[self.delegate xPMineDataClanTableViewCell:self didClickEnter:self.clanInfo];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)foldButtonAction:(UIButton *)sender{
|
- (void)foldButtonAction:(UIButton *)sender{
|
||||||
sender.selected = !sender.selected;
|
sender.selected = !sender.selected;
|
||||||
self.hallView.hidden = !self.hallView.hidden;
|
|
||||||
[UIView animateWithDuration:0.2 animations:^{
|
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMineDataClanTableViewCell:didClickFold:)]) {
|
||||||
if (self.foldButton.selected) {
|
[self.delegate xPMineDataClanTableViewCell:self didClickFold:sender];
|
||||||
self.foldButton.transform = CGAffineTransformIdentity;
|
}
|
||||||
} else {
|
|
||||||
self.foldButton.transform = CGAffineTransformMakeRotation(M_PI / 2);
|
|
||||||
}
|
|
||||||
}];
|
|
||||||
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMineDataClanTableViewCell:didClickFold:)]) {
|
|
||||||
[self.delegate xPMineDataClanTableViewCell:self didClickFold:sender];
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)didTapClanView {
|
- (void)didTapClanView {
|
||||||
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMineDataClanTableViewCell:didClickClanView:)]) {
|
if (_clanInfo.clan.elderUid.length <= 0) return;
|
||||||
[self.delegate xPMineDataClanTableViewCell:self didClickClanView:self.clanInfo];
|
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMineDataClanTableViewCell:didClickClanView:)]) {
|
||||||
}
|
[self.delegate xPMineDataClanTableViewCell:self didClickClanView:self.clanInfo];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)didTapHallView {
|
- (void)didTapHallView {
|
||||||
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMineDataClanTableViewCell:didClickHallView:)]) {
|
if(_clanInfo.hall.hallName.length <= 0)return;
|
||||||
[self.delegate xPMineDataClanTableViewCell:self didClickHallView:self.clanInfo];
|
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMineDataClanTableViewCell:didClickHallView:)]) {
|
||||||
}
|
[self.delegate xPMineDataClanTableViewCell:self didClickHallView:self.clanInfo];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
- (void)didTapAreaView {
|
||||||
|
if(self.delegate && [self.delegate respondsToSelector:@selector(xPMineDataClanTableViewCell:didClickOpen:)]){
|
||||||
|
[self.delegate xPMineDataClanTableViewCell:self didClickOpen:self.clanInfo];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - Getters And Setters
|
#pragma mark - Getters And Setters
|
||||||
- (void)setClanInfo:(ClanDetailInfoModel *)clanInfo {
|
- (void)setClanInfo:(ClanDetailInfoModel *)clanInfo {
|
||||||
_clanInfo = clanInfo;
|
_clanInfo = clanInfo;
|
||||||
if (_clanInfo) {
|
if (_clanInfo) {
|
||||||
self.clanView.hidden = _clanInfo.clan.elderUid.length <= 0;
|
_clanView.text = _clanInfo.clan.name;
|
||||||
if (self.clanInfo.clan.elderUid.length > 0) {
|
_roomView.text = _clanInfo.hall.hallName.length > 0 ? _clanInfo.hall.hallName :([[AccountInfoStorage instance] getUid].integerValue == self.userInfo.uid ? YMLocalizedString(@"XPMineDataClanTableViewCell12") : YMLocalizedString(@"XPMineDataClanTableViewCell11")) ;
|
||||||
if (self.clanInfo.hall.ownerUid.length > 0) {
|
_roomIconView.hidden = !(_clanInfo.hall.hallName.length > 0);
|
||||||
self.titleLabel.text = YMLocalizedString(@"XPMineDataClanTableViewCell0");
|
_roomView.textColor = _clanInfo.hall.hallName.length > 0 ? UIColorFromRGB(0xFFBC51):[DJDKMIMOMColor inputTextColor];
|
||||||
self.foldButton.hidden = NO;
|
if(self.isOpne == YES){
|
||||||
self.clanView.hidden = NO;
|
self.areaMornBnt.hidden = YES;
|
||||||
self.hallView.hidden = self.isfold ? YES : NO;
|
self.areaIconView.hidden = YES;
|
||||||
} else {
|
self.roomHeadView.hidden = NO;
|
||||||
self.titleLabel.text = YMLocalizedString(@"XPMineDataClanTableViewCell1");
|
self.roomView.hidden = NO;
|
||||||
self.foldButton.hidden = YES;
|
self.clanView.hidden = YES;
|
||||||
self.clanView.hidden = NO;
|
self.clanHeadView.hidden = YES;
|
||||||
self.hallView.hidden = YES;
|
self.clanIconView.hidden = YES;
|
||||||
}
|
if (self.clanInfo.clan.elderUid.length > 0) {
|
||||||
} else {
|
self.clanView.hidden = NO;
|
||||||
if (self.clanInfo.hall.ownerUid.length > 0) {
|
self.clanHeadView.hidden = NO;
|
||||||
self.titleLabel.text = YMLocalizedString(@"XPMineDataClanTableViewCell2");
|
self.clanIconView.hidden = NO;
|
||||||
self.clanView.hidden = YES;
|
}
|
||||||
self.hallView.hidden = NO;
|
}else{
|
||||||
} else {
|
self.roomHeadView.hidden = YES;
|
||||||
self.clanView.hidden = YES;
|
self.roomView.hidden = YES;
|
||||||
self.hallView.hidden = YES;
|
self.roomIconView.hidden = YES;
|
||||||
}
|
self.clanView.hidden = YES;
|
||||||
}
|
self.clanHeadView.hidden = YES;
|
||||||
self.foldButton.hidden = YES;
|
self.clanIconView.hidden = YES;
|
||||||
self.clanImageView.imageUrl = _clanInfo.clan.avatar;
|
self.areaMornBnt.hidden = NO;
|
||||||
self.clanNickLabel.text = _clanInfo.clan.name;
|
self.areaIconView.hidden = NO;
|
||||||
self.hallImageView.imageUrl = _clanInfo.hall.ownerAvatar;
|
}
|
||||||
self.hallNickLabel.text = _clanInfo.hall.hallName;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
-(void)setUserInfo:(UserInfoModel *)userInfo{
|
||||||
|
_userInfo = userInfo;
|
||||||
|
_starIconView.hidden = NO;
|
||||||
|
NSString *dateStr = [NSString stringWithFormat:@"%@",[self calculateConstellationWithMonth:_userInfo.birth]];
|
||||||
|
_starTitleView.text = dateStr;
|
||||||
|
_birthdayView.text = [NSDate timestampSwitchTime:_userInfo.birth / 1000 andFormatter:@"yyyy-MM-dd"];
|
||||||
|
_areaView.text = _userInfo.region;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
- (NSString *)calculateConstellationWithMonth:(long)time
|
||||||
|
{
|
||||||
|
NSString *astroString = YMLocalizedString(@"XPMineHeadView0");
|
||||||
|
NSString *astroFormat = @"102123444543";
|
||||||
|
NSString *result;
|
||||||
|
|
||||||
|
NSInteger month = [self getMonth:time];
|
||||||
|
NSInteger day = [self getDay:time];
|
||||||
|
|
||||||
|
if (month<1 || month>12 || day<1 || day>31){
|
||||||
|
return YMLocalizedString(@"XPMineHeadView1");
|
||||||
|
}
|
||||||
|
|
||||||
|
if(month==2 && day>29)
|
||||||
|
{
|
||||||
|
return YMLocalizedString(@"XPMineHeadView2");
|
||||||
|
}else if(month==4 || month==6 || month==9 || month==11) {
|
||||||
|
if (day>30) {
|
||||||
|
return YMLocalizedString(@"XPMineHeadView3");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
result=[NSString stringWithFormat:@"%@",[astroString substringWithRange:NSMakeRange(month*2-(day < [[astroFormat substringWithRange:NSMakeRange((month-1), 1)] intValue] - (-19))*2,2)]];
|
||||||
|
|
||||||
|
return [NSString stringWithFormat:YMLocalizedString(@"XPMineHeadView6"),result];
|
||||||
|
}
|
||||||
|
|
||||||
|
-(NSInteger) getMonth:(long )time
|
||||||
|
{
|
||||||
|
NSDate *date = [NSDate dateWithTimeIntervalSince1970:time/1000];
|
||||||
|
NSCalendar* calendar = [NSCalendar currentCalendar];
|
||||||
|
NSDateComponents* components = [calendar components:NSCalendarUnitMonth fromDate:date];
|
||||||
|
NSInteger month = components.month;
|
||||||
|
return month;
|
||||||
|
}
|
||||||
|
|
||||||
|
- (NSInteger) getDay:(long) time
|
||||||
|
{
|
||||||
|
NSDate *date = [NSDate dateWithTimeIntervalSince1970:time/1000];
|
||||||
|
NSCalendar* calendar = [NSCalendar currentCalendar];
|
||||||
|
NSDateComponents* components = [calendar components:NSCalendarUnitDay fromDate:date];
|
||||||
|
NSInteger day = components.day;
|
||||||
|
return day;
|
||||||
|
}
|
||||||
- (void)setIsShowEnterHall:(BOOL)isShowEnterHall {
|
- (void)setIsShowEnterHall:(BOOL)isShowEnterHall {
|
||||||
_isShowEnterHall = isShowEnterHall;
|
_isShowEnterHall = isShowEnterHall;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (UIView *)backView {
|
- (UIView *)backView {
|
||||||
if (!_backView) {
|
if (!_backView) {
|
||||||
_backView = [[UIView alloc] init];
|
_backView = [[UIView alloc] init];
|
||||||
_backView.userInteractionEnabled = YES;
|
_backView.userInteractionEnabled = YES;
|
||||||
_backView.layer.cornerRadius = 10;
|
_backView.layer.cornerRadius = kGetScaleWidth(8);
|
||||||
_backView.backgroundColor =[DJDKMIMOMColor appCellBackgroundColor];
|
_backView.backgroundColor =[UIColor whiteColor];
|
||||||
_backView.layer.shadowColor = UIColorFromRGB(0xE4E4E4).CGColor;
|
|
||||||
_backView.layer.shadowOffset = CGSizeMake(0, 2);
|
}
|
||||||
_backView.layer.shadowRadius = 8;
|
return _backView;
|
||||||
}
|
|
||||||
return _backView;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (UILabel *)titleLabel {
|
- (UILabel *)titleLabel {
|
||||||
if (!_titleLabel) {
|
if (!_titleLabel) {
|
||||||
_titleLabel = [[UILabel alloc] init];
|
_titleLabel = [[UILabel alloc] init];
|
||||||
_titleLabel.text = YMLocalizedString(@"XPMineDataClanTableViewCell3");
|
_titleLabel.text = YMLocalizedString(@"XPMineDataClanTableViewCell6");
|
||||||
_titleLabel.font = [UIFont systemFontOfSize:14 weight:UIFontWeightMedium];
|
_titleLabel.font = kFontMedium(15);
|
||||||
_titleLabel.textColor = [DJDKMIMOMColor mainTextColor];
|
_titleLabel.textColor = UIColorFromRGB(0x1F1A4E);
|
||||||
}
|
}
|
||||||
return _titleLabel;
|
return _titleLabel;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (UIStackView *)stackView {
|
-(UILabel *)starView{
|
||||||
if (!_stackView) {
|
if (!_starView){
|
||||||
_stackView = [[UIStackView alloc] init];
|
_starView = [UILabel labelInitWithText:YMLocalizedString(@"XPMineDataClanTableViewCell7") font:kFontRegular(12) textColor:[DJDKMIMOMColor inputTextColor]];
|
||||||
_stackView.axis = UILayoutConstraintAxisVertical;
|
}
|
||||||
_stackView.distribution = UIStackViewDistributionFill;
|
return _starView;
|
||||||
_stackView.alignment = UIStackViewAlignmentFill;
|
|
||||||
_stackView.spacing = 0;
|
|
||||||
}
|
|
||||||
return _stackView;
|
|
||||||
}
|
}
|
||||||
|
-(UIImageView *)starIconView{
|
||||||
- (UIView *)clanView {
|
if (!_starIconView){
|
||||||
if (!_clanView) {
|
_starIconView = [[UIImageView alloc]init];
|
||||||
_clanView = [[UIView alloc] init];
|
UIImage *image = [UIImage gradientColorImageFromColors:@[UIColorFromRGB(0xA486FF),UIColorFromRGB(0xD3ACFE)] gradientType:GradientTypeLeftToRight imgSize:CGSizeMake(kGetScaleWidth(38), kGetScaleWidth(13))];
|
||||||
_clanView.backgroundColor = [UIColor clearColor];
|
_starIconView.layer.cornerRadius = kGetScaleWidth(6.5);
|
||||||
}
|
_starIconView.layer.masksToBounds = YES;
|
||||||
return _clanView;
|
_starIconView.image = image;
|
||||||
|
_starIconView.hidden = YES;
|
||||||
|
}
|
||||||
|
return _starIconView;
|
||||||
}
|
}
|
||||||
|
-(UILabel *)starTitleView{
|
||||||
- (NetImageView *)clanImageView {
|
if (!_starTitleView){
|
||||||
if (!_clanImageView) {
|
_starTitleView = [UILabel labelInitWithText:@"" font:kFontRegular(8.5) textColor:[UIColor whiteColor]];
|
||||||
NetImageConfig * config = [[NetImageConfig alloc]init];
|
_starTitleView.textAlignment = NSTextAlignmentCenter;
|
||||||
config.imageType = ImageTypeUserIcon;
|
}
|
||||||
config.placeHolder = [UIImageConstant defaultAvatarPlaceholder];
|
return _starTitleView;
|
||||||
_clanImageView = [[NetImageView alloc] initWithConfig:config];
|
|
||||||
_clanImageView.layer.masksToBounds = YES;
|
|
||||||
_clanImageView.layer.cornerRadius = 8;
|
|
||||||
_clanImageView.userInteractionEnabled = YES;
|
|
||||||
UITapGestureRecognizer * tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(didTapClanView)];
|
|
||||||
[_clanImageView addGestureRecognizer:tap];
|
|
||||||
}
|
|
||||||
return _clanImageView;
|
|
||||||
}
|
}
|
||||||
|
- (UILabel *)birthdayHeadView{
|
||||||
- (UILabel *)clanNickLabel {
|
if (!_birthdayHeadView){
|
||||||
if (!_clanNickLabel) {
|
_birthdayHeadView = [UILabel labelInitWithText:YMLocalizedString(@"XPMineDataClanTableViewCell8") font:kFontRegular(12) textColor:[DJDKMIMOMColor inputTextColor]];
|
||||||
_clanNickLabel = [[UILabel alloc] init];
|
}
|
||||||
_clanNickLabel.font = [UIFont systemFontOfSize:14 weight:UIFontWeightMedium];
|
return _birthdayHeadView;
|
||||||
_clanNickLabel.textColor = [DJDKMIMOMColor mainTextColor];
|
|
||||||
}
|
|
||||||
return _clanNickLabel;
|
|
||||||
}
|
}
|
||||||
|
- (UILabel *)birthdayView{
|
||||||
|
if (!_birthdayView){
|
||||||
- (UIButton *)foldButton {
|
_birthdayView = [UILabel labelInitWithText:@"" font:kFontRegular(12) textColor:[DJDKMIMOMColor inputTextColor]];
|
||||||
if (!_foldButton) {
|
}
|
||||||
_foldButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
return _birthdayView;
|
||||||
[_foldButton setImage:[UIImage imageNamed:@"room_setting_arrow"] forState:UIControlStateNormal];
|
|
||||||
[_foldButton setImage:[UIImage imageNamed:@"room_setting_arrow"] forState:UIControlStateSelected];
|
|
||||||
[_foldButton addTarget:self action:@selector(foldButtonAction:) forControlEvents:UIControlEventTouchUpInside];
|
|
||||||
_foldButton.transform = CGAffineTransformMakeRotation(M_PI / 2);
|
|
||||||
_foldButton.hidden = YES;
|
|
||||||
[_foldButton setEnlargeEdgeWithTop:10 right:10 bottom:10 left:10];
|
|
||||||
}
|
|
||||||
return _foldButton;
|
|
||||||
}
|
}
|
||||||
|
-(UILabel *)areaHeadView{
|
||||||
- (UIView *)lineView {
|
if (!_areaHeadView){
|
||||||
if (!_lineView) {
|
_areaHeadView = [UILabel labelInitWithText:YMLocalizedString(@"XPMineDataClanTableViewCell13") font:kFontRegular(12) textColor:[DJDKMIMOMColor inputTextColor]];
|
||||||
_lineView = [[UIView alloc] init];
|
}
|
||||||
_lineView.backgroundColor = [UIColor clearColor];
|
return _areaHeadView;
|
||||||
}
|
|
||||||
return _lineView;
|
|
||||||
}
|
}
|
||||||
|
-(UILabel *)areaView{
|
||||||
- (UIView *)hallView {
|
if (!_areaView){
|
||||||
if (!_hallView) {
|
_areaView = [UILabel labelInitWithText:@"" font:kFontRegular(12) textColor:[DJDKMIMOMColor inputTextColor]];
|
||||||
_hallView = [[UIView alloc] init];
|
}
|
||||||
_hallView.backgroundColor = [UIColor clearColor];
|
return _areaView;
|
||||||
_hallView.hidden = NO;
|
|
||||||
}
|
|
||||||
return _hallView;
|
|
||||||
}
|
}
|
||||||
|
-(UIButton *)areaMornBnt{
|
||||||
- (NetImageView *)hallImageView {
|
if (!_areaMornBnt){
|
||||||
if (!_hallImageView) {
|
_areaMornBnt = [UIButton new];
|
||||||
NetImageConfig * config = [[NetImageConfig alloc]init];
|
[_areaMornBnt setTitle:YMLocalizedString(@"XPMineDataClanTableViewCell14") forState:UIControlStateNormal];
|
||||||
config.imageType = ImageTypeUserIcon;
|
[_areaMornBnt setTitleColor:UIColorFromRGB(0xFFBC51) forState:UIControlStateNormal];
|
||||||
config.placeHolder = [UIImageConstant defaultAvatarPlaceholder];
|
_areaMornBnt.titleLabel.font = kFontRegular(11);
|
||||||
_hallImageView = [[NetImageView alloc] initWithConfig:config];
|
[_areaMornBnt addTarget:self action:@selector(didTapAreaView) forControlEvents:UIControlEventTouchUpInside];
|
||||||
_hallImageView.layer.masksToBounds = YES;
|
}
|
||||||
_hallImageView.layer.cornerRadius = 8;
|
return _areaMornBnt;
|
||||||
_hallImageView.userInteractionEnabled = YES;
|
|
||||||
UITapGestureRecognizer * tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(didTapHallView)];
|
|
||||||
[_hallImageView addGestureRecognizer:tap];
|
|
||||||
}
|
|
||||||
return _hallImageView;
|
|
||||||
}
|
}
|
||||||
|
-(UIButton *)areaIconView{
|
||||||
- (UILabel *)hallNickLabel {
|
if (!_areaIconView){
|
||||||
if (!_hallNickLabel) {
|
_areaIconView = [UIButton new];
|
||||||
_hallNickLabel = [[UILabel alloc] init];
|
[_areaIconView setEnlargeEdgeWithTop:10 right:10 bottom:10 left:10];
|
||||||
_hallNickLabel.font = [UIFont systemFontOfSize:12 weight:UIFontWeightMedium];
|
[_areaIconView addTarget:self action:@selector(didTapAreaView) forControlEvents:UIControlEventTouchUpInside];
|
||||||
_hallNickLabel.textColor = [DJDKMIMOMColor mainTextColor];
|
[_areaIconView setBackgroundImage:kImage(@"mine_clan_arrow") forState:UIControlStateNormal];
|
||||||
}
|
}
|
||||||
return _hallNickLabel;
|
return _areaIconView;
|
||||||
}
|
}
|
||||||
|
-(UILabel *)roomHeadView{
|
||||||
- (UIButton *)enterButton {
|
if (!_roomHeadView){
|
||||||
if (!_enterButton) {
|
_roomHeadView = [UILabel labelInitWithText:YMLocalizedString(@"XPMineDataClanTableViewCell9") font:kFontRegular(12) textColor:[DJDKMIMOMColor inputTextColor]];
|
||||||
_enterButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
_roomHeadView.hidden = YES;
|
||||||
[_enterButton setTitle:YMLocalizedString(@"XPMineDataClanTableViewCell4") forState:UIControlStateNormal];
|
|
||||||
[_enterButton setTitleColor:UIColorFromRGB(0xFFC000) forState:UIControlStateNormal];
|
}
|
||||||
_enterButton.titleLabel.font = [UIFont systemFontOfSize:10];
|
return _roomHeadView;
|
||||||
_enterButton.backgroundColor = UIColorRGBAlpha(0xFFC000, 0.2);
|
}
|
||||||
_enterButton.layer.masksToBounds = YES;
|
- (UILabel *)roomView{
|
||||||
_enterButton.layer.cornerRadius = 10;
|
if (!_roomView){
|
||||||
[_enterButton addTarget:self action:@selector(enterButtonAction:) forControlEvents:UIControlEventTouchUpInside];
|
_roomView = [UILabel labelInitWithText:@"" font:kFontRegular(12) textColor:UIColorFromRGB(0xFFBC51)];
|
||||||
}
|
_roomView.userInteractionEnabled = YES;
|
||||||
return _enterButton;
|
UITapGestureRecognizer * tap = [[UITapGestureRecognizer alloc]initWithTarget:self action:@selector(didTapHallView)];
|
||||||
|
[_roomView addGestureRecognizer:tap];
|
||||||
|
_roomView.hidden = YES;
|
||||||
|
}
|
||||||
|
return _roomView;
|
||||||
|
}
|
||||||
|
-(UIButton *)roomIconView{
|
||||||
|
if (!_roomIconView){
|
||||||
|
_roomIconView = [UIButton new];
|
||||||
|
[_roomIconView setEnlargeEdgeWithTop:10 right:10 bottom:10 left:10];
|
||||||
|
[_roomIconView addTarget:self action:@selector(didTapHallView) forControlEvents:UIControlEventTouchUpInside];
|
||||||
|
[_roomIconView setBackgroundImage:kImage(@"mine_clan_arrow") forState:UIControlStateNormal];
|
||||||
|
_roomIconView.hidden = YES;
|
||||||
|
}
|
||||||
|
return _roomIconView;
|
||||||
|
}
|
||||||
|
- (UILabel *)clanHeadView{
|
||||||
|
if (!_clanHeadView){
|
||||||
|
_clanHeadView = [UILabel labelInitWithText:YMLocalizedString(@"XPMineDataClanTableViewCell10") font:kFontRegular(12) textColor:[DJDKMIMOMColor inputTextColor]];
|
||||||
|
_clanHeadView.hidden = YES;
|
||||||
|
}
|
||||||
|
return _clanHeadView;
|
||||||
|
}
|
||||||
|
-(UILabel *)clanView{
|
||||||
|
if (!_clanView){
|
||||||
|
|
||||||
|
_clanView = [UILabel labelInitWithText:@"" font:kFontRegular(12) textColor:UIColorFromRGB(0xFFBC51)];
|
||||||
|
_clanView.userInteractionEnabled = YES;
|
||||||
|
UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc]initWithTarget:self action:@selector(didTapClanView)];
|
||||||
|
[_clanView addGestureRecognizer:tap];
|
||||||
|
_clanView.hidden = YES;
|
||||||
|
}
|
||||||
|
return _clanView;
|
||||||
|
}
|
||||||
|
-(UIButton *)clanIconView{
|
||||||
|
if (!_clanIconView){
|
||||||
|
_clanIconView = [UIButton new];
|
||||||
|
[_clanIconView setEnlargeEdgeWithTop:10 right:10 bottom:10 left:10];
|
||||||
|
[_clanIconView addTarget:self action:@selector(didTapClanView) forControlEvents:UIControlEventTouchUpInside];
|
||||||
|
[_clanIconView setBackgroundImage:kImage(@"mine_clan_arrow") forState:UIControlStateNormal];
|
||||||
|
_clanIconView.hidden = YES;
|
||||||
|
}
|
||||||
|
return _clanIconView;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
@@ -30,7 +30,7 @@
|
|||||||
///分页控件
|
///分页控件
|
||||||
@property (nonatomic, strong) JXCategoryTitleView *titleView;
|
@property (nonatomic, strong) JXCategoryTitleView *titleView;
|
||||||
///分页lineView
|
///分页lineView
|
||||||
@property (nonatomic, strong) JXCategoryListContainerView *containerView;
|
@property (nonatomic, strong) JXCategoryListContainerView *pi_containerView;
|
||||||
///普通礼物
|
///普通礼物
|
||||||
@property (nonatomic,strong) XPMineUserInfoGiftView *normalGiftView;
|
@property (nonatomic,strong) XPMineUserInfoGiftView *normalGiftView;
|
||||||
///幸运礼物
|
///幸运礼物
|
||||||
@@ -56,7 +56,7 @@
|
|||||||
// [self.backImageView addSubview:self.titleLabel];
|
// [self.backImageView addSubview:self.titleLabel];
|
||||||
[self.backImageView addSubview:self.arrowButton];
|
[self.backImageView addSubview:self.arrowButton];
|
||||||
[self.backImageView addSubview:self.titleView];
|
[self.backImageView addSubview:self.titleView];
|
||||||
[self.backImageView addSubview:self.containerView];
|
[self.backImageView addSubview:self.pi_containerView];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)initSubViewConstraints {
|
- (void)initSubViewConstraints {
|
||||||
@@ -84,7 +84,7 @@
|
|||||||
make.top.mas_equalTo(kGetScaleWidth(14));
|
make.top.mas_equalTo(kGetScaleWidth(14));
|
||||||
}];
|
}];
|
||||||
|
|
||||||
[self.containerView mas_makeConstraints:^(MASConstraintMaker *make) {
|
[self.pi_containerView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.left.right.bottom.mas_equalTo(self.backImageView);
|
make.left.right.bottom.mas_equalTo(self.backImageView);
|
||||||
make.top.mas_equalTo(self.titleView.mas_bottom).offset(kGetScaleWidth(20));
|
make.top.mas_equalTo(self.titleView.mas_bottom).offset(kGetScaleWidth(20));
|
||||||
}];
|
}];
|
||||||
@@ -181,7 +181,7 @@
|
|||||||
_titleView.cellSpacing = 20;
|
_titleView.cellSpacing = 20;
|
||||||
_titleView.cellWidthIncrement = 5;
|
_titleView.cellWidthIncrement = 5;
|
||||||
_titleView.cellWidth = 60;
|
_titleView.cellWidth = 60;
|
||||||
_titleView.listContainer = self.containerView;
|
_titleView.listContainer = self.pi_containerView;
|
||||||
|
|
||||||
JXCategoryIndicatorImageView *lineView = [[JXCategoryIndicatorImageView alloc] init];
|
JXCategoryIndicatorImageView *lineView = [[JXCategoryIndicatorImageView alloc] init];
|
||||||
lineView.indicatorImageViewSize = CGSizeMake(15, 3);
|
lineView.indicatorImageViewSize = CGSizeMake(15, 3);
|
||||||
@@ -194,13 +194,13 @@
|
|||||||
return _titleView;
|
return _titleView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (JXCategoryListContainerView *)containerView {
|
- (JXCategoryListContainerView *)pi_containerView {
|
||||||
if (!_containerView) {
|
if (!_pi_containerView) {
|
||||||
_containerView = [[JXCategoryListContainerView alloc] initWithType:JXCategoryListContainerType_ScrollView delegate:self];
|
_pi_containerView = [[JXCategoryListContainerView alloc] initWithType:JXCategoryListContainerType_ScrollView delegate:self];
|
||||||
_containerView.defaultSelectedIndex = 0;
|
_pi_containerView.defaultSelectedIndex = 0;
|
||||||
_containerView.scrollView.tag = 1009;
|
_pi_containerView.scrollView.tag = 1009;
|
||||||
}
|
}
|
||||||
return _containerView;
|
return _pi_containerView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (NSArray<NSString *> *)titles {
|
- (NSArray<NSString *> *)titles {
|
||||||
|
@@ -1,8 +1,8 @@
|
|||||||
//
|
//
|
||||||
// YMMineUserInfoGiftWallCollectionViewCell.h
|
// XPMineUserInfoGiftWallCollectionViewCell.h
|
||||||
// YUMI
|
// xplan-ios
|
||||||
//
|
//
|
||||||
// Created by YUMI on 2022/4/14.
|
// Created by 冯硕 on 2022/4/14.
|
||||||
//
|
//
|
||||||
|
|
||||||
#import <UIKit/UIKit.h>
|
#import <UIKit/UIKit.h>
|
||||||
@@ -11,6 +11,7 @@ NS_ASSUME_NONNULL_BEGIN
|
|||||||
@class UserGiftWallInfoModel;
|
@class UserGiftWallInfoModel;
|
||||||
@interface XPMineUserInfoGiftWallCollectionViewCell : UICollectionViewCell
|
@interface XPMineUserInfoGiftWallCollectionViewCell : UICollectionViewCell
|
||||||
@property (nonatomic,strong) UserGiftWallInfoModel *giftInfo;
|
@property (nonatomic,strong) UserGiftWallInfoModel *giftInfo;
|
||||||
|
-(void)setLevel:(int)level;
|
||||||
@end
|
@end
|
||||||
|
|
||||||
NS_ASSUME_NONNULL_END
|
NS_ASSUME_NONNULL_END
|
||||||
|
@@ -1,158 +1,160 @@
|
|||||||
//
|
//
|
||||||
// YMMineUserInfoGiftWallCollectionViewCell.m
|
// XPMineUserInfoGiftWallCollectionViewCell.m
|
||||||
// YUMI
|
// xplan-ios
|
||||||
//
|
//
|
||||||
// Created by YUMI on 2022/4/14.
|
// Created by 冯硕 on 2022/4/14.
|
||||||
//
|
//
|
||||||
|
|
||||||
#import "XPMineUserInfoGiftWallCollectionViewCell.h"
|
#import "XPMineUserInfoGiftWallCollectionViewCell.h"
|
||||||
///Third
|
///Third
|
||||||
#import <Masonry/Masonry.h>
|
#import <Masonry/Masonry.h>
|
||||||
///Tool
|
///Tool
|
||||||
#import "DJDKMIMOMColor.h"
|
|
||||||
#import "NetImageView.h"
|
#import "NetImageView.h"
|
||||||
#import "UIView+Corner.h"
|
#import "UIView+Corner.h"
|
||||||
///Model
|
///Model
|
||||||
#import "UserGiftWallInfoModel.h"
|
#import "UserGiftWallInfoModel.h"
|
||||||
|
|
||||||
@interface XPMineUserInfoGiftWallCollectionViewCell ()
|
@interface XPMineUserInfoGiftWallCollectionViewCell ()
|
||||||
///礼物的图片
|
///背景
|
||||||
|
@property (nonatomic,strong) UIView *bgView;
|
||||||
|
///排名
|
||||||
|
@property (nonatomic,strong) UIImageView *levelImageView;
|
||||||
|
|
||||||
|
///礼物头像
|
||||||
@property (nonatomic,strong) NetImageView *giftImageView;
|
@property (nonatomic,strong) NetImageView *giftImageView;
|
||||||
///礼物的数量
|
///礼物个数
|
||||||
@property (nonatomic,strong) UIButton *numberButton;
|
@property (nonatomic,strong) UILabel *giftNumberLabel;
|
||||||
///礼物的名
|
|
||||||
@property (nonatomic,strong) UILabel *giftNameLabel;
|
@property (nonatomic,strong) UILabel *priceView;
|
||||||
///礼物的价值容器
|
|
||||||
@property (nonatomic,strong) UIStackView *stackView;
|
|
||||||
///钻石
|
|
||||||
@property (nonatomic,strong) UIImageView *diamondImageView;
|
|
||||||
///价格
|
|
||||||
@property (nonatomic,strong) UILabel *giftPriceLabel;
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
@implementation XPMineUserInfoGiftWallCollectionViewCell
|
@implementation XPMineUserInfoGiftWallCollectionViewCell
|
||||||
|
|
||||||
- (instancetype)initWithFrame:(CGRect)frame {
|
- (instancetype)initWithFrame:(CGRect)frame {
|
||||||
self = [super initWithFrame:frame];
|
self = [super initWithFrame:frame];
|
||||||
if (self) {
|
if (self) {
|
||||||
[self initSubViews];
|
[self initSubViews];
|
||||||
[self initSubViewConstraints];
|
[self initSubViewConstraints];
|
||||||
}
|
}
|
||||||
return self;
|
return self;
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - Private Method
|
#pragma mark - Private Method
|
||||||
|
|
||||||
- (void)initSubViews {
|
- (void)initSubViews {
|
||||||
self.backgroundColor = [UIColor clearColor];
|
self.backgroundColor = [UIColor clearColor];
|
||||||
[self.contentView addSubview:self.giftImageView];
|
[self.contentView addSubview:self.bgView];
|
||||||
[self.contentView addSubview:self.numberButton];
|
[self.bgView addSubview:self.giftImageView];
|
||||||
[self.contentView addSubview:self.giftNameLabel];
|
[self.bgView addSubview:self.priceView];
|
||||||
[self.contentView addSubview:self.stackView];
|
[self.bgView addSubview:self.giftNumberLabel];
|
||||||
|
[self.bgView addSubview:self.levelImageView];
|
||||||
[self.stackView addArrangedSubview:self.diamondImageView];
|
|
||||||
[self.stackView addArrangedSubview:self.giftPriceLabel];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)initSubViewConstraints {
|
- (void)initSubViewConstraints {
|
||||||
[self.giftImageView mas_makeConstraints:^(MASConstraintMaker *make) {
|
[self.bgView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.left.right.mas_equalTo(self.contentView).inset(5);
|
make.edges.equalTo(self.contentView);
|
||||||
make.top.mas_equalTo(self.contentView);
|
}];
|
||||||
make.height.mas_equalTo(self.giftImageView.mas_width);
|
|
||||||
}];
|
|
||||||
|
[self.giftImageView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
[self.numberButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
make.size.mas_equalTo(CGSizeMake(kGetScaleWidth(60.16), kGetScaleWidth(55.58)));
|
||||||
make.size.mas_equalTo(CGSizeMake(55, 15));
|
make.centerX.mas_equalTo(self.contentView);
|
||||||
make.centerX.mas_equalTo(self.contentView);
|
make.top.mas_equalTo(kGetScaleWidth(5));
|
||||||
make.top.mas_equalTo(self.giftImageView.mas_bottom).offset(2);
|
}];
|
||||||
}];
|
|
||||||
|
[self.giftNumberLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
[self.giftNameLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
make.centerX.mas_equalTo(self.contentView);
|
||||||
make.left.right.mas_equalTo(self.contentView);
|
make.top.mas_equalTo(self.giftImageView.mas_bottom).offset(kGetScaleWidth(5));
|
||||||
make.top.mas_equalTo(self.numberButton.mas_bottom).offset(10);
|
make.height.mas_equalTo(kGetScaleWidth(14));
|
||||||
}];
|
}];
|
||||||
|
[self.priceView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
[self.stackView mas_makeConstraints:^(MASConstraintMaker *make) {
|
make.centerX.equalTo(self.bgView);
|
||||||
make.centerX.mas_equalTo(self.contentView);
|
make.top.equalTo(self.giftNumberLabel.mas_bottom).mas_offset(kGetScaleWidth(5));
|
||||||
make.top.mas_equalTo(self.giftNameLabel.mas_bottom).offset(3);
|
make.left.right.equalTo(self.bgView).inset(kGetScaleWidth(0));
|
||||||
}];
|
}];
|
||||||
|
[self.levelImageView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
[self.diamondImageView mas_makeConstraints:^(MASConstraintMaker *make) {
|
make.left.top.mas_equalTo(kGetScaleWidth(3));
|
||||||
make.size.mas_equalTo(CGSizeMake(13, 13));
|
make.width.height.mas_equalTo(kGetScaleWidth(19));
|
||||||
}];
|
}];
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - Getters And Setters
|
#pragma mark - Getters And Setters
|
||||||
|
|
||||||
|
-(void)setLevel:(int)level{
|
||||||
|
self.levelImageView.hidden = YES;
|
||||||
|
if(level == 1){
|
||||||
|
self.levelImageView.hidden = NO;
|
||||||
|
_levelImageView.image = [UIImage imageNamed:@"gift_list_one"];
|
||||||
|
}else if(level == 2){
|
||||||
|
self.levelImageView.hidden = NO;
|
||||||
|
_levelImageView.image = [UIImage imageNamed:@"gift_list_two"];
|
||||||
|
}else if(level == 3){
|
||||||
|
self.levelImageView.hidden = NO;
|
||||||
|
_levelImageView.image = [UIImage imageNamed:@"gift_list_three"];
|
||||||
|
}else{
|
||||||
|
self.levelImageView.hidden = YES;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
- (void)setGiftInfo:(UserGiftWallInfoModel *)giftInfo {
|
- (void)setGiftInfo:(UserGiftWallInfoModel *)giftInfo {
|
||||||
_giftInfo = giftInfo;
|
_giftInfo = giftInfo;
|
||||||
if (_giftInfo) {
|
if (_giftInfo) {
|
||||||
self.giftImageView.imageUrl = _giftInfo.picUrl;
|
_giftImageView.imageUrl = _giftInfo.picUrl;
|
||||||
self.giftNameLabel.text = _giftInfo.giftName;
|
_giftNumberLabel.text = [NSString stringWithFormat:@"X%ld", _giftInfo.reciveCount];
|
||||||
self.giftPriceLabel.text = [NSString stringWithFormat:@"%ld", _giftInfo.giftPrice];
|
NSMutableAttributedString *textAtt = [[NSMutableAttributedString alloc]initWithString:[NSString stringWithFormat:@" %ld",_giftInfo.giftPrice] attributes:@{NSForegroundColorAttributeName:UIColorFromRGB(0x6D6B89)}];
|
||||||
[self.numberButton setTitle:[NSString stringWithFormat:@"X%ld", _giftInfo.reciveCount] forState:UIControlStateNormal];
|
NSTextAttachment * attachment = [[NSTextAttachment alloc] init];
|
||||||
}
|
UIImage *iconImage = [UIImage imageNamed:@"exchange_diamonds_icon"];;
|
||||||
|
attachment.bounds = CGRectMake(0, roundf(_priceView.font.capHeight - iconImage.size.height)/2.f, iconImage.size.width, iconImage.size.height);
|
||||||
|
attachment.image = iconImage;
|
||||||
|
[textAtt insertAttributedString:[NSMutableAttributedString attributedStringWithAttachment:attachment] atIndex:0];
|
||||||
|
_priceView.attributedText = textAtt;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
- (NetImageView *)giftImageView {
|
- (NetImageView *)giftImageView {
|
||||||
if (!_giftImageView) {
|
if (!_giftImageView) {
|
||||||
NetImageConfig * config = [[NetImageConfig alloc]init];
|
NetImageConfig * config = [[NetImageConfig alloc]init];
|
||||||
config.imageType = ImageTypeUserIcon;
|
config.imageType = ImageTypeUserIcon;
|
||||||
config.placeHolder = [UIImageConstant defaultAvatarPlaceholder];
|
config.placeHolder = [UIImageConstant defaultAvatarPlaceholder];
|
||||||
_giftImageView = [[NetImageView alloc] initWithConfig:config];
|
_giftImageView = [[NetImageView alloc] initWithConfig:config];
|
||||||
_giftImageView.contentMode = UIViewContentModeScaleAspectFill;
|
}
|
||||||
_giftImageView.layer.masksToBounds = YES;
|
return _giftImageView;
|
||||||
}
|
|
||||||
return _giftImageView;
|
|
||||||
}
|
|
||||||
|
|
||||||
- (UIButton *)numberButton {
|
|
||||||
if (!_numberButton) {
|
|
||||||
_numberButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
|
||||||
[_numberButton setBackgroundColor:[DJDKMIMOMColor appCellBackgroundColor]];
|
|
||||||
[_numberButton setTitleColor:[DJDKMIMOMColor mainTextColor] forState:UIControlStateNormal];
|
|
||||||
_numberButton.titleLabel.font = [UIFont systemFontOfSize:10];
|
|
||||||
_numberButton.layer.masksToBounds = YES;
|
|
||||||
[_numberButton setCornerWithLeftTopCorner:2 rightTopCorner:6 bottomLeftCorner:6 bottomRightCorner:2 size:CGSizeMake(55, 15)];
|
|
||||||
}
|
|
||||||
return _numberButton;
|
|
||||||
}
|
|
||||||
|
|
||||||
- (UILabel *)giftNameLabel {
|
|
||||||
if (!_giftNameLabel) {
|
|
||||||
_giftNameLabel = [[UILabel alloc] init];
|
|
||||||
_giftNameLabel.font = [UIFont systemFontOfSize:13];
|
|
||||||
_giftNameLabel.textColor = [DJDKMIMOMColor mainTextColor];
|
|
||||||
_giftNameLabel.textAlignment = NSTextAlignmentCenter;
|
|
||||||
}
|
|
||||||
return _giftNameLabel;
|
|
||||||
}
|
|
||||||
|
|
||||||
- (UIStackView *)stackView {
|
|
||||||
if (!_stackView) {
|
|
||||||
_stackView = [[UIStackView alloc] init];
|
|
||||||
_stackView.axis = UILayoutConstraintAxisHorizontal;
|
|
||||||
_stackView.distribution = UIStackViewDistributionFill;
|
|
||||||
_stackView.alignment = UIStackViewAlignmentFill;
|
|
||||||
_stackView.spacing = 3;
|
|
||||||
}
|
|
||||||
return _stackView;
|
|
||||||
}
|
|
||||||
|
|
||||||
- (UIImageView *)diamondImageView {
|
|
||||||
if (!_diamondImageView) {
|
|
||||||
_diamondImageView = [[UIImageView alloc] init];
|
|
||||||
_diamondImageView.userInteractionEnabled = YES;
|
|
||||||
_diamondImageView.image = [UIImage imageNamed:@"common_diamond"];
|
|
||||||
}
|
|
||||||
return _diamondImageView;
|
|
||||||
}
|
|
||||||
|
|
||||||
- (UILabel *)giftPriceLabel {
|
|
||||||
if (!_giftPriceLabel) {
|
|
||||||
_giftPriceLabel = [[UILabel alloc] init];
|
|
||||||
_giftPriceLabel.font = [UIFont systemFontOfSize:11];
|
|
||||||
_giftPriceLabel.textColor = [DJDKMIMOMColor secondTextColor];
|
|
||||||
}
|
|
||||||
return _giftPriceLabel;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
- (UILabel *)giftNumberLabel {
|
||||||
|
if (!_giftNumberLabel) {
|
||||||
|
_giftNumberLabel = [[UILabel alloc] init];
|
||||||
|
_giftNumberLabel.font = [UIFont systemFontOfSize:kGetScaleWidth(10) weight:UIFontWeightRegular];
|
||||||
|
_giftNumberLabel.textColor = UIColorFromRGB(0x6D6B89);
|
||||||
|
_giftNumberLabel.textAlignment = NSTextAlignmentCenter;
|
||||||
|
|
||||||
|
}
|
||||||
|
return _giftNumberLabel;
|
||||||
|
}
|
||||||
|
|
||||||
|
- (UIView *)bgView{
|
||||||
|
if (!_bgView){
|
||||||
|
_bgView = [UIView new];
|
||||||
|
_bgView.backgroundColor = UIColorFromRGB(0xF3F5FA);
|
||||||
|
_bgView.layer.cornerRadius = kGetScaleWidth(8);
|
||||||
|
_bgView.layer.masksToBounds = YES;
|
||||||
|
}
|
||||||
|
return _bgView;
|
||||||
|
}
|
||||||
|
- (UIImageView *)levelImageView{
|
||||||
|
if (!_levelImageView){
|
||||||
|
_levelImageView = [UIImageView new];
|
||||||
|
_levelImageView.hidden = NO;
|
||||||
|
}
|
||||||
|
return _levelImageView;
|
||||||
|
}
|
||||||
|
- (UILabel *)priceView{
|
||||||
|
if (!_priceView){
|
||||||
|
_priceView = [UILabel new];
|
||||||
|
_priceView.textAlignment = NSTextAlignmentCenter;
|
||||||
|
_priceView.font = [UIFont systemFontOfSize:kGetScaleWidth(10) weight:UIFontWeightRegular];
|
||||||
|
}
|
||||||
|
return _priceView;
|
||||||
|
}
|
||||||
@end
|
@end
|
||||||
|
@@ -1,17 +0,0 @@
|
|||||||
//
|
|
||||||
// YMMineInfoTableViewCell.h
|
|
||||||
// YUMI
|
|
||||||
//
|
|
||||||
// Created by YUMI on 2021/9/23.
|
|
||||||
//
|
|
||||||
|
|
||||||
#import <UIKit/UIKit.h>
|
|
||||||
|
|
||||||
NS_ASSUME_NONNULL_BEGIN
|
|
||||||
@class UserInfoModel;
|
|
||||||
@interface XPMineUserInfoTableViewCell : UITableViewCell
|
|
||||||
///用户信息
|
|
||||||
@property (nonatomic,strong) UserInfoModel *userInfo;
|
|
||||||
@end
|
|
||||||
|
|
||||||
NS_ASSUME_NONNULL_END
|
|
@@ -1,167 +0,0 @@
|
|||||||
//
|
|
||||||
// YMMineInfoTableViewCell.m
|
|
||||||
// YUMI
|
|
||||||
//
|
|
||||||
// Created by YUMI on 2021/9/23.
|
|
||||||
//
|
|
||||||
|
|
||||||
#import "XPMineUserInfoTableViewCell.h"
|
|
||||||
///Third
|
|
||||||
#import <Masonry/Masonry.h>
|
|
||||||
///Tool
|
|
||||||
#import "DJDKMIMOMColor.h"
|
|
||||||
///Model
|
|
||||||
#import "UserInfoModel.h"
|
|
||||||
|
|
||||||
@interface XPMineUserInfoTableViewCell ()
|
|
||||||
///背景
|
|
||||||
@property (nonatomic,strong) UIView * backView;
|
|
||||||
///名字
|
|
||||||
@property (nonatomic,strong) UILabel *nameLabel;
|
|
||||||
///sex
|
|
||||||
@property (nonatomic,strong) UIImageView *sexImageView;
|
|
||||||
///id
|
|
||||||
@property (nonatomic,strong) UILabel *idLabel;
|
|
||||||
///签名
|
|
||||||
@property (nonatomic,strong) UILabel *signLabel;
|
|
||||||
///正在直播中
|
|
||||||
@property (nonatomic,strong) UIButton *onlineButton;
|
|
||||||
@end
|
|
||||||
|
|
||||||
@implementation XPMineUserInfoTableViewCell
|
|
||||||
|
|
||||||
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
|
|
||||||
if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
|
|
||||||
[self initSubViews];
|
|
||||||
[self initSubViewConstraints];
|
|
||||||
}
|
|
||||||
return self;
|
|
||||||
}
|
|
||||||
|
|
||||||
#pragma mark - Private Method
|
|
||||||
- (void)initSubViews {
|
|
||||||
self.backgroundColor = [UIColor clearColor];
|
|
||||||
self.selectionStyle = UITableViewCellSelectionStyleNone;
|
|
||||||
[self.contentView addSubview:self.backView];
|
|
||||||
|
|
||||||
[self.backView addSubview:self.nameLabel];
|
|
||||||
[self.backView addSubview:self.sexImageView];
|
|
||||||
[self.backView addSubview:self.idLabel];
|
|
||||||
[self.backView addSubview:self.signLabel];
|
|
||||||
[self.backView addSubview:self.onlineButton];
|
|
||||||
}
|
|
||||||
|
|
||||||
- (void)initSubViewConstraints {
|
|
||||||
[self.backView mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.left.right.mas_equalTo(self.contentView).inset(15);
|
|
||||||
make.top.bottom.mas_equalTo(self.contentView);
|
|
||||||
}];
|
|
||||||
|
|
||||||
[self.nameLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.left.mas_equalTo(self.backView).offset(15);
|
|
||||||
make.top.mas_equalTo(self.backView).offset(15);
|
|
||||||
}];
|
|
||||||
|
|
||||||
[self.sexImageView mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.left.mas_equalTo(self.nameLabel.mas_right).offset(5);
|
|
||||||
make.centerY.mas_equalTo(self.nameLabel);
|
|
||||||
}];
|
|
||||||
|
|
||||||
[self.idLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.left.mas_equalTo(self.nameLabel);
|
|
||||||
make.top.mas_equalTo(self.nameLabel.mas_bottom).offset(10);
|
|
||||||
}];
|
|
||||||
|
|
||||||
[self.signLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.left.mas_equalTo(self.nameLabel);
|
|
||||||
make.top.mas_equalTo(self.idLabel.mas_bottom).offset(18);
|
|
||||||
}];
|
|
||||||
|
|
||||||
[self.onlineButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.size.mas_equalTo(CGSizeMake(55, 18));
|
|
||||||
make.right.mas_equalTo(self.backView).offset(-15);
|
|
||||||
make.top.mas_equalTo(self.backView).offset(10);
|
|
||||||
}];
|
|
||||||
}
|
|
||||||
|
|
||||||
#pragma mark - Getters And Setters
|
|
||||||
- (void)setUserInfo:(UserInfoModel *)userInfo {
|
|
||||||
_userInfo = userInfo;
|
|
||||||
if (_userInfo) {
|
|
||||||
self.nameLabel.text = _userInfo.nick;
|
|
||||||
self.idLabel.text = [NSString stringWithFormat:@"%@%@:%ld",AppName,YMLocalizedString(@"App_Common_hao"), (long)_userInfo.erbanNo];
|
|
||||||
self.signLabel.text = _userInfo.userDesc.length > 0 ? _userInfo.userDesc : YMLocalizedString(@"XPMineUserInfoTableViewCell1");
|
|
||||||
NSString * sexStr;
|
|
||||||
if (_userInfo.gender == GenderType_Male) {
|
|
||||||
sexStr = @"common_male";
|
|
||||||
} else {
|
|
||||||
sexStr = @"common_female";
|
|
||||||
}
|
|
||||||
self.sexImageView.image = [UIImage imageNamed:sexStr];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
- (UIView *)backView {
|
|
||||||
if (!_backView) {
|
|
||||||
_backView = [[UIView alloc] init];
|
|
||||||
_backView.backgroundColor = [DJDKMIMOMColor appCellBackgroundColor];
|
|
||||||
_backView.layer.masksToBounds = YES;
|
|
||||||
_backView.layer.cornerRadius = 12;
|
|
||||||
}
|
|
||||||
return _backView;
|
|
||||||
}
|
|
||||||
|
|
||||||
- (UILabel *)nameLabel {
|
|
||||||
if (!_nameLabel) {
|
|
||||||
_nameLabel = [[UILabel alloc] init];
|
|
||||||
_nameLabel.font = [UIFont fontWithName:@"PingFang-SC-Medium" size:15];
|
|
||||||
_nameLabel.textColor = [DJDKMIMOMColor mainTextColor];
|
|
||||||
}
|
|
||||||
return _nameLabel;
|
|
||||||
}
|
|
||||||
|
|
||||||
- (UIImageView *)sexImageView {
|
|
||||||
if (!_sexImageView) {
|
|
||||||
_sexImageView = [[UIImageView alloc] init];
|
|
||||||
_sexImageView.userInteractionEnabled = YES;
|
|
||||||
}
|
|
||||||
return _sexImageView;
|
|
||||||
}
|
|
||||||
|
|
||||||
- (UILabel *)idLabel {
|
|
||||||
if (!_idLabel) {
|
|
||||||
_idLabel = [[UILabel alloc] init];
|
|
||||||
_idLabel.font = [UIFont systemFontOfSize:11];
|
|
||||||
_idLabel.textColor = [DJDKMIMOMColor textThirdColor];
|
|
||||||
}
|
|
||||||
return _idLabel;
|
|
||||||
}
|
|
||||||
|
|
||||||
- (UILabel *)signLabel {
|
|
||||||
if (!_signLabel) {
|
|
||||||
_signLabel = [[UILabel alloc] init];
|
|
||||||
_signLabel.font = [UIFont systemFontOfSize:11];;
|
|
||||||
_signLabel.textColor = [DJDKMIMOMColor secondTextColor];
|
|
||||||
}
|
|
||||||
return _signLabel;
|
|
||||||
}
|
|
||||||
|
|
||||||
- (UIButton *)onlineButton {
|
|
||||||
if (!_onlineButton) {
|
|
||||||
_onlineButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
|
||||||
[_onlineButton setTitle:YMLocalizedString(@"XPMineUserInfoTableViewCell2") forState:UIControlStateNormal];
|
|
||||||
[_onlineButton setImage:[UIImage imageNamed:@"home_search_user_online"] forState:UIControlStateNormal];
|
|
||||||
[_onlineButton setTitleColor:[DJDKMIMOMColor appEmphasizeColor] forState:UIControlStateNormal];
|
|
||||||
_onlineButton.backgroundColor = [UIColor clearColor];
|
|
||||||
_onlineButton.titleLabel.font = [UIFont systemFontOfSize:10];
|
|
||||||
_onlineButton.layer.masksToBounds = YES;
|
|
||||||
_onlineButton.layer.cornerRadius = 18/2;
|
|
||||||
_onlineButton.layer.borderColor = [DJDKMIMOMColor appEmphasizeColor].CGColor;
|
|
||||||
_onlineButton.layer.borderWidth = 1;
|
|
||||||
[_onlineButton addTarget:self action:@selector(onlineButtonAction:) forControlEvents:UIControlEventTouchUpInside];
|
|
||||||
}
|
|
||||||
return _onlineButton;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
@end
|
|
@@ -27,7 +27,7 @@
|
|||||||
///分页控件
|
///分页控件
|
||||||
@property (nonatomic, strong) JXCategoryTitleView *titleView;
|
@property (nonatomic, strong) JXCategoryTitleView *titleView;
|
||||||
///分页lineView
|
///分页lineView
|
||||||
@property (nonatomic, strong) JXCategoryListContainerView *containerView;
|
@property (nonatomic, strong) JXCategoryListContainerView *pi_containerView;
|
||||||
///钻石
|
///钻石
|
||||||
@property (nonatomic,strong) XPMineGiveDiamondDetailsView *diamondView;
|
@property (nonatomic,strong) XPMineGiveDiamondDetailsView *diamondView;
|
||||||
///礼物
|
///礼物
|
||||||
@@ -87,7 +87,7 @@
|
|||||||
}else{
|
}else{
|
||||||
self.type = 0;
|
self.type = 0;
|
||||||
[self.view addSubview:self.titleView];
|
[self.view addSubview:self.titleView];
|
||||||
[self.view addSubview:self.containerView];
|
[self.view addSubview:self.pi_containerView];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -107,7 +107,7 @@
|
|||||||
make.height.mas_equalTo(30);
|
make.height.mas_equalTo(30);
|
||||||
|
|
||||||
}];
|
}];
|
||||||
[self.containerView mas_makeConstraints:^(MASConstraintMaker *make) {
|
[self.pi_containerView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.left.right.bottom.mas_equalTo(self.view);
|
make.left.right.bottom.mas_equalTo(self.view);
|
||||||
make.top.mas_equalTo(self.titleView.mas_bottom).offset(10);
|
make.top.mas_equalTo(self.titleView.mas_bottom).offset(10);
|
||||||
}];
|
}];
|
||||||
@@ -285,7 +285,7 @@
|
|||||||
_titleView.cellSpacing = 20;
|
_titleView.cellSpacing = 20;
|
||||||
_titleView.cellWidthIncrement = 5;
|
_titleView.cellWidthIncrement = 5;
|
||||||
_titleView.cellWidth = 60;
|
_titleView.cellWidth = 60;
|
||||||
_titleView.listContainer = self.containerView;
|
_titleView.listContainer = self.pi_containerView;
|
||||||
|
|
||||||
JXCategoryIndicatorImageView *lineView = [[JXCategoryIndicatorImageView alloc] init];
|
JXCategoryIndicatorImageView *lineView = [[JXCategoryIndicatorImageView alloc] init];
|
||||||
lineView.indicatorImageViewSize = CGSizeMake(16, 3);
|
lineView.indicatorImageViewSize = CGSizeMake(16, 3);
|
||||||
@@ -298,14 +298,14 @@
|
|||||||
return _titleView;
|
return _titleView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (JXCategoryListContainerView *)containerView {
|
- (JXCategoryListContainerView *)pi_containerView {
|
||||||
if (!_containerView) {
|
if (!_pi_containerView) {
|
||||||
_containerView = [[JXCategoryListContainerView alloc] initWithType:JXCategoryListContainerType_ScrollView delegate:self];
|
_pi_containerView = [[JXCategoryListContainerView alloc] initWithType:JXCategoryListContainerType_ScrollView delegate:self];
|
||||||
_containerView.defaultSelectedIndex = 0;
|
_pi_containerView.defaultSelectedIndex = 0;
|
||||||
[_containerView.scrollView.panGestureRecognizer requireGestureRecognizerToFail:self.navigationController.interactivePopGestureRecognizer];
|
[_pi_containerView.scrollView.panGestureRecognizer requireGestureRecognizerToFail:self.navigationController.interactivePopGestureRecognizer];
|
||||||
|
|
||||||
}
|
}
|
||||||
return _containerView;
|
return _pi_containerView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (NSArray<NSString *> *)titles {
|
- (NSArray<NSString *> *)titles {
|
||||||
|
@@ -61,7 +61,7 @@
|
|||||||
///分页控件
|
///分页控件
|
||||||
@property (nonatomic, strong) JXCategoryTitleView *titleView;
|
@property (nonatomic, strong) JXCategoryTitleView *titleView;
|
||||||
///分页lineView
|
///分页lineView
|
||||||
@property (nonatomic, strong) JXCategoryListContainerView *containerView;
|
@property (nonatomic, strong) JXCategoryListContainerView *pi_containerView;
|
||||||
///普通礼物
|
///普通礼物
|
||||||
@property (nonatomic,strong) XPMineUserInfoGiftView *normalGiftView;
|
@property (nonatomic,strong) XPMineUserInfoGiftView *normalGiftView;
|
||||||
///幸运礼物
|
///幸运礼物
|
||||||
@@ -142,7 +142,7 @@
|
|||||||
[self.backImageView addSubview:self.giftBgView];
|
[self.backImageView addSubview:self.giftBgView];
|
||||||
[self.backImageView addSubview:self.arrowButton];
|
[self.backImageView addSubview:self.arrowButton];
|
||||||
[self.giftBgView addSubview:self.titleView];
|
[self.giftBgView addSubview:self.titleView];
|
||||||
[self.giftBgView addSubview:self.containerView];
|
[self.giftBgView addSubview:self.pi_containerView];
|
||||||
[self.backImageView addSubview:self.dynamicLabel];
|
[self.backImageView addSubview:self.dynamicLabel];
|
||||||
|
|
||||||
CGFloat itemHeight = 65;
|
CGFloat itemHeight = 65;
|
||||||
@@ -181,7 +181,7 @@
|
|||||||
make.top.mas_equalTo(0);
|
make.top.mas_equalTo(0);
|
||||||
}];
|
}];
|
||||||
|
|
||||||
[self.containerView mas_makeConstraints:^(MASConstraintMaker *make) {
|
[self.pi_containerView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.left.right.mas_equalTo(0);
|
make.left.right.mas_equalTo(0);
|
||||||
make.top.mas_equalTo(self.titleView.mas_bottom).offset(8);
|
make.top.mas_equalTo(self.titleView.mas_bottom).offset(8);
|
||||||
make.bottom.mas_equalTo(0);
|
make.bottom.mas_equalTo(0);
|
||||||
@@ -409,7 +409,7 @@
|
|||||||
_titleView.cellSpacing = 20;
|
_titleView.cellSpacing = 20;
|
||||||
_titleView.cellWidthIncrement = 5;
|
_titleView.cellWidthIncrement = 5;
|
||||||
_titleView.cellWidth = 60;
|
_titleView.cellWidth = 60;
|
||||||
_titleView.listContainer = self.containerView;
|
_titleView.listContainer = self.pi_containerView;
|
||||||
|
|
||||||
// JXCategoryIndicatorImageView *lineView = [[JXCategoryIndicatorImageView alloc] init];
|
// JXCategoryIndicatorImageView *lineView = [[JXCategoryIndicatorImageView alloc] init];
|
||||||
// lineView.indicatorImageViewSize = CGSizeMake(60, 8);
|
// lineView.indicatorImageViewSize = CGSizeMake(60, 8);
|
||||||
@@ -422,13 +422,13 @@
|
|||||||
return _titleView;
|
return _titleView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (JXCategoryListContainerView *)containerView {
|
- (JXCategoryListContainerView *)pi_containerView {
|
||||||
if (!_containerView) {
|
if (!_pi_containerView) {
|
||||||
_containerView = [[JXCategoryListContainerView alloc] initWithType:JXCategoryListContainerType_ScrollView delegate:self];
|
_pi_containerView = [[JXCategoryListContainerView alloc] initWithType:JXCategoryListContainerType_ScrollView delegate:self];
|
||||||
_containerView.defaultSelectedIndex = 0;
|
_pi_containerView.defaultSelectedIndex = 0;
|
||||||
_containerView.scrollView.tag = 1009;
|
_pi_containerView.scrollView.tag = 1009;
|
||||||
}
|
}
|
||||||
return _containerView;
|
return _pi_containerView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (NSArray<NSString *> *)titles {
|
- (NSArray<NSString *> *)titles {
|
||||||
|
@@ -340,12 +340,7 @@
|
|||||||
[self.navigationController pushViewController:giftWallVC animated:YES];
|
[self.navigationController pushViewController:giftWallVC animated:YES];
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - XPMineDataSkillCardTableViewCell
|
|
||||||
- (void)xPMineDataSkillCardTableViewCell:(XPMineDataSkillCardTableViewCell *)view didSelectItem:(MineSkillCardListInfoModel *)skillInfo {
|
|
||||||
XPSkillCardViewController *skillCardVC = [[XPSkillCardViewController alloc] init];
|
|
||||||
skillCardVC.uid = self.userUid.integerValue;
|
|
||||||
[self.navigationController pushViewController:skillCardVC animated:YES];
|
|
||||||
}
|
|
||||||
|
|
||||||
#pragma mark - JXPagingViewListViewDelegate
|
#pragma mark - JXPagingViewListViewDelegate
|
||||||
- (UIView *)listView {
|
- (UIView *)listView {
|
||||||
|
@@ -1,8 +1,8 @@
|
|||||||
//
|
//
|
||||||
// YMMineUserInfoGiftWalllSubViewController.h
|
// XPMineUserInfoGiftWalllSubViewController.h
|
||||||
// YUMI
|
// xplan-ios
|
||||||
//
|
//
|
||||||
// Created by YUMI on 2022/6/15.
|
// Created by 冯硕 on 2022/6/15.
|
||||||
//
|
//
|
||||||
|
|
||||||
#import "MvpViewController.h"
|
#import "MvpViewController.h"
|
||||||
@@ -10,10 +10,10 @@
|
|||||||
NS_ASSUME_NONNULL_BEGIN
|
NS_ASSUME_NONNULL_BEGIN
|
||||||
|
|
||||||
typedef NS_ENUM(NSInteger, GiftWallViewType) {
|
typedef NS_ENUM(NSInteger, GiftWallViewType) {
|
||||||
///普通礼物
|
///普通礼物
|
||||||
GiftWallViewType_Normal = 1,
|
GiftWallViewType_Normal = 1,
|
||||||
///幸运礼物
|
///幸运礼物
|
||||||
GiftWallViewType_Lucky = 2,
|
GiftWallViewType_Lucky = 2,
|
||||||
};
|
};
|
||||||
|
|
||||||
@interface XPMineUserInfoGiftWallSubViewController : MvpViewController<JXCategoryListContentViewDelegate>
|
@interface XPMineUserInfoGiftWallSubViewController : MvpViewController<JXCategoryListContentViewDelegate>
|
||||||
|
@@ -1,17 +1,14 @@
|
|||||||
//
|
//
|
||||||
// YMMineUserInfoGiftWalllSubViewController.m
|
// XPMineUserInfoGiftWalllSubViewController.m
|
||||||
// YUMI
|
// xplan-ios
|
||||||
//
|
//
|
||||||
// Created by YUMI on 2022/6/15.
|
// Created by 冯硕 on 2022/6/15.
|
||||||
//
|
//
|
||||||
|
|
||||||
#import "XPMineUserInfoGiftWallSubViewController.h"
|
#import "XPMineUserInfoGiftWallSubViewController.h"
|
||||||
///Third
|
///Third
|
||||||
#import <Masonry/Masonry.h>
|
#import <Masonry/Masonry.h>
|
||||||
///Tool
|
///Tool
|
||||||
#import "DJDKMIMOMColor.h"
|
|
||||||
#import "YUMIMacroUitls.h"
|
|
||||||
#import "NSArray+Safe.h"
|
|
||||||
///View
|
///View
|
||||||
#import "XPMineUserInfoGiftWallCollectionViewCell.h"
|
#import "XPMineUserInfoGiftWallCollectionViewCell.h"
|
||||||
#import "XPGuildEmptyCollectionViewCell.h"
|
#import "XPGuildEmptyCollectionViewCell.h"
|
||||||
@@ -23,79 +20,140 @@
|
|||||||
///列表
|
///列表
|
||||||
@property (nonatomic,strong) UICollectionView *collectionView;
|
@property (nonatomic,strong) UICollectionView *collectionView;
|
||||||
@property (nonatomic,strong) NSArray *datasource;
|
@property (nonatomic,strong) NSArray *datasource;
|
||||||
|
@property (nonatomic,assign) NSInteger giftNum;
|
||||||
@end
|
@end
|
||||||
|
|
||||||
@implementation XPMineUserInfoGiftWallSubViewController
|
@implementation XPMineUserInfoGiftWallSubViewController
|
||||||
|
|
||||||
- (__kindof id)createPresenter {
|
- (__kindof id)createPresenter {
|
||||||
return [[XPMineUserInfoGiftWallPresenter alloc] init];
|
return [[XPMineUserInfoGiftWallPresenter alloc] init];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)viewDidLoad {
|
- (void)viewDidLoad {
|
||||||
[super viewDidLoad];
|
[super viewDidLoad];
|
||||||
[self.presenter getUserGiftWall:self.userUid giftType:self.type];
|
[self.presenter getUserGiftWall:self.userUid giftType:self.type];
|
||||||
[self initSubViews];
|
[self initSubViews];
|
||||||
[self initSubViewConstraints];
|
[self initSubViewConstraints];
|
||||||
}
|
}
|
||||||
#pragma mark - Private Method
|
#pragma mark - Private Method
|
||||||
- (void)initSubViews {
|
- (void)initSubViews {
|
||||||
[self.view addSubview:self.collectionView];
|
self.view.backgroundColor = [UIColor whiteColor];
|
||||||
|
[self.view addSubview:self.collectionView];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)initSubViewConstraints {
|
- (void)initSubViewConstraints {
|
||||||
[self.collectionView mas_makeConstraints:^(MASConstraintMaker *make) {
|
[self.collectionView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.edges.mas_equalTo(self.view);
|
make.edges.mas_equalTo(self.view);
|
||||||
}];
|
}];
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - UICollectionViewDelegate And UICollectionViewDatasource
|
#pragma mark - UICollectionViewDelegate And UICollectionViewDatasource
|
||||||
- (NSInteger)collectionView:(UICollectionView *)collectionView numberOfItemsInSection:(NSInteger)section {
|
|
||||||
return self.datasource.count > 0 ? self.datasource.count : 1;
|
-(NSInteger)numberOfSectionsInCollectionView:(UICollectionView *)collectionView{
|
||||||
|
if (self.giftNum == 0)return 1;
|
||||||
|
return 2;
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (CGSize)collectionView:(UICollectionView *)collectionView layout:(UICollectionViewLayout *)collectionViewLayout sizeForItemAtIndexPath:(NSIndexPath *)indexPath {
|
- (CGSize)collectionView:(UICollectionView *)collectionView layout:(UICollectionViewLayout *)collectionViewLayout sizeForItemAtIndexPath:(NSIndexPath *)indexPath {
|
||||||
return self.datasource.count > 0 ? CGSizeMake(74, 120) : CGSizeMake(KScreenWidth, 500);
|
if(self.giftNum > 0){
|
||||||
|
|
||||||
|
CGFloat width = KScreenWidth - kGetScaleWidth(60);
|
||||||
|
return indexPath.section == 0 ? CGSizeMake(width / 3 , kGetScaleWidth(110)): CGSizeMake((width - kGetScaleWidth(15))/4 , kGetScaleWidth(105));
|
||||||
|
}
|
||||||
|
return CGSizeMake(KScreenWidth - 30, 65 * 3 + 30);
|
||||||
|
}
|
||||||
|
- (UIEdgeInsets)collectionView:(UICollectionView *)collectionView layout:(UICollectionViewLayout*)collectionViewLayout insetForSectionAtIndex:(NSInteger)section{
|
||||||
|
if(self.giftNum > 0){
|
||||||
|
return section == 0 ? UIEdgeInsetsMake(0, kGetScaleWidth(15), kGetScaleWidth(15), kGetScaleWidth(15)):UIEdgeInsetsMake(0, kGetScaleWidth(15), 0, kGetScaleWidth(15));
|
||||||
|
}
|
||||||
|
return UIEdgeInsetsMake(0, 0, 0, 0);
|
||||||
|
}
|
||||||
|
- (NSInteger)collectionView:(UICollectionView *)collectionView numberOfItemsInSection:(NSInteger)section {
|
||||||
|
if (self.giftNum == 0)return 1;
|
||||||
|
return [self.datasource[section] count];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (__kindof UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath {
|
- (__kindof UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath {
|
||||||
if (self.datasource.count > 0) {
|
if (self.giftNum > 0) {
|
||||||
XPMineUserInfoGiftWallCollectionViewCell * cell = [collectionView dequeueReusableCellWithReuseIdentifier:NSStringFromClass([XPMineUserInfoGiftWallCollectionViewCell class]) forIndexPath:indexPath];
|
XPMineUserInfoGiftWallCollectionViewCell * cell = [collectionView dequeueReusableCellWithReuseIdentifier:NSStringFromClass([XPMineUserInfoGiftWallCollectionViewCell class]) forIndexPath:indexPath];
|
||||||
UserGiftWallInfoModel * giftInfo = [self.datasource safeObjectAtIndex1:indexPath.row];
|
if (indexPath.section == 0 && self.datasource.count > 0){
|
||||||
cell.giftInfo = giftInfo;
|
NSArray *dataList = self.datasource[indexPath.section];
|
||||||
return cell;
|
if(indexPath.row < dataList.count){
|
||||||
|
cell.giftInfo = [dataList safeObjectAtIndex1:indexPath.row];
|
||||||
}
|
[cell setLevel:((int)indexPath.row + 1)];
|
||||||
XPGuildEmptyCollectionViewCell * cell = [collectionView dequeueReusableCellWithReuseIdentifier:NSStringFromClass([XPGuildEmptyCollectionViewCell class]) forIndexPath:indexPath];
|
}else{
|
||||||
return cell;
|
UICollectionViewCell *cell = [collectionView dequeueReusableCellWithReuseIdentifier:NSStringFromClass([UICollectionViewCell class]) forIndexPath:indexPath];
|
||||||
|
|
||||||
|
return cell;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
if (indexPath.section == 1 && self.datasource.count > 1){
|
||||||
|
NSArray *dataList = self.datasource[indexPath.section];
|
||||||
|
if(indexPath.row < dataList.count){
|
||||||
|
cell.giftInfo = [dataList safeObjectAtIndex1:indexPath.row];
|
||||||
|
}else{
|
||||||
|
UICollectionViewCell *cell = [collectionView dequeueReusableCellWithReuseIdentifier:NSStringFromClass([UICollectionViewCell class]) forIndexPath:indexPath];
|
||||||
|
|
||||||
|
return cell;
|
||||||
|
}
|
||||||
|
[cell setLevel:4];
|
||||||
|
}
|
||||||
|
|
||||||
|
return cell;
|
||||||
|
}
|
||||||
|
|
||||||
|
XPGuildEmptyCollectionViewCell * cell = [collectionView dequeueReusableCellWithReuseIdentifier:NSStringFromClass([XPGuildEmptyCollectionViewCell class]) forIndexPath:indexPath];
|
||||||
|
|
||||||
|
return cell;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#pragma mark - JXCategoryListContentViewDelegate
|
#pragma mark - JXCategoryListContentViewDelegate
|
||||||
- (UIView *)listView {
|
- (UIView *)listView {
|
||||||
return self.view;
|
return self.view;
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - XPMineUserInfoGiftWallProtocol
|
#pragma mark - XPMineUserInfoGiftWallProtocol
|
||||||
- (void)getUserGiftWallSuccess:(NSArray *)giftList {
|
- (void)getUserGiftWallSuccess:(NSArray *)giftList {
|
||||||
self.datasource = giftList;
|
_giftNum = giftList.count ;
|
||||||
[self.collectionView reloadData];
|
NSMutableArray *firstDataSource = [NSMutableArray array];
|
||||||
|
NSMutableArray *secondDataSource = [NSMutableArray array];
|
||||||
|
for (int i = 0; i < giftList.count; i++) {
|
||||||
|
UserGiftWallInfoModel *obj = giftList[i];
|
||||||
|
if(i < 3){
|
||||||
|
[firstDataSource addObject:obj];
|
||||||
|
}else{
|
||||||
|
[secondDataSource addObject:obj];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
_datasource = @[firstDataSource,secondDataSource];
|
||||||
|
[self.collectionView reloadData];
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - Getters And Setters
|
#pragma mark - Getters And Setters
|
||||||
- (UICollectionView *)collectionView{
|
- (UICollectionView *)collectionView{
|
||||||
if (!_collectionView) {
|
if (!_collectionView) {
|
||||||
UICollectionViewFlowLayout *layout = [[UICollectionViewFlowLayout alloc] init];
|
UICollectionViewFlowLayout *layout = [[UICollectionViewFlowLayout alloc] init];
|
||||||
layout.sectionInset = UIEdgeInsetsMake(15, 15, 15, 15);
|
layout.minimumLineSpacing = kGetScaleWidth(15);
|
||||||
layout.minimumInteritemSpacing = (CGFloat)(KScreenWidth - 15 * 2 -74* 4 - 5) / 3.0;
|
layout.minimumInteritemSpacing = 0;
|
||||||
layout.minimumLineSpacing = 30;
|
_collectionView = [[UICollectionView alloc] initWithFrame:CGRectZero collectionViewLayout:layout];
|
||||||
_collectionView = [[UICollectionView alloc] initWithFrame:CGRectZero collectionViewLayout:layout];
|
_collectionView.dataSource = self;
|
||||||
_collectionView.dataSource = self;
|
_collectionView.delegate = self;
|
||||||
_collectionView.delegate = self;
|
_collectionView.pagingEnabled = NO;
|
||||||
_collectionView.backgroundColor = [UIColor clearColor];
|
|
||||||
[_collectionView registerClass:[XPMineUserInfoGiftWallCollectionViewCell class] forCellWithReuseIdentifier:NSStringFromClass([XPMineUserInfoGiftWallCollectionViewCell class])];
|
_collectionView.backgroundColor = [UIColor clearColor];
|
||||||
[_collectionView registerClass:[XPGuildEmptyCollectionViewCell class] forCellWithReuseIdentifier:NSStringFromClass([XPGuildEmptyCollectionViewCell class])];
|
[_collectionView registerClass:[XPMineUserInfoGiftWallCollectionViewCell class] forCellWithReuseIdentifier:NSStringFromClass([XPMineUserInfoGiftWallCollectionViewCell class])];
|
||||||
}
|
[_collectionView registerClass:[XPGuildEmptyCollectionViewCell class] forCellWithReuseIdentifier:NSStringFromClass([XPGuildEmptyCollectionViewCell class])];
|
||||||
return _collectionView;
|
[_collectionView registerClass:[UICollectionViewCell class] forCellWithReuseIdentifier:NSStringFromClass([UICollectionViewCell class])];
|
||||||
|
|
||||||
|
}
|
||||||
|
return _collectionView;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
@@ -1,8 +1,8 @@
|
|||||||
//
|
//
|
||||||
// YMMineGiftWallViewController.m
|
// XPMineGiftWallViewController.m
|
||||||
// YUMI
|
// xplan-ios
|
||||||
//
|
//
|
||||||
// Created by YUMI on 2022/4/14.
|
// Created by 冯硕 on 2022/4/14.
|
||||||
//
|
//
|
||||||
|
|
||||||
#import "XPMineUserInfoGiftWallViewController.h"
|
#import "XPMineUserInfoGiftWallViewController.h"
|
||||||
@@ -12,8 +12,7 @@
|
|||||||
#import <JXCategoryView/JXCategoryIndicatorBackgroundView.h>
|
#import <JXCategoryView/JXCategoryIndicatorBackgroundView.h>
|
||||||
#import <JXCategoryView/JXCategoryListContainerView.h>
|
#import <JXCategoryView/JXCategoryListContainerView.h>
|
||||||
///Tool
|
///Tool
|
||||||
#import "DJDKMIMOMColor.h"
|
|
||||||
#import "YUMIMacroUitls.h"
|
|
||||||
#import "UIImage+Utils.h"
|
#import "UIImage+Utils.h"
|
||||||
///View
|
///View
|
||||||
#import "XPMineUserInfoGiftWallSubViewController.h"
|
#import "XPMineUserInfoGiftWallSubViewController.h"
|
||||||
@@ -25,7 +24,7 @@
|
|||||||
///分页控件
|
///分页控件
|
||||||
@property (nonatomic, strong) JXCategoryTitleView *titleView;
|
@property (nonatomic, strong) JXCategoryTitleView *titleView;
|
||||||
///分页lineView
|
///分页lineView
|
||||||
@property (nonatomic, strong) JXCategoryListContainerView *containerView;
|
@property (nonatomic, strong) JXCategoryListContainerView *pi_containerView;
|
||||||
///普通礼物
|
///普通礼物
|
||||||
@property (nonatomic,strong) XPMineUserInfoGiftWallSubViewController *normalGiftVC;
|
@property (nonatomic,strong) XPMineUserInfoGiftWallSubViewController *normalGiftVC;
|
||||||
///幸运礼物
|
///幸运礼物
|
||||||
@@ -35,113 +34,114 @@
|
|||||||
@implementation XPMineUserInfoGiftWallViewController
|
@implementation XPMineUserInfoGiftWallViewController
|
||||||
- (void)viewDidLoad {
|
- (void)viewDidLoad {
|
||||||
[super viewDidLoad];
|
[super viewDidLoad];
|
||||||
[self initSubViews];
|
[self initSubViews];
|
||||||
[self initSubViewConstraints];
|
[self initSubViewConstraints];
|
||||||
}
|
}
|
||||||
#pragma mark - Private Method
|
#pragma mark - Private Method
|
||||||
- (void)initSubViews {
|
- (void)initSubViews {
|
||||||
self.title = YMLocalizedString(@"XPMineUserInfoGiftWallViewController0");
|
self.view.backgroundColor = [UIColor whiteColor];
|
||||||
[self.view addSubview:self.titleView];
|
self.title = YMLocalizedString(@"XPMineUserInfoGiftWallViewController0");
|
||||||
[self.view addSubview:self.containerView];
|
[self.view addSubview:self.titleView];
|
||||||
|
[self.view addSubview:self.pi_containerView];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)initSubViewConstraints {
|
- (void)initSubViewConstraints {
|
||||||
[self.titleView mas_makeConstraints:^(MASConstraintMaker *make) {
|
[self.titleView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.centerX.mas_equalTo(self.view);
|
make.centerX.mas_equalTo(self.view);
|
||||||
make.width.mas_equalTo(100 * 2 + 20);
|
make.width.mas_equalTo(100 * 2 + 20);
|
||||||
make.height.mas_equalTo(30);
|
make.height.mas_equalTo(30);
|
||||||
make.top.mas_equalTo(self.view).offset(10);
|
make.top.mas_equalTo(self.view).offset(10);
|
||||||
}];
|
}];
|
||||||
|
|
||||||
[self.containerView mas_makeConstraints:^(MASConstraintMaker *make) {
|
[self.pi_containerView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.left.right.bottom.mas_equalTo(self.view);
|
make.left.right.bottom.mas_equalTo(self.view);
|
||||||
make.top.mas_equalTo(self.titleView.mas_bottom).offset(10);
|
make.top.mas_equalTo(self.titleView.mas_bottom).offset(10);
|
||||||
}];
|
}];
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - JXCategoryViewDelegate
|
#pragma mark - JXCategoryViewDelegate
|
||||||
- (NSInteger)numberOfListsInlistContainerView:(JXCategoryListContainerView *)listContainerView {
|
- (NSInteger)numberOfListsInlistContainerView:(JXCategoryListContainerView *)listContainerView {
|
||||||
return self.titles.count;
|
return self.titles.count;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (id<JXCategoryListContentViewDelegate>)listContainerView:(JXCategoryListContainerView *)listContainerView initListForIndex:(NSInteger)index {
|
- (id<JXCategoryListContentViewDelegate>)listContainerView:(JXCategoryListContainerView *)listContainerView initListForIndex:(NSInteger)index {
|
||||||
if (index == 0) {
|
if (index == 0) {
|
||||||
return self.normalGiftVC;
|
return self.normalGiftVC;
|
||||||
} else {
|
} else {
|
||||||
return self.luckyGiftVC;
|
return self.luckyGiftVC;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)categoryView:(JXCategoryBaseView *)categoryView didSelectedItemAtIndex:(NSInteger)index {
|
- (void)categoryView:(JXCategoryBaseView *)categoryView didSelectedItemAtIndex:(NSInteger)index {
|
||||||
// 侧滑手势处理
|
// 侧滑手势处理
|
||||||
self.navigationController.interactivePopGestureRecognizer.enabled = (index == 0);
|
self.navigationController.interactivePopGestureRecognizer.enabled = (index == 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - Getters And Setters
|
#pragma mark - Getters And Setters
|
||||||
- (void)setUserUid:(NSString *)userUid {
|
- (void)setUserUid:(NSString *)userUid {
|
||||||
_userUid = userUid;
|
_userUid = userUid;
|
||||||
self.normalGiftVC.userUid = _userUid;
|
self.normalGiftVC.userUid = _userUid;
|
||||||
self.luckyGiftVC.userUid = _userUid;
|
self.luckyGiftVC.userUid = _userUid;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (JXCategoryTitleView *)titleView {
|
- (JXCategoryTitleView *)titleView {
|
||||||
if (!_titleView) {
|
if (!_titleView) {
|
||||||
_titleView = [[JXCategoryTitleView alloc] init];
|
_titleView = [[JXCategoryTitleView alloc] init];
|
||||||
_titleView.delegate = self;
|
_titleView.delegate = self;
|
||||||
_titleView.titles = self.titles;
|
_titleView.titles = self.titles;
|
||||||
_titleView.backgroundColor = [UIColor clearColor];
|
_titleView.backgroundColor = [UIColor clearColor];
|
||||||
_titleView.titleColor = [DJDKMIMOMColor secondTextColor];
|
_titleView.titleColor = UIColorFromRGB(0xB3B3C3);
|
||||||
_titleView.titleSelectedColor = [DJDKMIMOMColor mainTextColor];
|
_titleView.titleSelectedColor = UIColorFromRGB(0x1F1A4E);
|
||||||
_titleView.titleFont = [UIFont systemFontOfSize:12];
|
_titleView.titleFont = [UIFont systemFontOfSize:14 weight:UIFontWeightMedium];
|
||||||
_titleView.titleSelectedFont = [UIFont systemFontOfSize:12 weight:UIFontWeightMedium];
|
_titleView.titleSelectedFont = [UIFont systemFontOfSize:14 weight:UIFontWeightMedium];
|
||||||
_titleView.titleLabelAnchorPointStyle = JXCategoryTitleLabelAnchorPointStyleCenter;
|
_titleView.titleLabelAnchorPointStyle = JXCategoryTitleLabelAnchorPointStyleCenter;
|
||||||
_titleView.contentScrollViewClickTransitionAnimationEnabled = NO;
|
_titleView.contentScrollViewClickTransitionAnimationEnabled = NO;
|
||||||
_titleView.defaultSelectedIndex = 0;
|
_titleView.defaultSelectedIndex = 0;
|
||||||
_titleView.cellSpacing = 20;
|
_titleView.cellSpacing = 20;
|
||||||
_titleView.cellWidthIncrement = 5;
|
_titleView.cellWidthIncrement = 5;
|
||||||
_titleView.cellWidth = 60;
|
_titleView.cellWidth = 60;
|
||||||
_titleView.listContainer = self.containerView;
|
_titleView.listContainer = self.pi_containerView;
|
||||||
|
|
||||||
JXCategoryIndicatorImageView *lineView = [[JXCategoryIndicatorImageView alloc] init];
|
JXCategoryIndicatorImageView *lineView = [[JXCategoryIndicatorImageView alloc] init];
|
||||||
lineView.indicatorImageViewSize = CGSizeMake(60, 8);
|
lineView.indicatorImageViewSize = CGSizeMake(15, 3);
|
||||||
lineView.verticalMargin = 6;
|
lineView.verticalMargin = 0;
|
||||||
lineView.indicatorImageView.image = [UIImage gradientColorImageFromColors:@[UIColorFromRGB(0xFFC000), UIColorFromRGB(0xFFD15A)] gradientType:GradientTypeLeftToRight imgSize:CGSizeMake(60, 8)];
|
lineView.indicatorImageView.image = [UIImage gradientColorImageFromColors:@[[DJDKMIMOMColor confirmButtonGradientStartColor], [DJDKMIMOMColor confirmButtonGradientMiddleColor],[DJDKMIMOMColor confirmButtonGradientEndColor]] gradientType:GradientTypeLeftToRight imgSize:CGSizeMake(15, 3)];
|
||||||
lineView.indicatorImageView.layer.masksToBounds = YES;
|
lineView.indicatorImageView.layer.masksToBounds = YES;
|
||||||
lineView.indicatorImageView.layer.cornerRadius = 4;
|
lineView.indicatorImageView.layer.cornerRadius = 1.5;
|
||||||
_titleView.indicators = @[lineView];
|
_titleView.indicators = @[lineView];
|
||||||
}
|
}
|
||||||
return _titleView;
|
return _titleView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (JXCategoryListContainerView *)containerView {
|
- (JXCategoryListContainerView *)pi_containerView {
|
||||||
if (!_containerView) {
|
if (!_pi_containerView) {
|
||||||
_containerView = [[JXCategoryListContainerView alloc] initWithType:JXCategoryListContainerType_ScrollView delegate:self];
|
_pi_containerView = [[JXCategoryListContainerView alloc] initWithType:JXCategoryListContainerType_ScrollView delegate:self];
|
||||||
_containerView.defaultSelectedIndex = 0;
|
_pi_containerView.defaultSelectedIndex = 0;
|
||||||
}
|
}
|
||||||
return _containerView;
|
return _pi_containerView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (NSArray<NSString *> *)titles {
|
- (NSArray<NSString *> *)titles {
|
||||||
if (!_titles) {
|
if (!_titles) {
|
||||||
_titles = @[YMLocalizedString(@"XPWishGiftCreateItemViewController0"), YMLocalizedString(@"XPMineUserInfoGiftWallViewController2")];
|
_titles = @[YMLocalizedString(@"XPMineUserInfoGiftWallViewController1"), YMLocalizedString(@"XPMineUserInfoGiftWallViewController2")];
|
||||||
}
|
}
|
||||||
return _titles;
|
return _titles;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (XPMineUserInfoGiftWallSubViewController *)normalGiftVC {
|
- (XPMineUserInfoGiftWallSubViewController *)normalGiftVC {
|
||||||
if (!_normalGiftVC) {
|
if (!_normalGiftVC) {
|
||||||
_normalGiftVC = [[XPMineUserInfoGiftWallSubViewController alloc] init];
|
_normalGiftVC = [[XPMineUserInfoGiftWallSubViewController alloc] init];
|
||||||
_normalGiftVC.type = GiftWallViewType_Normal;
|
_normalGiftVC.type = GiftWallViewType_Normal;
|
||||||
}
|
}
|
||||||
return _normalGiftVC;
|
return _normalGiftVC;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (XPMineUserInfoGiftWallSubViewController *)luckyGiftVC {
|
- (XPMineUserInfoGiftWallSubViewController *)luckyGiftVC {
|
||||||
if (!_luckyGiftVC) {
|
if (!_luckyGiftVC) {
|
||||||
_luckyGiftVC = [[XPMineUserInfoGiftWallSubViewController alloc] init];
|
_luckyGiftVC = [[XPMineUserInfoGiftWallSubViewController alloc] init];
|
||||||
_luckyGiftVC.type = GiftWallViewType_Lucky;
|
_luckyGiftVC.type = GiftWallViewType_Lucky;
|
||||||
}
|
}
|
||||||
return _luckyGiftVC;
|
return _luckyGiftVC;
|
||||||
}
|
}
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
@@ -28,7 +28,6 @@
|
|||||||
#import "XPMineUserInfoTagModel.h"
|
#import "XPMineUserInfoTagModel.h"
|
||||||
#import "UploadFile.h"
|
#import "UploadFile.h"
|
||||||
///View
|
///View
|
||||||
#import "XPMineUserInfoTableViewCell.h"
|
|
||||||
#import "XPMineUserInfoHeaderView.h"
|
#import "XPMineUserInfoHeaderView.h"
|
||||||
#import "XPMineUserInfoCustomNavView.h"
|
#import "XPMineUserInfoCustomNavView.h"
|
||||||
#import "XPMineUserInfoVoiceCardView.h"
|
#import "XPMineUserInfoVoiceCardView.h"
|
||||||
|
@@ -190,7 +190,7 @@
|
|||||||
|
|
||||||
@kWeakify(self);
|
@kWeakify(self);
|
||||||
SVGAParser * parser = [[SVGAParser alloc]init];
|
SVGAParser * parser = [[SVGAParser alloc]init];
|
||||||
[parser parseWithNamed:@"mine_info_online" inBundle:[NSBundle mainBundle] completionBlock:^(SVGAVideoEntity * _Nonnull videoItem) {
|
[parser parseWithNamed:@"pi_new_mine_info_online" inBundle:[NSBundle mainBundle] completionBlock:^(SVGAVideoEntity * _Nonnull videoItem) {
|
||||||
@kStrongify(self);
|
@kStrongify(self);
|
||||||
self.onlineIconView.loops = 0;
|
self.onlineIconView.loops = 0;
|
||||||
self.onlineIconView.clearsAfterStop = NO;
|
self.onlineIconView.clearsAfterStop = NO;
|
||||||
@@ -201,7 +201,7 @@
|
|||||||
}];
|
}];
|
||||||
|
|
||||||
SVGAParser *soundParser = [SVGAParser new];
|
SVGAParser *soundParser = [SVGAParser new];
|
||||||
[soundParser parseWithNamed:@"mine_info_sound_play" inBundle:[NSBundle mainBundle] completionBlock:^(SVGAVideoEntity * _Nonnull videoItem) {
|
[soundParser parseWithNamed:@"pi_new_mine_info_sound_play" inBundle:[NSBundle mainBundle] completionBlock:^(SVGAVideoEntity * _Nonnull videoItem) {
|
||||||
@kStrongify(self);
|
@kStrongify(self);
|
||||||
self.soundSVGAView.loops = 0;
|
self.soundSVGAView.loops = 0;
|
||||||
self.soundSVGAView.clearsAfterStop = NO;
|
self.soundSVGAView.clearsAfterStop = NO;
|
||||||
@@ -564,7 +564,7 @@
|
|||||||
self.idLabel.attributedText = textAtt;
|
self.idLabel.attributedText = textAtt;
|
||||||
|
|
||||||
|
|
||||||
self.signLabel.text = _userInfo.userDesc.length > 0 ? _userInfo.userDesc : YMLocalizedString(@"XPMineUserInfoHeaderView0");
|
self.signLabel.text = _userInfo.userDesc.length > 0 ? _userInfo.userDesc : YMLocalizedString(@"XPTreasureFairyFriendCell0");
|
||||||
self.fansNumLabel.text =[NSString stringWithFormat:YMLocalizedString(@"XPMineUserInfoHeaderView2"), _userInfo.fansNum];
|
self.fansNumLabel.text =[NSString stringWithFormat:YMLocalizedString(@"XPMineUserInfoHeaderView2"), _userInfo.fansNum];
|
||||||
self.sexImageView.image = userInfo.gender == GenderType_Female ? [UIImage imageNamed:@"common_female"] : [UIImage imageNamed:@"common_male"];
|
self.sexImageView.image = userInfo.gender == GenderType_Female ? [UIImage imageNamed:@"common_female"] : [UIImage imageNamed:@"common_male"];
|
||||||
self.officalImageView.hidden = userInfo.defUser != UserLevelType_Offical;
|
self.officalImageView.hidden = userInfo.defUser != UserLevelType_Offical;
|
||||||
|
@@ -0,0 +1,26 @@
|
|||||||
|
//
|
||||||
|
// XPMineUserInfoNavView.h
|
||||||
|
// xplan-ios
|
||||||
|
//
|
||||||
|
// Created by duoban on 2023/2/15.
|
||||||
|
//
|
||||||
|
|
||||||
|
#import <UIKit/UIKit.h>
|
||||||
|
|
||||||
|
NS_ASSUME_NONNULL_BEGIN
|
||||||
|
@class XPMineUserInfoNavView;
|
||||||
|
|
||||||
|
@protocol XPMineUserInfoNavViewDelegate <NSObject>
|
||||||
|
//点击了返回
|
||||||
|
- (void)xPMineUserInfoNavView:(XPMineUserInfoNavView *)view didClickBack:(UIButton *)sender;
|
||||||
|
///点击了搜索
|
||||||
|
- (void)xPMineUserInfoNavView:(XPMineUserInfoNavView *)view didClickComplete:(UIButton *)sender;
|
||||||
|
@end
|
||||||
|
|
||||||
|
|
||||||
|
@interface XPMineUserInfoNavView : UIView
|
||||||
|
///
|
||||||
|
@property (nonatomic,weak) id<XPMineUserInfoNavViewDelegate> delegate;
|
||||||
|
@end
|
||||||
|
|
||||||
|
NS_ASSUME_NONNULL_END
|
@@ -0,0 +1,88 @@
|
|||||||
|
//
|
||||||
|
// XPMineUserInfoNavView.m
|
||||||
|
// xplan-ios
|
||||||
|
//
|
||||||
|
// Created by duoban on 2023/2/15.
|
||||||
|
//
|
||||||
|
|
||||||
|
#import "XPMineUserInfoNavView.h"
|
||||||
|
@interface XPMineUserInfoNavView()
|
||||||
|
///返回
|
||||||
|
@property (nonatomic,strong) UIButton *backButton;
|
||||||
|
///标题
|
||||||
|
@property (nonatomic,strong) UILabel *titleView;
|
||||||
|
///完成
|
||||||
|
@property (nonatomic,strong) UIButton *completeBtn;
|
||||||
|
@end
|
||||||
|
@implementation XPMineUserInfoNavView
|
||||||
|
|
||||||
|
-(instancetype)initWithFrame:(CGRect)frame{
|
||||||
|
self = [super initWithFrame:frame];
|
||||||
|
if(self){
|
||||||
|
[self initSubViews];
|
||||||
|
[self initSubViewConstraints];
|
||||||
|
}
|
||||||
|
return self;
|
||||||
|
}
|
||||||
|
|
||||||
|
#pragma mark - Private Method
|
||||||
|
- (void)initSubViews {
|
||||||
|
[self addSubview:self.backButton];
|
||||||
|
[self addSubview:self.titleView];
|
||||||
|
[self addSubview:self.completeBtn];
|
||||||
|
}
|
||||||
|
- (void)initSubViewConstraints {
|
||||||
|
[self.backButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.width.height.mas_equalTo(kGetScaleWidth(28));
|
||||||
|
make.left.mas_equalTo(0);
|
||||||
|
make.bottom.mas_equalTo(-kGetScaleWidth(8));
|
||||||
|
}];
|
||||||
|
[self.titleView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.centerY.equalTo(self.backButton);
|
||||||
|
make.centerX.equalTo(self);
|
||||||
|
}];
|
||||||
|
[self.completeBtn mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.right.mas_equalTo(-kGetScaleWidth(15));
|
||||||
|
make.width.mas_equalTo(kGetScaleWidth(40));
|
||||||
|
make.height.mas_equalTo(kGetScaleWidth(24));
|
||||||
|
make.centerY.equalTo(self.backButton);
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
-(void)backButtonAction{
|
||||||
|
if(self.delegate && [self.delegate respondsToSelector:@selector(xPMineUserInfoNavView:didClickBack:)]){
|
||||||
|
[self.delegate xPMineUserInfoNavView:self didClickBack:self.backButton];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
-(void)completeAction{
|
||||||
|
if(self.delegate && [self.delegate respondsToSelector:@selector(xPMineUserInfoNavView:didClickComplete:)]){
|
||||||
|
[self.delegate xPMineUserInfoNavView:self didClickComplete:self.completeBtn];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#pragma mark -懒加载
|
||||||
|
- (UIButton *)backButton {
|
||||||
|
if (!_backButton) {
|
||||||
|
_backButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
||||||
|
[_backButton setImage:[UIImage imageNamed:@"common_nav_back"] forState:UIControlStateNormal];
|
||||||
|
[_backButton setImage:[UIImage imageNamed:@"common_nav_back"] forState:UIControlStateSelected];
|
||||||
|
[_backButton addTarget:self action:@selector(backButtonAction) forControlEvents:UIControlEventTouchUpInside];
|
||||||
|
[_backButton setEnlargeEdgeWithTop:10 right:5 bottom:10 left:8];
|
||||||
|
}
|
||||||
|
return _backButton;
|
||||||
|
}
|
||||||
|
- (UILabel *)titleView{
|
||||||
|
if (!_titleView){
|
||||||
|
_titleView = [UILabel labelInitWithText:YMLocalizedString(@"XPMineUserInfoTagVC0") font:kFontSemibold(17) textColor:UIColorFromRGB(0x1F1B4F)];
|
||||||
|
}
|
||||||
|
return _titleView;
|
||||||
|
}
|
||||||
|
- (UIButton *)completeBtn{
|
||||||
|
if (!_completeBtn){
|
||||||
|
_completeBtn = [UIButton new];
|
||||||
|
[_completeBtn setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
|
||||||
|
[_completeBtn setEnlargeEdgeWithTop:10 right:10 bottom:10 left:10];
|
||||||
|
[_completeBtn setTitle:YMLocalizedString(@"XPMineUserInfoTagVC1") forState:UIControlStateNormal];
|
||||||
|
[_completeBtn addTarget:self action:@selector(completeAction) forControlEvents:UIControlEventTouchUpInside];
|
||||||
|
}
|
||||||
|
return _completeBtn;
|
||||||
|
}
|
||||||
|
@end
|
@@ -1,24 +1,23 @@
|
|||||||
//
|
//
|
||||||
// XPMonentsLayoutConfig.h
|
// YMMonentsLayoutConfig.h
|
||||||
// xplan-ios
|
// YUMI
|
||||||
//
|
//
|
||||||
// Created by 冯硕 on 2022/5/12.
|
// Created by YUMI on 2022/5/12.
|
||||||
//
|
//
|
||||||
|
|
||||||
#import <Foundation/Foundation.h>
|
#import <Foundation/Foundation.h>
|
||||||
|
#import "YUMIMacroUitls.h"
|
||||||
NS_ASSUME_NONNULL_BEGIN
|
NS_ASSUME_NONNULL_BEGIN
|
||||||
#define kMONENTS_CONTENT_LEFT_PADDING 18
|
#define kMONENTS_CONTENT_LEFT_PADDING 67
|
||||||
#define kMONENTS_CONTENT_RIGHT_PADDING 18
|
#define kMONENTS_CONTENT_RIGHT_PADDING 36
|
||||||
#define kMONENTS_CONTENT_MAX_WIDTH (KScreenWidth - kMONENTS_CONTENT_LEFT_PADDING - kMONENTS_CONTENT_RIGHT_PADDING)
|
#define kMONENTS_CONTENT_MAX_WIDTH (KScreenWidth - kMONENTS_CONTENT_LEFT_PADDING - kMONENTS_CONTENT_RIGHT_PADDING)
|
||||||
#define kMONENTS_PIC_ONE_WIDTH 109 ///只有一个动态图片的高度
|
#define kMONENTS_PIC_ONE_WIDTH 200 ///只有一个动态图片的高度
|
||||||
#define kMONENTS_PIC_SPACE 4 ///图片之间的间隙的宽度或者高度
|
#define kMONENTS_PIC_SPACE 4 ///图片之间的间隙的宽度或者高度
|
||||||
#define kMONENTS_USER_INFO_HEIGHT 50 ///用户信息的高度
|
#define kMONENTS_USER_INFO_HEIGHT 60 ///用户信息的高度
|
||||||
#define kMONENTS_TOOL_BAR_HEIGHT 58 ///底部操作栏的高度
|
#define kMONENTS_TOOL_BAR_HEIGHT 58 ///底部操作栏的高度
|
||||||
#define kMONENTS_CONTENT_SPACAE_HEIGHT 12 /// 每个内容之间下面的间隙的高度
|
#define kMONENTS_CONTENT_SPACAE_HEIGHT 12 /// 每个内容之间下面的间隙的高度
|
||||||
#define kMONENTS_TEXT_TOPIC_HEIGHT 15 /// 话题的高度
|
#define kMONENTS_TEXT_TOPIC_HEIGHT 20 /// 话题的高度
|
||||||
#define kMONENTS_FOLD_HEIGHT 20 /// 展开 关闭的高度
|
#define kMONENTS_FOLD_HEIGHT 20 /// 展开 关闭的高度
|
||||||
#define kMONENTS_Time_HEIGHT 14 /// 时间
|
|
||||||
#define kMONENTS_Content_Text_Space 5 /// 内容 展开按钮 时间的间隙
|
|
||||||
#pragma mark - 评论的配置
|
#pragma mark - 评论的配置
|
||||||
#define kMONENTS_COMMENT_LEFT_PADDING 15 ///评论左的间隙
|
#define kMONENTS_COMMENT_LEFT_PADDING 15 ///评论左的间隙
|
||||||
#define kMONENTS_COMMENT_RIGHT_PADDING 25 ///评论右的间隙
|
#define kMONENTS_COMMENT_RIGHT_PADDING 25 ///评论右的间隙
|
||||||
@@ -30,8 +29,16 @@ NS_ASSUME_NONNULL_BEGIN
|
|||||||
#define kMONENTS_COMMENT_REPLY_LEFT_PADDING (kMONENTS_COMMENT_LEFT_PADDING + kMONENTS_COMMENT_RIGHT_PADDING + kMONENTS_COMMENT_AVATAR_NICK_PADDING) ///回复这左边的间隙
|
#define kMONENTS_COMMENT_REPLY_LEFT_PADDING (kMONENTS_COMMENT_LEFT_PADDING + kMONENTS_COMMENT_RIGHT_PADDING + kMONENTS_COMMENT_AVATAR_NICK_PADDING) ///回复这左边的间隙
|
||||||
#define KMONENTS_COMMENT_REPLY_MAX_WIDTH (KMONENTS_COMMENT_MAX_WIDTH - KMONENTS_COMMENT_REPLY_AVATAR_WIDTH - kMONENTS_COMMENT_AVATAR_NICK_PADDING) ///评论回复内容的最大宽度
|
#define KMONENTS_COMMENT_REPLY_MAX_WIDTH (KMONENTS_COMMENT_MAX_WIDTH - KMONENTS_COMMENT_REPLY_AVATAR_WIDTH - kMONENTS_COMMENT_AVATAR_NICK_PADDING) ///评论回复内容的最大宽度
|
||||||
|
|
||||||
|
#pragma mark - 审核UI配置
|
||||||
|
#define kSIMPLE_MONENTS_CONTENT_LEFT_PADDING 16 ///动态内容左边间距
|
||||||
|
#define kSIMPLE_MONENTS_CONTENT_RIGHT_PADDING 16 ///动态内容右边间距
|
||||||
|
#define kSIMPLE_MONENTS_CONTENT_MAX_WIDTH (KScreenWidth - kSIMPLE_MONENTS_CONTENT_LEFT_PADDING - kSIMPLE_MONENTS_CONTENT_RIGHT_PADDING) ///动态内容最大宽度
|
||||||
|
|
||||||
|
#define KSIMPLE_MONENTS_COMMENT_AVATAR_WIDTH 40 ///评论的头像大小
|
||||||
|
|
||||||
@class MonentsInfoModel, MonentsCommentModel;
|
@class MonentsInfoModel, MonentsCommentModel;
|
||||||
@interface XPMonentsLayoutConfig : NSObject
|
@interface XPMonentsLayoutConfig : NSObject
|
||||||
|
+ (void)layoutSimpleMonentsModel:(MonentsInfoModel *)monents;
|
||||||
+ (void)layoutMonentsModel:(MonentsInfoModel *)monents;
|
+ (void)layoutMonentsModel:(MonentsInfoModel *)monents;
|
||||||
+ (CGFloat)monentsPicHeight:(MonentsInfoModel *)monents;
|
+ (CGFloat)monentsPicHeight:(MonentsInfoModel *)monents;
|
||||||
+ (CGFloat)monentsContentHeight:(MonentsInfoModel *)monents;
|
+ (CGFloat)monentsContentHeight:(MonentsInfoModel *)monents;
|
||||||
|
@@ -1,19 +1,21 @@
|
|||||||
//
|
//
|
||||||
// XPMonentsLayoutConfig.m
|
// YMMonentsLayoutConfig.m
|
||||||
// xplan-ios
|
// YUMI
|
||||||
//
|
//
|
||||||
// Created by 冯硕 on 2022/5/12.
|
// Created by YUMI on 2022/5/12.
|
||||||
//
|
//
|
||||||
|
|
||||||
#import "XPMonentsLayoutConfig.h"
|
#import "XPMonentsLayoutConfig.h"
|
||||||
#import <YYText/YYText.h>
|
#import <YYText/YYText.h>
|
||||||
|
#import "DJDKMIMOMColor.h"
|
||||||
///Model
|
///Model
|
||||||
#import "MonentsInfoModel.h"
|
#import "MonentsInfoModel.h"
|
||||||
#import "MonentsCommentModel.h"
|
#import "MonentsCommentModel.h"
|
||||||
#import "QEmotionHelper.h"
|
#import "QEmotionHelper.h"
|
||||||
|
|
||||||
@implementation XPMonentsLayoutConfig
|
@implementation XPMonentsLayoutConfig
|
||||||
|
|
||||||
|
#pragma mark - 审核的布局
|
||||||
+ (void)getNewlayoutMonentsModelWithDynamic:(MonentsInfoModel *)monents {
|
+ (void)getNewlayoutMonentsModelWithDynamic:(MonentsInfoModel *)monents {
|
||||||
CGFloat rowHeight = 10;
|
CGFloat rowHeight = 10;
|
||||||
///用户信息和文字之间的间隙
|
///用户信息和文字之间的间隙
|
||||||
@@ -34,52 +36,6 @@
|
|||||||
rowHeight += kMONENTS_TOOL_BAR_HEIGHT;
|
rowHeight += kMONENTS_TOOL_BAR_HEIGHT;
|
||||||
monents.rowHeight = rowHeight;
|
monents.rowHeight = rowHeight;
|
||||||
}
|
}
|
||||||
+ (void)layoutMonentsModelWithDynamic:(MonentsInfoModel *)monents {
|
|
||||||
CGFloat rowHeight = 10;
|
|
||||||
///用户信息和文字之间的间隙
|
|
||||||
rowHeight += kMONENTS_CONTENT_SPACAE_HEIGHT;
|
|
||||||
///文字内容的高度
|
|
||||||
rowHeight += [self monentsContentHeight:monents];
|
|
||||||
///图片的高度
|
|
||||||
rowHeight += [self monentsPicHeight:monents];
|
|
||||||
///如果没有图片的话 间隙就只有一个
|
|
||||||
if (monents.type == MonentsContentType_Picture && monents.content.length > 0) {
|
|
||||||
rowHeight += (kMONENTS_CONTENT_SPACAE_HEIGHT);
|
|
||||||
}
|
|
||||||
///话题的高度
|
|
||||||
if (monents.worldId > 0) {
|
|
||||||
rowHeight += kMONENTS_TEXT_TOPIC_HEIGHT;
|
|
||||||
}
|
|
||||||
///底部操作栏的高度
|
|
||||||
rowHeight += kMONENTS_TOOL_BAR_HEIGHT;
|
|
||||||
monents.rowHeight = rowHeight;
|
|
||||||
}
|
|
||||||
|
|
||||||
+ (void)layoutMonentsModel:(MonentsInfoModel *)monents {
|
|
||||||
CGFloat rowHeight = kMONENTS_USER_INFO_HEIGHT;
|
|
||||||
///用户信息和文字之间的间隙
|
|
||||||
rowHeight += kMONENTS_CONTENT_SPACAE_HEIGHT;
|
|
||||||
///文字内容的高度
|
|
||||||
rowHeight += [self monentsContentHeight:monents];
|
|
||||||
///图片的高度
|
|
||||||
rowHeight += [self monentsPicHeight:monents];
|
|
||||||
///如果没有图片的话 间隙就只有一个
|
|
||||||
if (monents.type == MonentsContentType_Picture) {
|
|
||||||
rowHeight += 8; //stackView设置的space=8
|
|
||||||
}
|
|
||||||
///话题的高度
|
|
||||||
if (monents.worldId > 0) {
|
|
||||||
rowHeight += kMONENTS_TEXT_TOPIC_HEIGHT;
|
|
||||||
rowHeight += (kMONENTS_CONTENT_SPACAE_HEIGHT);
|
|
||||||
}
|
|
||||||
///底部操作栏的高度
|
|
||||||
rowHeight += kMONENTS_TOOL_BAR_HEIGHT;
|
|
||||||
|
|
||||||
///时间高度,cell在约束文本内容的stackView时,直接加了24,这里统一
|
|
||||||
rowHeight += 24;
|
|
||||||
|
|
||||||
monents.rowHeight = rowHeight;
|
|
||||||
}
|
|
||||||
+ (CGFloat)getNewMonentsPicHeight:(MonentsInfoModel *)monents {
|
+ (CGFloat)getNewMonentsPicHeight:(MonentsInfoModel *)monents {
|
||||||
///计算图片的高度
|
///计算图片的高度
|
||||||
NSInteger picCount = monents.dynamicResList.count;
|
NSInteger picCount = monents.dynamicResList.count;
|
||||||
@@ -107,6 +63,131 @@
|
|||||||
monents.picHeight = picHeight;
|
monents.picHeight = picHeight;
|
||||||
return picHeight;
|
return picHeight;
|
||||||
}
|
}
|
||||||
|
+ (void)layoutMonentsModelWithDynamic:(MonentsInfoModel *)monents {
|
||||||
|
CGFloat rowHeight = 10;
|
||||||
|
///用户信息和文字之间的间隙
|
||||||
|
rowHeight += kMONENTS_CONTENT_SPACAE_HEIGHT;
|
||||||
|
///文字内容的高度
|
||||||
|
rowHeight += [self monentsContentHeight:monents];
|
||||||
|
///图片的高度
|
||||||
|
rowHeight += [self monentsPicHeight:monents];
|
||||||
|
///如果没有图片的话 间隙就只有一个
|
||||||
|
if (monents.type == MonentsContentType_Picture && monents.content.length > 0) {
|
||||||
|
rowHeight += (kMONENTS_CONTENT_SPACAE_HEIGHT);
|
||||||
|
}
|
||||||
|
///话题的高度
|
||||||
|
if (monents.worldId > 0) {
|
||||||
|
rowHeight += kMONENTS_TEXT_TOPIC_HEIGHT;
|
||||||
|
}
|
||||||
|
///底部操作栏的高度
|
||||||
|
rowHeight += kMONENTS_TOOL_BAR_HEIGHT;
|
||||||
|
monents.rowHeight = rowHeight;
|
||||||
|
}
|
||||||
|
+ (void)layoutSimpleMonentsModel:(MonentsInfoModel *)monents {
|
||||||
|
CGFloat rowHeight = kMONENTS_CONTENT_SPACAE_HEIGHT;
|
||||||
|
///文字内容的高度
|
||||||
|
rowHeight += [self simpleMonentsContentHeight:monents];
|
||||||
|
///图片的高度
|
||||||
|
rowHeight += [self monentsPicHeight:monents];
|
||||||
|
///如果没有图片的话 间隙就只有一个
|
||||||
|
if (monents.type == MonentsContentType_Picture && monents.content.length > 0) {
|
||||||
|
rowHeight += (kMONENTS_CONTENT_SPACAE_HEIGHT * 2);
|
||||||
|
}else {
|
||||||
|
rowHeight += kMONENTS_CONTENT_SPACAE_HEIGHT;
|
||||||
|
}
|
||||||
|
///话题的高度
|
||||||
|
rowHeight += kMONENTS_TEXT_TOPIC_HEIGHT;
|
||||||
|
monents.rowHeight = rowHeight;
|
||||||
|
}
|
||||||
|
|
||||||
|
+ (CGFloat)simpleMonentsContentHeight:(MonentsInfoModel *)monents {
|
||||||
|
if (monents.content.length <= 0) {
|
||||||
|
monents.contentHeight = 0;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
///计算文本的高度
|
||||||
|
if (!monents.contentAttribute) {
|
||||||
|
NSMutableAttributedString *attributedString = [[NSMutableAttributedString alloc] init];
|
||||||
|
if (monents.squareTop ) {//动态/广场
|
||||||
|
NSTextAttachment * attachment = [[NSTextAttachment alloc] init];
|
||||||
|
attachment.bounds = CGRectMake(0, 0, 25 * 1.3 ,10 * 1.3);
|
||||||
|
attachment.image = [UIImage imageNamed:@"monents_info_top"];
|
||||||
|
NSAttributedString * starAttribute = [NSMutableAttributedString attributedStringWithAttachment:(NSTextAttachment *)attachment];
|
||||||
|
[attributedString insertAttributedString:starAttribute atIndex:0];
|
||||||
|
}
|
||||||
|
[attributedString appendAttributedString:[self creatStrAttrByStr:monents.content attributed:@{NSFontAttributeName : [UIFont systemFontOfSize:15]}]];
|
||||||
|
attributedString.yy_lineSpacing = 5;
|
||||||
|
attributedString.yy_lineBreakMode = NSLineBreakByWordWrapping;
|
||||||
|
monents.contentAttribute = attributedString;
|
||||||
|
}
|
||||||
|
|
||||||
|
YYTextContainer *container = [YYTextContainer new];
|
||||||
|
container.size = CGSizeMake(kSIMPLE_MONENTS_CONTENT_MAX_WIDTH, CGFLOAT_MAX);
|
||||||
|
container.maximumNumberOfRows = 0;
|
||||||
|
YYTextLayout *layout = [YYTextLayout layoutWithContainer:container text:monents.contentAttribute];
|
||||||
|
monents.numberOfText = layout.rowCount;
|
||||||
|
CGFloat foldHeight = 0;
|
||||||
|
if (layout.rowCount > 6) {
|
||||||
|
foldHeight = kMONENTS_FOLD_HEIGHT;
|
||||||
|
NSInteger numberOfLines = monents.isFold ? 6 : 0;
|
||||||
|
container.maximumNumberOfRows = numberOfLines;
|
||||||
|
}
|
||||||
|
YYTextLayout *realLayout = [YYTextLayout layoutWithContainer:container text:monents.contentAttribute];
|
||||||
|
CGFloat contentHeight = realLayout.textBoundingSize.height;
|
||||||
|
monents.contentHeight =contentHeight;
|
||||||
|
return contentHeight + foldHeight;
|
||||||
|
}
|
||||||
|
|
||||||
|
+ (CGFloat)simpleMonentsPicHeight:(MonentsInfoModel *)monents {
|
||||||
|
///计算图片的高度
|
||||||
|
NSInteger picCount = monents.dynamicResList.count;
|
||||||
|
CGFloat picHeight = 0;
|
||||||
|
if (picCount == 0) {
|
||||||
|
picHeight = 0;
|
||||||
|
} else if(picCount == 1) {
|
||||||
|
picHeight = kMONENTS_PIC_ONE_WIDTH;
|
||||||
|
} else if(picCount == 2) {
|
||||||
|
picHeight = (kSIMPLE_MONENTS_CONTENT_MAX_WIDTH - kMONENTS_PIC_SPACE) / 2;
|
||||||
|
} else {
|
||||||
|
if (picCount > 9) {
|
||||||
|
picCount = 9;
|
||||||
|
}
|
||||||
|
CGFloat itemWidth = (kSIMPLE_MONENTS_CONTENT_MAX_WIDTH - kMONENTS_PIC_SPACE * 2) / 3;
|
||||||
|
NSInteger page = picCount % 3;
|
||||||
|
NSInteger line = picCount / 3;
|
||||||
|
if (page == 0) {
|
||||||
|
picHeight = itemWidth * line + (line -1)* kMONENTS_PIC_SPACE;
|
||||||
|
} else {
|
||||||
|
picHeight = itemWidth * (line +1) + line * kMONENTS_PIC_SPACE;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
monents.picHeight = picHeight;
|
||||||
|
return picHeight;
|
||||||
|
}
|
||||||
|
|
||||||
|
#pragma mark - 正常的布局
|
||||||
|
|
||||||
|
+ (void)layoutMonentsModel:(MonentsInfoModel *)monents {
|
||||||
|
CGFloat rowHeight = kMONENTS_USER_INFO_HEIGHT;
|
||||||
|
///用户信息和文字之间的间隙
|
||||||
|
rowHeight += kMONENTS_CONTENT_SPACAE_HEIGHT;
|
||||||
|
///文字内容的高度
|
||||||
|
rowHeight += [self monentsContentHeight:monents];
|
||||||
|
///图片的高度
|
||||||
|
rowHeight += [self monentsPicHeight:monents];
|
||||||
|
///如果没有图片的话 间隙就只有一个
|
||||||
|
if (monents.type == MonentsContentType_Picture && monents.content.length > 0) {
|
||||||
|
rowHeight += (kMONENTS_CONTENT_SPACAE_HEIGHT * 2);
|
||||||
|
}else {
|
||||||
|
rowHeight += kMONENTS_CONTENT_SPACAE_HEIGHT;
|
||||||
|
}
|
||||||
|
///话题的高度
|
||||||
|
rowHeight += kMONENTS_TEXT_TOPIC_HEIGHT;
|
||||||
|
///底部操作栏的高度
|
||||||
|
rowHeight += kMONENTS_TOOL_BAR_HEIGHT;
|
||||||
|
monents.rowHeight = rowHeight;
|
||||||
|
}
|
||||||
|
|
||||||
+ (CGFloat)monentsPicHeight:(MonentsInfoModel *)monents {
|
+ (CGFloat)monentsPicHeight:(MonentsInfoModel *)monents {
|
||||||
///计算图片的高度
|
///计算图片的高度
|
||||||
NSInteger picCount = monents.dynamicResList.count;
|
NSInteger picCount = monents.dynamicResList.count;
|
||||||
@@ -144,12 +225,10 @@
|
|||||||
NSMutableAttributedString *attributedString = [[NSMutableAttributedString alloc] init];
|
NSMutableAttributedString *attributedString = [[NSMutableAttributedString alloc] init];
|
||||||
if (monents.squareTop ) {//动态/广场
|
if (monents.squareTop ) {//动态/广场
|
||||||
NSTextAttachment * attachment = [[NSTextAttachment alloc] init];
|
NSTextAttachment * attachment = [[NSTextAttachment alloc] init];
|
||||||
attachment.bounds = CGRectMake(0, 0, 10, 12);
|
attachment.bounds = CGRectMake(0, 0, 25 * 1.3 ,10 * 1.3);
|
||||||
attachment.image = [UIImage imageNamed:@"monents_info_top"];
|
attachment.image = [UIImage imageNamed:@"monents_info_top"];
|
||||||
NSAttributedString * starAttribute = [NSMutableAttributedString attributedStringWithAttachment:(NSTextAttachment *)attachment];
|
NSAttributedString * starAttribute = [NSMutableAttributedString attributedStringWithAttachment:(NSTextAttachment *)attachment];
|
||||||
[attributedString insertAttributedString:starAttribute atIndex:0];
|
[attributedString insertAttributedString:starAttribute atIndex:0];
|
||||||
//将图片插入到合适的位置
|
|
||||||
[attributedString appendAttributedString:[self creatStrAttrByStr:YMLocalizedString(@"XPMonentsLayoutConfig0") attributed:@{NSFontAttributeName : [UIFont systemFontOfSize:15], NSForegroundColorAttributeName: UIColorFromRGB(0xE84C46)}]];
|
|
||||||
}
|
}
|
||||||
[attributedString appendAttributedString:[self creatStrAttrByStr:monents.content attributed:@{NSFontAttributeName : [UIFont systemFontOfSize:15]}]];
|
[attributedString appendAttributedString:[self creatStrAttrByStr:monents.content attributed:@{NSFontAttributeName : [UIFont systemFontOfSize:15]}]];
|
||||||
attributedString.yy_lineSpacing = 5;
|
attributedString.yy_lineSpacing = 5;
|
||||||
@@ -164,13 +243,13 @@
|
|||||||
monents.numberOfText = layout.rowCount;
|
monents.numberOfText = layout.rowCount;
|
||||||
CGFloat foldHeight = 0;
|
CGFloat foldHeight = 0;
|
||||||
if (layout.rowCount > 6) {
|
if (layout.rowCount > 6) {
|
||||||
foldHeight = kMONENTS_FOLD_HEIGHT + kMONENTS_Content_Text_Space;
|
foldHeight = kMONENTS_FOLD_HEIGHT;
|
||||||
NSInteger numberOfLines = monents.isFold ? 6 : 0;
|
NSInteger numberOfLines = monents.isFold ? 6 : 0;
|
||||||
container.maximumNumberOfRows = numberOfLines;
|
container.maximumNumberOfRows = numberOfLines;
|
||||||
}
|
}
|
||||||
YYTextLayout *realLayout = [YYTextLayout layoutWithContainer:container text:monents.contentAttribute];
|
YYTextLayout *realLayout = [YYTextLayout layoutWithContainer:container text:monents.contentAttribute];
|
||||||
CGFloat contentHeight = realLayout.textBoundingSize.height ;
|
CGFloat contentHeight = realLayout.textBoundingSize.height;
|
||||||
monents.contentHeight = contentHeight + kMONENTS_Time_HEIGHT + kMONENTS_Content_Text_Space;
|
monents.contentHeight =contentHeight;
|
||||||
return contentHeight + foldHeight;
|
return contentHeight + foldHeight;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -15,6 +15,8 @@ NS_ASSUME_NONNULL_BEGIN
|
|||||||
|
|
||||||
///删除话题成功
|
///删除话题成功
|
||||||
- (void)deleteMonentsSuccess:(NSString *)monentsInfo;
|
- (void)deleteMonentsSuccess:(NSString *)monentsInfo;
|
||||||
|
///屏蔽
|
||||||
|
- (void)requesstShieldingSuccess:(NSString *)monentsInfo;
|
||||||
@end
|
@end
|
||||||
|
|
||||||
NS_ASSUME_NONNULL_END
|
NS_ASSUME_NONNULL_END
|
||||||
|
@@ -1,8 +1,8 @@
|
|||||||
//
|
//
|
||||||
// YMMonentsTableViewCell.h
|
// XPMonentsTableViewCell.h
|
||||||
// YUMI
|
// xplan-ios
|
||||||
//
|
//
|
||||||
// Created by YUMI on 2022/5/11.
|
// Created by 冯硕 on 2022/5/11.
|
||||||
//
|
//
|
||||||
|
|
||||||
#import <UIKit/UIKit.h>
|
#import <UIKit/UIKit.h>
|
||||||
@@ -20,12 +20,20 @@ NS_ASSUME_NONNULL_BEGIN
|
|||||||
- (void)xPMonentsTableViewCell:(XPMonentsTableViewCell *)view didClicCommon:(MonentsInfoModel *)monentsInfo;
|
- (void)xPMonentsTableViewCell:(XPMonentsTableViewCell *)view didClicCommon:(MonentsInfoModel *)monentsInfo;
|
||||||
///点击了展开
|
///点击了展开
|
||||||
- (void)xPMonentsTableViewCell:(XPMonentsTableViewCell *)view didClicFold:(MonentsInfoModel *)monentsInfo;
|
- (void)xPMonentsTableViewCell:(XPMonentsTableViewCell *)view didClicFold:(MonentsInfoModel *)monentsInfo;
|
||||||
|
///屏蔽
|
||||||
|
- (void)xPMonentsTableViewCell:(XPMonentsTableViewCell *)view didClicShielding:(MonentsInfoModel *)monentsInfo;
|
||||||
|
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
@interface XPMonentsTableViewCell : UITableViewCell
|
@interface XPMonentsTableViewCell : UITableViewCell
|
||||||
|
@property (nonatomic,strong) MonentsInfoModel *mineMonentsInfo;
|
||||||
@property (nonatomic,strong) MonentsInfoModel *monentsInfo;
|
@property (nonatomic,strong) MonentsInfoModel *monentsInfo;
|
||||||
|
@property (nonatomic,assign) BOOL isFillet;
|
||||||
///代理
|
///代理
|
||||||
@property (nonatomic,weak) id<XPMonentsTableViewCellDelegate> delegate;
|
@property (nonatomic,weak) id<XPMonentsTableViewCellDelegate> delegate;
|
||||||
|
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
NS_ASSUME_NONNULL_END
|
NS_ASSUME_NONNULL_END
|
||||||
|
@@ -1,8 +1,8 @@
|
|||||||
//
|
//
|
||||||
// YMMonentsTableViewCell.m
|
// XPMonentsTableViewCell.m
|
||||||
// YUMI
|
// xplan-ios
|
||||||
//
|
//
|
||||||
// Created by YUMI on 2022/5/11.
|
// Created by 冯硕 on 2022/5/11.
|
||||||
//
|
//
|
||||||
|
|
||||||
#import "XPMonentsTableViewCell.h"
|
#import "XPMonentsTableViewCell.h"
|
||||||
@@ -10,13 +10,11 @@
|
|||||||
#import <Masonry/Masonry.h>
|
#import <Masonry/Masonry.h>
|
||||||
|
|
||||||
///Tool
|
///Tool
|
||||||
#import "DJDKMIMOMColor.h"
|
|
||||||
#import "NetImageView.h"
|
#import "NetImageView.h"
|
||||||
#import "XPMonentsLayoutConfig.h"
|
#import "XPMonentsLayoutConfig.h"
|
||||||
#import "SDPhotoBrowser.h"
|
#import "SDPhotoBrowser.h"
|
||||||
#import "XCCurrentVCStackManager.h"
|
#import "XCCurrentVCStackManager.h"
|
||||||
#import "NSArray+Safe.h"
|
|
||||||
#import "ClientConfig.h"
|
|
||||||
///Model
|
///Model
|
||||||
#import "MonentsInfoModel.h"
|
#import "MonentsInfoModel.h"
|
||||||
///View
|
///View
|
||||||
@@ -28,7 +26,6 @@
|
|||||||
#import "XPMonentsLayoutConfig.h"
|
#import "XPMonentsLayoutConfig.h"
|
||||||
#import "XPMonentTopicContainerViewController.h"
|
#import "XPMonentTopicContainerViewController.h"
|
||||||
#import "XPMineUserInfoViewController.h"
|
#import "XPMineUserInfoViewController.h"
|
||||||
#import "XPMineSimpleUserInfoViewController.h"
|
|
||||||
#import "XPRoomViewController.h"
|
#import "XPRoomViewController.h"
|
||||||
@interface XPMonentsTableViewCell ()<XPMonentsTooBarViewDelegate, XPMonentsTooBarViewDelegate, XPMonentsPhotoViewDelegate, SDPhotoBrowserDelegate, XPMonentsUserInfoViewDelegate, XPMonentsContentViewDelegate>
|
@interface XPMonentsTableViewCell ()<XPMonentsTooBarViewDelegate, XPMonentsTooBarViewDelegate, XPMonentsPhotoViewDelegate, SDPhotoBrowserDelegate, XPMonentsUserInfoViewDelegate, XPMonentsContentViewDelegate>
|
||||||
///显示颜色的 有的时候stackView 不能显示颜色
|
///显示颜色的 有的时候stackView 不能显示颜色
|
||||||
@@ -45,271 +42,374 @@
|
|||||||
@property (nonatomic,strong) XPMonentsTooBarView *toolBarView;
|
@property (nonatomic,strong) XPMonentsTooBarView *toolBarView;
|
||||||
///话题
|
///话题
|
||||||
@property (nonatomic,strong) XPMoentsTopicView *topicView;
|
@property (nonatomic,strong) XPMoentsTopicView *topicView;
|
||||||
|
@property (nonatomic,strong) UIView *lineView;
|
||||||
/// 复用标识,用来区分是审核UI还是正常UI
|
|
||||||
@property (nonatomic,strong) NSString *identifier;
|
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
@implementation XPMonentsTableViewCell
|
@implementation XPMonentsTableViewCell
|
||||||
|
|
||||||
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
|
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
|
||||||
if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
|
if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
|
||||||
[self initSubViews];
|
if ([reuseIdentifier isEqualToString:@"XPMonentsDynamicTableViewCell"]) {
|
||||||
[self initSubViewConstraints];
|
[self initDynamicSubViews];
|
||||||
}
|
[self initDynamicSubViewConstraints];
|
||||||
return self;
|
|
||||||
|
}else{
|
||||||
|
[self initSubViews];
|
||||||
|
[self initSubViewConstraints];
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
return self;
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - Private Method
|
#pragma mark - Private Method
|
||||||
- (void)initSubViews {
|
|
||||||
self.backgroundColor = [UIColor clearColor];
|
- (void)initDynamicSubViews {
|
||||||
self.selectionStyle = UITableViewCellSelectionStyleNone;
|
self.backgroundColor = [UIColor clearColor];
|
||||||
[self.contentView addSubview:self.backView];
|
self.selectionStyle = UITableViewCellSelectionStyleNone;
|
||||||
|
[self.contentView addSubview:self.backView];
|
||||||
|
|
||||||
/// 正常UI
|
|
||||||
if ([self.reuseIdentifier isEqualToString:NSStringFromClass([XPMonentsTableViewCell class])]){
|
[self.backView addSubview:self.stackView];
|
||||||
[self.backView addSubview:self.userInfoView];
|
[self.backView addSubview:self.toolBarView];
|
||||||
[self.backView addSubview:self.stackView];
|
|
||||||
[self.backView addSubview:self.toolBarView];
|
[self.stackView addArrangedSubview:self.textView];
|
||||||
|
[self.stackView addArrangedSubview:self.photoView];
|
||||||
[self.stackView addArrangedSubview:self.textView];
|
[self.stackView addArrangedSubview:self.topicView];
|
||||||
[self.stackView addArrangedSubview:self.photoView];
|
|
||||||
[self.stackView addArrangedSubview:self.topicView];
|
[self.contentView addSubview:self.lineView];
|
||||||
}else{
|
}
|
||||||
/// 审核UI
|
|
||||||
[self.backView addSubview:self.stackView];
|
- (void)initDynamicSubViewConstraints {
|
||||||
|
[self.backView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
[self.stackView addArrangedSubview:self.textView];
|
make.left.mas_equalTo(15);
|
||||||
[self.stackView addArrangedSubview:self.photoView];
|
make.right.mas_equalTo(-15);
|
||||||
[self.stackView addArrangedSubview:self.topicView];
|
make.top.bottom.equalTo(self.contentView);
|
||||||
}
|
}];
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
[self.textView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.height.mas_equalTo(20);
|
||||||
|
}];
|
||||||
|
|
||||||
|
[self.stackView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.left.mas_equalTo(self.backView).offset(12);
|
||||||
|
make.right.mas_equalTo(self.backView).offset(-12);
|
||||||
|
make.top.mas_equalTo(13);
|
||||||
|
}];
|
||||||
|
|
||||||
|
[self.topicView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.height.mas_equalTo(kMONENTS_TEXT_TOPIC_HEIGHT);
|
||||||
|
}];
|
||||||
|
[self.photoView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.width.mas_equalTo(KScreenWidth-30);
|
||||||
|
}];
|
||||||
|
[self.toolBarView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.left.right.mas_equalTo(self.backView);
|
||||||
|
make.top.mas_equalTo(self.stackView.mas_bottom).mas_offset(10);
|
||||||
|
make.height.mas_equalTo(18);
|
||||||
|
}];
|
||||||
|
|
||||||
|
[self.lineView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.height.mas_equalTo(kGetScaleWidth(1));
|
||||||
|
make.left.right.equalTo(self.toolBarView).inset(12);
|
||||||
|
make.bottom.equalTo(self.contentView);
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
|
||||||
|
- (void)initSubViews {
|
||||||
|
self.backgroundColor = [UIColor clearColor];
|
||||||
|
self.selectionStyle = UITableViewCellSelectionStyleNone;
|
||||||
|
[self.contentView addSubview:self.backView];
|
||||||
|
|
||||||
|
[self.backView addSubview:self.userInfoView];
|
||||||
|
[self.backView addSubview:self.stackView];
|
||||||
|
[self.backView addSubview:self.toolBarView];
|
||||||
|
|
||||||
|
[self.stackView addArrangedSubview:self.textView];
|
||||||
|
[self.stackView addArrangedSubview:self.photoView];
|
||||||
|
[self.stackView addArrangedSubview:self.topicView];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)initSubViewConstraints {
|
- (void)initSubViewConstraints {
|
||||||
/// 正常UI
|
[self.backView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
if ([self.reuseIdentifier isEqualToString:NSStringFromClass([XPMonentsTableViewCell class])]){
|
make.edges.mas_equalTo(self.contentView);
|
||||||
[self.backView mas_makeConstraints:^(MASConstraintMaker *make) {
|
}];
|
||||||
make.edges.mas_equalTo(self.contentView);
|
|
||||||
}];
|
[self.userInfoView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.left.right.top.mas_equalTo(self.backView);
|
||||||
[self.userInfoView mas_makeConstraints:^(MASConstraintMaker *make) {
|
make.height.mas_equalTo(kMONENTS_USER_INFO_HEIGHT);
|
||||||
make.left.right.top.mas_equalTo(self.backView);
|
}];
|
||||||
make.height.mas_equalTo(kMONENTS_USER_INFO_HEIGHT);
|
|
||||||
}];
|
[self.textView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.height.mas_equalTo(20);
|
||||||
[self.textView mas_makeConstraints:^(MASConstraintMaker *make) {
|
}];
|
||||||
make.height.mas_equalTo(20);
|
|
||||||
}];
|
[self.stackView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.left.mas_equalTo(self.backView).offset(kMONENTS_CONTENT_LEFT_PADDING);
|
||||||
[self.stackView mas_makeConstraints:^(MASConstraintMaker *make) {
|
make.right.mas_equalTo(self.backView).offset(-kMONENTS_CONTENT_RIGHT_PADDING);
|
||||||
make.left.mas_equalTo(self.backView).offset(kMONENTS_CONTENT_LEFT_PADDING);
|
make.top.mas_equalTo(self.userInfoView.mas_bottom).offset(kMONENTS_CONTENT_SPACAE_HEIGHT);
|
||||||
make.right.mas_equalTo(self.backView).offset(-kMONENTS_CONTENT_RIGHT_PADDING);
|
}];
|
||||||
make.top.mas_equalTo(self.userInfoView.mas_bottom).offset(kMONENTS_CONTENT_SPACAE_HEIGHT);
|
|
||||||
}];
|
[self.topicView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.height.mas_equalTo(kMONENTS_TEXT_TOPIC_HEIGHT);
|
||||||
[self.topicView mas_makeConstraints:^(MASConstraintMaker *make) {
|
}];
|
||||||
make.height.mas_equalTo(kMONENTS_TEXT_TOPIC_HEIGHT);
|
|
||||||
}];
|
[self.toolBarView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.left.right.mas_equalTo(self.backView);
|
||||||
[self.toolBarView mas_makeConstraints:^(MASConstraintMaker *make) {
|
make.top.mas_equalTo(self.stackView.mas_bottom);
|
||||||
make.left.right.mas_equalTo(self.backView);
|
make.height.mas_equalTo(kMONENTS_TOOL_BAR_HEIGHT);
|
||||||
make.top.mas_equalTo(self.stackView.mas_bottom);
|
}];
|
||||||
make.height.mas_equalTo(kMONENTS_TOOL_BAR_HEIGHT);
|
|
||||||
}];
|
|
||||||
}else{
|
|
||||||
[self.backView mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.edges.mas_equalTo(self.contentView);
|
|
||||||
}];
|
|
||||||
// 审核UI
|
|
||||||
[self.textView mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.height.mas_equalTo(20);
|
|
||||||
}];
|
|
||||||
|
|
||||||
[self.stackView mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.left.mas_equalTo(self.backView).offset(12);
|
|
||||||
make.right.mas_equalTo(self.backView).offset(-12);
|
|
||||||
make.top.mas_equalTo(self.backView.mas_top).offset(kMONENTS_CONTENT_SPACAE_HEIGHT);
|
|
||||||
}];
|
|
||||||
|
|
||||||
[self.topicView mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.height.mas_equalTo(kMONENTS_TEXT_TOPIC_HEIGHT);
|
|
||||||
}];
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
#pragma mark - XPMonentsUserInfoViewDelegate
|
#pragma mark - XPMonentsUserInfoViewDelegate
|
||||||
- (void)xPMonentsUserInfoView:(XPMonentsUserInfoView *)view didClickEnterRoom:(MonentsInfoModel *)monents {
|
- (void)xPMonentsUserInfoView:(XPMonentsUserInfoView *)view didClickEnterRoom:(MonentsInfoModel *)monents {
|
||||||
if (monents.inRoomUid.integerValue > 0) {
|
if (monents.inRoomUid.integerValue > 0) {
|
||||||
[XPRoomViewController openRoom:monents.inRoomUid viewController:[XCCurrentVCStackManager shareManager].getCurrentVC];
|
[XPRoomViewController openRoom:monents.inRoomUid viewController:[XCCurrentVCStackManager shareManager].getCurrentVC];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)xPMonentsUserInfoView:(XPMonentsUserInfoView *)view didClickAvatar:(MonentsInfoModel *)monents {
|
- (void)xPMonentsUserInfoView:(XPMonentsUserInfoView *)view didClickAvatar:(MonentsInfoModel *)monents {
|
||||||
if ([ClientConfig shareConfig].canOpen) {
|
XPMineUserInfoViewController * userInfoVC = [[XPMineUserInfoViewController alloc] init];
|
||||||
XPMineUserInfoViewController * userInfoVC = [[XPMineUserInfoViewController alloc] init];
|
userInfoVC.uid = monents.uid.integerValue;
|
||||||
userInfoVC.uid = monents.uid.integerValue;
|
[[XCCurrentVCStackManager shareManager].getCurrentVC.navigationController pushViewController:userInfoVC animated:YES];
|
||||||
[[XCCurrentVCStackManager shareManager].getCurrentVC.navigationController pushViewController:userInfoVC animated:YES];
|
}
|
||||||
}else{
|
|
||||||
XPMineSimpleUserInfoViewController * userInfoVC = [[XPMineSimpleUserInfoViewController alloc] init];
|
- (void)xPMonentsTooBarView:(XPMonentsUserInfoView *)view didClickDelete:(MonentsInfoModel *)monentsInfo {
|
||||||
userInfoVC.uid = monents.uid.integerValue;
|
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTableViewCell:didClicDelete:)]) {
|
||||||
[[XCCurrentVCStackManager shareManager].getCurrentVC.navigationController pushViewController:userInfoVC animated:YES];
|
[self.delegate xPMonentsTableViewCell:self didClicDelete:monentsInfo];
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - XPMonentsTooBarViewDelegate
|
#pragma mark - XPMonentsTooBarViewDelegate
|
||||||
- (void)xPMonentsTooBarView:(XPMonentsTooBarView *)view didClickLike:(MonentsInfoModel *)monentsInfo {
|
- (void)xPMonentsTooBarView:(XPMonentsTooBarView *)view didClickLike:(MonentsInfoModel *)monentsInfo {
|
||||||
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTableViewCell:didClickLike:)]) {
|
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTableViewCell:didClickLike:)]) {
|
||||||
[self.delegate xPMonentsTableViewCell:self didClickLike:monentsInfo];
|
[self.delegate xPMonentsTableViewCell:self didClickLike:monentsInfo];
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
- (void)xPMonentsTooBarView:(XPMonentsTooBarView *)view didClickDelete:(MonentsInfoModel *)monentsInfo {
|
|
||||||
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTableViewCell:didClicDelete:)]) {
|
|
||||||
[self.delegate xPMonentsTableViewCell:self didClicDelete:self.monentsInfo];
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)xPMonentsTooBarView:(XPMonentsTooBarView *)view didClickCommon:(MonentsInfoModel *)monentsInfo {
|
- (void)xPMonentsTooBarView:(XPMonentsTooBarView *)view didClickCommon:(MonentsInfoModel *)monentsInfo {
|
||||||
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTableViewCell:didClicCommon:)]) {
|
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTableViewCell:didClicCommon:)]) {
|
||||||
[self.delegate xPMonentsTableViewCell:self didClicCommon:self.monentsInfo];
|
[self.delegate xPMonentsTableViewCell:self didClicCommon:monentsInfo];
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
- (void)xPMonentsTooBarView:(XPMonentsTooBarView *)view didClickShielding:(MonentsInfoModel *)monentsInfo{
|
||||||
|
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTableViewCell:didClicShielding:)]) {
|
||||||
|
[self.delegate xPMonentsTableViewCell:self didClicShielding:monentsInfo];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - XPMonentsContentViewDelegate
|
#pragma mark - XPMonentsContentViewDelegate
|
||||||
- (void)xPMonentsContentView:(XPMonentsContentView *)view didClickFold:(MonentsInfoModel *)monentsInfo {
|
- (void)xPMonentsContentView:(XPMonentsContentView *)view didClickFold:(MonentsInfoModel *)monentsInfo {
|
||||||
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTableViewCell:didClicFold:)]) {
|
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTableViewCell:didClicFold:)]) {
|
||||||
[self.delegate xPMonentsTableViewCell:self didClicFold:monentsInfo];
|
[self.delegate xPMonentsTableViewCell:self didClicFold:monentsInfo];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - SDPhotoBrowserDelegate
|
#pragma mark - SDPhotoBrowserDelegate
|
||||||
- (NSURL *)photoBrowser:(SDPhotoBrowser *)browser highQualityImageURLForIndex:(NSInteger)index {
|
- (NSURL *)photoBrowser:(SDPhotoBrowser *)browser highQualityImageURLForIndex:(NSInteger)index {
|
||||||
MonentsPicInfoModel *picinfo = [self.monentsInfo.dynamicResList safeObjectAtIndex1:index];
|
|
||||||
return [NSURL URLWithString:picinfo.resUrl];
|
NSArray *list = self.monentsInfo != nil ? self.monentsInfo.dynamicResList : self.mineMonentsInfo.dynamicResList;
|
||||||
|
if(index < list.count){
|
||||||
|
MonentsPicInfoModel *picinfo = [list safeObjectAtIndex1:index];
|
||||||
|
return [NSURL URLWithString:picinfo.resUrl];
|
||||||
|
}
|
||||||
|
return [NSURL URLWithString:@""];;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (UIImage *)photoBrowser:(SDPhotoBrowser *)browser placeholderImageForIndex:(NSInteger)index {
|
- (UIImage *)photoBrowser:(SDPhotoBrowser *)browser placeholderImageForIndex:(NSInteger)index {
|
||||||
return [UIImageConstant defalutBannerPlaceholder];
|
return [UIImageConstant defalutBannerPlaceholder];
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - XPMonentsPhotoViewDelegate
|
#pragma mark - XPMonentsPhotoViewDelegate
|
||||||
- (void)xPMonentsPhotoView:(XPMonentsPhotoView *)view didClickImage:(NSInteger)index {
|
- (void)xPMonentsPhotoView:(XPMonentsPhotoView *)view didClickImage:(NSInteger)index {
|
||||||
NSInteger count = self.monentsInfo.dynamicResList.count;
|
NSInteger count = self.monentsInfo != nil ? self.monentsInfo.dynamicResList.count : self.mineMonentsInfo.dynamicResList.count;
|
||||||
SDPhotoBrowser *browser = [[SDPhotoBrowser alloc]init];
|
SDPhotoBrowser *browser = [[SDPhotoBrowser alloc]init];
|
||||||
browser.sourceImagesContainerView = self;
|
browser.sourceImagesContainerView = self;
|
||||||
browser.delegate = self;
|
browser.delegate = self;
|
||||||
browser.imageCount = count;
|
browser.imageCount = count;
|
||||||
browser.currentImageIndex = index;
|
browser.currentImageIndex = index;
|
||||||
browser.isMe = NO;
|
browser.isMe = NO;
|
||||||
[browser show];
|
[browser show];
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - Event Response
|
#pragma mark - Event Response
|
||||||
- (void)didTapTopicRecognizer {
|
- (void)didTapTopicRecognizer {
|
||||||
if (self.monentsInfo.worldId > 0) {
|
long worldId = self.monentsInfo != nil ? self.monentsInfo.worldId : self.mineMonentsInfo.worldId;
|
||||||
XPMonentTopicContainerViewController * topicListVC = [[XPMonentTopicContainerViewController alloc] init];
|
if (worldId > 0) {
|
||||||
topicListVC.worldId = [NSString stringWithFormat:@"%ld", self.monentsInfo.worldId];
|
XPMonentTopicContainerViewController * topicListVC = [[XPMonentTopicContainerViewController alloc] init];
|
||||||
[[XCCurrentVCStackManager shareManager].getCurrentVC.navigationController pushViewController:topicListVC animated:YES];
|
topicListVC.worldId = [NSString stringWithFormat:@"%ld", worldId];
|
||||||
}
|
[[XCCurrentVCStackManager shareManager].getCurrentVC.navigationController pushViewController:topicListVC animated:YES];
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - Getters And Setters
|
#pragma mark - Getters And Setters
|
||||||
- (void)setMonentsInfo:(MonentsInfoModel *)monentsInfo {
|
- (void)setIsFillet:(BOOL)isFillet{
|
||||||
_monentsInfo = monentsInfo;
|
_isFillet = isFillet;
|
||||||
if (_monentsInfo) {
|
|
||||||
self.userInfoView.monentsInfo = _monentsInfo;
|
|
||||||
self.textView.monentsInfo = _monentsInfo;
|
|
||||||
self.photoView.dynamicResList = _monentsInfo.dynamicResList;
|
|
||||||
self.topicView.monentsInfo = _monentsInfo;
|
|
||||||
self.toolBarView.monentsInfo = _monentsInfo;
|
|
||||||
if (_monentsInfo.type == MonentsContentType_Picture) {
|
|
||||||
self.photoView.hidden = NO;
|
|
||||||
CGFloat picHeight = _monentsInfo.picHeight <=0 ? [XPMonentsLayoutConfig monentsPicHeight:_monentsInfo] : _monentsInfo.picHeight;
|
|
||||||
[self.photoView mas_updateConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.height.mas_equalTo(picHeight);
|
|
||||||
}];
|
|
||||||
} else {
|
|
||||||
self.photoView.hidden = YES;
|
|
||||||
[self.photoView mas_updateConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.height.mas_equalTo(0);
|
|
||||||
}];
|
|
||||||
}
|
|
||||||
|
|
||||||
CGFloat contentHeight = [XPMonentsLayoutConfig monentsContentHeight:_monentsInfo];
|
if(_isFillet == YES){
|
||||||
[self.textView mas_updateConstraints:^(MASConstraintMaker *make) {
|
_lineView.hidden = YES;
|
||||||
make.height.mas_equalTo(contentHeight);
|
[_backView setCornerWithLeftTopCorner:0 rightTopCorner:0 bottomLeftCorner:8 bottomRightCorner:8 size:CGSizeMake(KScreenWidth-30, self.frame.size.height)];
|
||||||
}];
|
}else{
|
||||||
}
|
_lineView.hidden = NO;
|
||||||
|
if(_backView.layer.mask != nil){
|
||||||
|
_backView.layer.mask = nil;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
-(void)setMineMonentsInfo:(MonentsInfoModel *)mineMonentsInfo{
|
||||||
|
_mineMonentsInfo = mineMonentsInfo;
|
||||||
|
if (_mineMonentsInfo) {
|
||||||
|
self.userInfoView.monentsInfo = _mineMonentsInfo;
|
||||||
|
self.textView.monentsInfo = _mineMonentsInfo;
|
||||||
|
self.photoView.mineDynamicResList = _mineMonentsInfo.dynamicResList;
|
||||||
|
self.topicView.monentsInfo = _mineMonentsInfo;
|
||||||
|
self.toolBarView.monentsInfo = _mineMonentsInfo;
|
||||||
|
if (_mineMonentsInfo.type == MonentsContentType_Picture) {
|
||||||
|
self.photoView.hidden = NO;
|
||||||
|
CGFloat picHeight = _mineMonentsInfo.picHeight <=0 ? [XPMonentsLayoutConfig monentsPicHeight:_mineMonentsInfo] : _mineMonentsInfo.picHeight;
|
||||||
|
[self.photoView mas_updateConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.height.mas_equalTo(picHeight);
|
||||||
|
}];
|
||||||
|
} else {
|
||||||
|
self.photoView.hidden = YES;
|
||||||
|
[self.photoView mas_updateConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.height.mas_equalTo(0);
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
|
||||||
|
CGFloat contentHeight = [XPMonentsLayoutConfig monentsContentHeight:_mineMonentsInfo] + 24;
|
||||||
|
|
||||||
|
self.topicView.hidden = _mineMonentsInfo.worldId <= 0;
|
||||||
|
|
||||||
|
if(_mineMonentsInfo.squareTop && _mineMonentsInfo.content.length == 0){
|
||||||
|
[self.textView mas_updateConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.height.mas_equalTo(contentHeight + 20);
|
||||||
|
}];
|
||||||
|
}else{
|
||||||
|
[self.textView mas_updateConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.height.mas_equalTo(contentHeight);
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
- (void)setMonentsInfo:(MonentsInfoModel *)monentsInfo {
|
||||||
|
_monentsInfo = monentsInfo;
|
||||||
|
if (_monentsInfo) {
|
||||||
|
self.userInfoView.monentsInfo = _monentsInfo;
|
||||||
|
self.textView.monentsInfo = _monentsInfo;
|
||||||
|
self.photoView.dynamicResList = _monentsInfo.dynamicResList;
|
||||||
|
self.topicView.monentsInfo = _monentsInfo;
|
||||||
|
self.toolBarView.monentsInfo = _monentsInfo;
|
||||||
|
if (_monentsInfo.type == MonentsContentType_Picture) {
|
||||||
|
self.photoView.hidden = NO;
|
||||||
|
CGFloat picHeight = _monentsInfo.picHeight <=0 ? [XPMonentsLayoutConfig monentsPicHeight:_monentsInfo] : _monentsInfo.picHeight;
|
||||||
|
[self.photoView mas_updateConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.height.mas_equalTo(picHeight);
|
||||||
|
}];
|
||||||
|
} else {
|
||||||
|
self.photoView.hidden = YES;
|
||||||
|
[self.photoView mas_updateConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.height.mas_equalTo(0);
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
|
||||||
|
CGFloat contentHeight = [XPMonentsLayoutConfig monentsContentHeight:_monentsInfo] + 24;
|
||||||
|
|
||||||
|
self.topicView.hidden = monentsInfo.worldId <= 0;
|
||||||
|
|
||||||
|
if(_monentsInfo.squareTop && _monentsInfo.content.length == 0){
|
||||||
|
[self.textView mas_updateConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.height.mas_equalTo(contentHeight + 20);
|
||||||
|
}];
|
||||||
|
}else{
|
||||||
|
[self.textView mas_updateConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.height.mas_equalTo(contentHeight);
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
- (UIView *)backView {
|
- (UIView *)backView {
|
||||||
if (!_backView) {
|
if (!_backView) {
|
||||||
_backView = [[UIView alloc] init];
|
_backView = [[UIView alloc] init];
|
||||||
_backView.backgroundColor = [DJDKMIMOMColor appCellBackgroundColor];
|
_backView.backgroundColor = [DJDKMIMOMColor appCellBackgroundColor];
|
||||||
}
|
}
|
||||||
return _backView;
|
return _backView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (XPMonentsUserInfoView *)userInfoView {
|
- (XPMonentsUserInfoView *)userInfoView {
|
||||||
if (!_userInfoView) {
|
if (!_userInfoView) {
|
||||||
_userInfoView = [[XPMonentsUserInfoView alloc] init];
|
_userInfoView = [[XPMonentsUserInfoView alloc] init];
|
||||||
_userInfoView.delegate = self;
|
_userInfoView.delegate = self;
|
||||||
}
|
}
|
||||||
return _userInfoView;
|
return _userInfoView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (XPMonentsPhotoView *)photoView {
|
- (XPMonentsPhotoView *)photoView {
|
||||||
if (!_photoView) {
|
if (!_photoView) {
|
||||||
_photoView = [[XPMonentsPhotoView alloc] init];
|
_photoView = [[XPMonentsPhotoView alloc] init];
|
||||||
_photoView.delegate = self;
|
_photoView.delegate = self;
|
||||||
}
|
}
|
||||||
return _photoView;
|
return _photoView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (UIStackView *)stackView {
|
- (UIStackView *)stackView {
|
||||||
if (!_stackView) {
|
if (!_stackView) {
|
||||||
_stackView = [[UIStackView alloc] init];
|
_stackView = [[UIStackView alloc] init];
|
||||||
_stackView.axis = UILayoutConstraintAxisVertical;
|
_stackView.axis = UILayoutConstraintAxisVertical;
|
||||||
_stackView.distribution = UIStackViewDistributionFill;
|
_stackView.distribution = UIStackViewDistributionFill;
|
||||||
_stackView.alignment = UIStackViewAlignmentFill;
|
_stackView.alignment = UIStackViewAlignmentFill;
|
||||||
_stackView.spacing = kMONENTS_CONTENT_SPACAE_HEIGHT;
|
_stackView.spacing = 8;
|
||||||
}
|
}
|
||||||
return _stackView;
|
return _stackView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (XPMonentsContentView *)textView {
|
- (XPMonentsContentView *)textView {
|
||||||
if (!_textView) {
|
if (!_textView) {
|
||||||
_textView = [[XPMonentsContentView alloc] init];
|
_textView = [[XPMonentsContentView alloc] init];
|
||||||
_textView.delegate = self;
|
_textView.delegate = self;
|
||||||
/// 正常UI
|
}
|
||||||
if ([self.reuseIdentifier isEqualToString:NSStringFromClass([XPMonentsTableViewCell class])]){
|
return _textView;
|
||||||
_textView.isSimple = NO;
|
|
||||||
}else{
|
|
||||||
/// 审核UI
|
|
||||||
_textView.isSimple = YES;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return _textView;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (XPMoentsTopicView *)topicView {
|
- (XPMoentsTopicView *)topicView {
|
||||||
if (!_topicView) {
|
if (!_topicView) {
|
||||||
_topicView = [[XPMoentsTopicView alloc] init];
|
_topicView = [[XPMoentsTopicView alloc] initWithFrame:CGRectZero];
|
||||||
UITapGestureRecognizer * tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(didTapTopicRecognizer)];
|
UITapGestureRecognizer * tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(didTapTopicRecognizer)];
|
||||||
[_topicView addGestureRecognizer:tap];
|
[_topicView addGestureRecognizer:tap];
|
||||||
}
|
}
|
||||||
return _topicView;
|
return _topicView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (XPMonentsTooBarView *)toolBarView {
|
- (XPMonentsTooBarView *)toolBarView {
|
||||||
if (!_toolBarView) {
|
if (!_toolBarView) {
|
||||||
_toolBarView = [[XPMonentsTooBarView alloc] init];
|
if ([self.reuseIdentifier isEqualToString:@"XPMonentsDynamicTableViewCell"]){
|
||||||
_toolBarView.delegate = self;
|
_toolBarView = [[XPMonentsTooBarView alloc]initDynamicWithFrame:CGRectZero];
|
||||||
}
|
}else{
|
||||||
return _toolBarView;
|
_toolBarView = [[XPMonentsTooBarView alloc] init];
|
||||||
|
}
|
||||||
|
|
||||||
|
_toolBarView.delegate = self;
|
||||||
|
}
|
||||||
|
return _toolBarView;
|
||||||
|
}
|
||||||
|
- (UIView *)lineView{
|
||||||
|
if (!_lineView){
|
||||||
|
_lineView = [UIView new];
|
||||||
|
_lineView.backgroundColor = UIColorFromRGB(0xF7F7F7);
|
||||||
|
}
|
||||||
|
return _lineView;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
@@ -18,6 +18,7 @@ NS_ASSUME_NONNULL_BEGIN
|
|||||||
@interface XPMonentsPhotoView : UIView
|
@interface XPMonentsPhotoView : UIView
|
||||||
///发布的内容
|
///发布的内容
|
||||||
@property (nonatomic,copy) NSArray<MonentsPicInfoModel *> *dynamicResList;
|
@property (nonatomic,copy) NSArray<MonentsPicInfoModel *> *dynamicResList;
|
||||||
|
@property (nonatomic,copy) NSArray<MonentsPicInfoModel *> *mineDynamicResList;
|
||||||
///代理
|
///代理
|
||||||
@property (nonatomic,weak) id<XPMonentsPhotoViewDelegate> delegate;
|
@property (nonatomic,weak) id<XPMonentsPhotoViewDelegate> delegate;
|
||||||
@end
|
@end
|
||||||
|
@@ -78,6 +78,72 @@
|
|||||||
|
|
||||||
|
|
||||||
#pragma mark - Getters And Setters
|
#pragma mark - Getters And Setters
|
||||||
|
-(void)setMineDynamicResList:(NSArray<MonentsPicInfoModel *> *)mineDynamicResList{
|
||||||
|
_mineDynamicResList = mineDynamicResList;
|
||||||
|
[self hiddenAllImageView];
|
||||||
|
if ( _mineDynamicResList.count == 0) {
|
||||||
|
|
||||||
|
} else if ( _mineDynamicResList.count == 1) {
|
||||||
|
self.firstImageView.hidden = NO;
|
||||||
|
[self.firstImageView mas_remakeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.size.mas_equalTo(CGSizeMake(KScreenWidth-27*2, KScreenWidth-27*2));
|
||||||
|
make.left.top.mas_equalTo(self);
|
||||||
|
}];
|
||||||
|
MonentsPicInfoModel * picInfo = [ _mineDynamicResList safeObjectAtIndex1:0];
|
||||||
|
if(picInfo != nil){
|
||||||
|
self.firstImageView.imageUrl = picInfo.resUrl;
|
||||||
|
}
|
||||||
|
} else if( _mineDynamicResList.count == 2) {
|
||||||
|
self.firstImageView.hidden = NO;
|
||||||
|
CGFloat itemWidth = (KScreenWidth-27*2 - kMONENTS_PIC_SPACE) / 2;
|
||||||
|
[self.firstImageView mas_remakeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.size.mas_equalTo(CGSizeMake(itemWidth, itemWidth));
|
||||||
|
make.left.top.mas_equalTo(self);
|
||||||
|
}];
|
||||||
|
|
||||||
|
MonentsPicInfoModel * picInfo = [ _mineDynamicResList safeObjectAtIndex1:0];
|
||||||
|
if(picInfo != nil){
|
||||||
|
self.firstImageView.imageUrl = picInfo.resUrl;
|
||||||
|
|
||||||
|
self.secondImageView.hidden = NO;
|
||||||
|
[self.secondImageView mas_remakeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.size.mas_equalTo(CGSizeMake(itemWidth, itemWidth));
|
||||||
|
make.top.mas_equalTo(self);
|
||||||
|
make.left.mas_equalTo(self.firstImageView.mas_right).offset(kMONENTS_PIC_SPACE);
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
MonentsPicInfoModel * secondPicInfo = [ _mineDynamicResList safeObjectAtIndex1:1];
|
||||||
|
if(secondPicInfo != nil){
|
||||||
|
self.secondImageView.imageUrl = secondPicInfo.resUrl;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
} else{
|
||||||
|
for (int i = 0; i < _mineDynamicResList.count; i++) {
|
||||||
|
MonentsPicInfoModel * picInfo = [ _mineDynamicResList safeObjectAtIndex1:i];
|
||||||
|
if (i < self.subViewArray.count) {
|
||||||
|
NetImageView * imageView = [self.subViewArray safeObjectAtIndex1:i];
|
||||||
|
imageView.hidden = NO;
|
||||||
|
imageView.imageUrl = picInfo.resUrl;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
CGFloat itemWidth = (KScreenWidth-27*2 - kMONENTS_PIC_SPACE * 2) / 3;
|
||||||
|
for (int i = 0; i < self.subViewArray.count; i++) {
|
||||||
|
NSInteger page = i % 3;
|
||||||
|
NSInteger line = i / 3;
|
||||||
|
NetImageView * imageView = [self.subViewArray safeObjectAtIndex1:i];
|
||||||
|
if(imageView == nil)return;
|
||||||
|
[imageView mas_remakeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.size.mas_equalTo(CGSizeMake(itemWidth, itemWidth));
|
||||||
|
make.left.mas_equalTo(page * (itemWidth + kMONENTS_PIC_SPACE));
|
||||||
|
make.top.mas_equalTo(line * (itemWidth + kMONENTS_PIC_SPACE));
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
- (void)setDynamicResList:(NSArray<MonentsPicInfoModel *> *)dynamicResList {
|
- (void)setDynamicResList:(NSArray<MonentsPicInfoModel *> *)dynamicResList {
|
||||||
_dynamicResList = dynamicResList;
|
_dynamicResList = dynamicResList;
|
||||||
[self hiddenAllImageView];
|
[self hiddenAllImageView];
|
||||||
|
@@ -1,8 +1,8 @@
|
|||||||
//
|
//
|
||||||
// YMMonentsTooBarView.h
|
// XPMonentsTooBarView.h
|
||||||
// YUMI
|
// xplan-ios
|
||||||
//
|
//
|
||||||
// Created by YUMI on 2022/5/12.
|
// Created by 冯硕 on 2022/5/12.
|
||||||
//
|
//
|
||||||
|
|
||||||
#import <UIKit/UIKit.h>
|
#import <UIKit/UIKit.h>
|
||||||
@@ -12,16 +12,21 @@ NS_ASSUME_NONNULL_BEGIN
|
|||||||
@protocol XPMonentsTooBarViewDelegate <NSObject>
|
@protocol XPMonentsTooBarViewDelegate <NSObject>
|
||||||
///点赞
|
///点赞
|
||||||
- (void)xPMonentsTooBarView:(XPMonentsTooBarView *)view didClickLike:(MonentsInfoModel *)monentsInfo;
|
- (void)xPMonentsTooBarView:(XPMonentsTooBarView *)view didClickLike:(MonentsInfoModel *)monentsInfo;
|
||||||
///删除
|
|
||||||
- (void)xPMonentsTooBarView:(XPMonentsTooBarView *)view didClickDelete:(MonentsInfoModel *)monentsInfo;
|
|
||||||
///评论
|
///评论
|
||||||
- (void)xPMonentsTooBarView:(XPMonentsTooBarView *)view didClickCommon:(MonentsInfoModel *)monentsInfo;
|
- (void)xPMonentsTooBarView:(XPMonentsTooBarView *)view didClickCommon:(MonentsInfoModel *)monentsInfo;
|
||||||
|
///删除
|
||||||
|
- (void)xPMonentsTooBarView:(XPMonentsTooBarView *)view didClickDelete:(MonentsInfoModel *)monentsInfo;
|
||||||
|
///屏蔽
|
||||||
|
- (void)xPMonentsTooBarView:(XPMonentsTooBarView *)view didClickShielding:(MonentsInfoModel *)monentsInfo;
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
@interface XPMonentsTooBarView : UIView
|
@interface XPMonentsTooBarView : UIView
|
||||||
@property (nonatomic,strong) MonentsInfoModel *monentsInfo;
|
@property (nonatomic,strong) MonentsInfoModel *monentsInfo;
|
||||||
///代理
|
///代理
|
||||||
@property (nonatomic,weak) id<XPMonentsTooBarViewDelegate> delegate;
|
@property (nonatomic,weak) id<XPMonentsTooBarViewDelegate> delegate;
|
||||||
|
///从进入主态时初始化
|
||||||
|
- (instancetype)initDynamicWithFrame:(CGRect)frame;
|
||||||
@end
|
@end
|
||||||
|
|
||||||
NS_ASSUME_NONNULL_END
|
NS_ASSUME_NONNULL_END
|
||||||
|
@@ -1,24 +1,19 @@
|
|||||||
//
|
//
|
||||||
// YMMonentsTooBarView.m
|
// XPMonentsTooBarView.m
|
||||||
// YUMI
|
// xplan-ios
|
||||||
//
|
//
|
||||||
// Created by YUMI on 2022/5/12.
|
// Created by 冯硕 on 2022/5/12.
|
||||||
//
|
//
|
||||||
|
|
||||||
#import "XPMonentsTooBarView.h"
|
#import "XPMonentsTooBarView.h"
|
||||||
///Third
|
///Third
|
||||||
#import <Masonry/Masonry.h>
|
#import <Masonry/Masonry.h>
|
||||||
|
#import <NIMSDK/NIMSDK.h>
|
||||||
///Tool
|
///Tool
|
||||||
#import "DJDKMIMOMColor.h"
|
|
||||||
#import "TTPopup.h"
|
#import "TTPopup.h"
|
||||||
#import "YUMIHtmlUrl.h"
|
|
||||||
#import "XPShareView.h"
|
#import "XPShareView.h"
|
||||||
#import "XNDJTDDLoadingTool.h"
|
|
||||||
#import "YUMIMacroUitls.h"
|
|
||||||
#import "YUMIHtmlUrl.h"
|
|
||||||
#import "AccountInfoStorage.h"
|
#import "AccountInfoStorage.h"
|
||||||
#import "Api+Monents.h"
|
#import "Api+Monents.h"
|
||||||
#import "ClientConfig.h"
|
|
||||||
///Model
|
///Model
|
||||||
#import "MonentsInfoModel.h"
|
#import "MonentsInfoModel.h"
|
||||||
///View
|
///View
|
||||||
@@ -26,8 +21,6 @@
|
|||||||
#import "XCCurrentVCStackManager.h"
|
#import "XCCurrentVCStackManager.h"
|
||||||
|
|
||||||
@interface XPMonentsTooBarView ()<XCShareViewDelegate>
|
@interface XPMonentsTooBarView ()<XCShareViewDelegate>
|
||||||
///举报
|
|
||||||
@property (nonatomic,strong) UIButton *reportButton;
|
|
||||||
///喜欢的容器
|
///喜欢的容器
|
||||||
@property (nonatomic,strong) UIView * likeView;
|
@property (nonatomic,strong) UIView * likeView;
|
||||||
///喜欢
|
///喜欢
|
||||||
@@ -44,270 +37,389 @@
|
|||||||
@property (nonatomic,strong) UIButton *shareButton;
|
@property (nonatomic,strong) UIButton *shareButton;
|
||||||
///分割线
|
///分割线
|
||||||
@property (nonatomic,strong) UIView * lineView;
|
@property (nonatomic,strong) UIView * lineView;
|
||||||
|
///举报
|
||||||
|
@property (nonatomic,strong) UIButton *reportButton;
|
||||||
|
///是不是我的动态
|
||||||
|
@property (nonatomic,assign) BOOL isMyMonents;
|
||||||
@end
|
@end
|
||||||
|
|
||||||
@implementation XPMonentsTooBarView
|
@implementation XPMonentsTooBarView
|
||||||
|
|
||||||
|
- (instancetype)initDynamicWithFrame:(CGRect)frame{
|
||||||
|
self = [super initWithFrame:frame];
|
||||||
|
if (self) {
|
||||||
|
self.isMyMonents = YES;
|
||||||
|
[self initSubViews];
|
||||||
|
[self initSubViewConstraints];
|
||||||
|
}
|
||||||
|
return self;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
- (instancetype)initWithFrame:(CGRect)frame {
|
- (instancetype)initWithFrame:(CGRect)frame {
|
||||||
self = [super initWithFrame:frame];
|
self = [super initWithFrame:frame];
|
||||||
if (self) {
|
if (self) {
|
||||||
[self initSubViews];
|
[self initSubViews];
|
||||||
[self initSubViewConstraints];
|
[self initSubViewConstraints];
|
||||||
}
|
}
|
||||||
return self;
|
return self;
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - Private Method
|
#pragma mark - Private Method
|
||||||
|
|
||||||
- (void)initSubViews {
|
- (void)initSubViews {
|
||||||
[self addSubview:self.reportButton];
|
[self addSubview:self.likeView];
|
||||||
[self addSubview:self.likeView];
|
[self addSubview:self.commentView];
|
||||||
[self addSubview:self.commentView];
|
[self addSubview:self.shareButton];
|
||||||
[self addSubview:self.shareButton];
|
[self addSubview:self.lineView];
|
||||||
[self addSubview:self.lineView];
|
[self addSubview:self.reportButton];
|
||||||
|
|
||||||
[self.likeView addSubview:self.likeButton];
|
[self.likeView addSubview:self.likeButton];
|
||||||
[self.likeView addSubview:self.likeLabel];
|
[self.likeView addSubview:self.likeLabel];
|
||||||
[self.commentView addSubview:self.commentButton];
|
[self.commentView addSubview:self.commentButton];
|
||||||
[self.commentView addSubview:self.commentLabel];
|
[self.commentView addSubview:self.commentLabel];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)initSubViewConstraints {
|
- (void)initSubViewConstraints {
|
||||||
[self.reportButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
if (self.isMyMonents) {
|
||||||
make.left.mas_equalTo(self).offset(70);
|
[self.likeView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.top.mas_equalTo(self).offset(24);
|
make.left.mas_equalTo(12);
|
||||||
make.size.mas_equalTo(CGSizeMake(22, 22));
|
make.height.mas_equalTo(18);
|
||||||
}];
|
make.top.mas_equalTo(self).offset(0);
|
||||||
|
make.width.greaterThanOrEqualTo(@62);
|
||||||
[self.likeView mas_makeConstraints:^(MASConstraintMaker *make) {
|
}];
|
||||||
make.left.mas_equalTo(self.likeButton.mas_left);
|
[self.likeButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.height.mas_equalTo(22);
|
make.size.mas_equalTo(CGSizeMake(18, 18));
|
||||||
make.centerY.mas_equalTo(self.reportButton);
|
make.centerY.mas_equalTo(self.likeView);
|
||||||
make.right.mas_equalTo(self.commentView.mas_left).offset(-12);
|
make.left.mas_equalTo(self.likeView);
|
||||||
}];
|
}];
|
||||||
|
[self.likeLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
[self.likeLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
make.left.equalTo(self.likeButton.mas_right).mas_offset(4);
|
||||||
make.right.mas_equalTo(self.likeView.mas_right).offset(-3);
|
make.right.equalTo(self.likeView);
|
||||||
make.centerY.mas_equalTo(self.likeView);
|
make.centerY.mas_equalTo(self.likeView);
|
||||||
}];
|
}];
|
||||||
|
|
||||||
[self.likeButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.size.mas_equalTo(CGSizeMake(22, 22));
|
|
||||||
make.centerY.mas_equalTo(self.likeView);
|
|
||||||
make.right.mas_equalTo(self.likeLabel.mas_left).offset(-3);
|
|
||||||
}];
|
|
||||||
|
|
||||||
[self.commentView mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.left.mas_equalTo(self.commentButton.mas_left).offset(-2);
|
|
||||||
make.height.mas_equalTo(22);
|
|
||||||
make.centerY.mas_equalTo(self.reportButton);
|
|
||||||
make.right.mas_equalTo(self.shareButton.mas_left).offset(-12);
|
|
||||||
}];
|
|
||||||
|
|
||||||
|
|
||||||
[self.commentButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
[self.commentView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.size.mas_equalTo(CGSizeMake(22, 22));
|
make.centerY.height.mas_equalTo(self.likeView);
|
||||||
make.centerY.mas_equalTo(self.commentView);
|
make.width.greaterThanOrEqualTo(@62);
|
||||||
make.right.mas_equalTo(self.commentLabel.mas_left).offset(-2);
|
make.left.mas_equalTo(self.likeView.mas_right).offset(5);
|
||||||
}];
|
}];
|
||||||
|
|
||||||
[self.commentLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.right.mas_equalTo(self.commentView.mas_right).offset(-3);
|
[self.commentButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.centerY.mas_equalTo(self.commentView);
|
make.size.mas_equalTo(CGSizeMake(18, 18));
|
||||||
}];
|
make.centerY.mas_equalTo(self.commentView);
|
||||||
|
make.left.mas_equalTo(self.commentView);
|
||||||
[self.shareButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
}];
|
||||||
make.size.mas_equalTo(CGSizeMake(22, 22));
|
|
||||||
make.right.mas_equalTo(self).offset(-32);
|
[self.commentLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.centerY.mas_equalTo(self.reportButton);
|
make.left.mas_equalTo(self.commentButton.mas_right).offset(4);
|
||||||
}];
|
make.centerY.mas_equalTo(self.commentView);
|
||||||
|
make.right.equalTo(self.commentView);
|
||||||
[self.lineView mas_makeConstraints:^(MASConstraintMaker *make) {
|
}];
|
||||||
make.left.right.mas_equalTo(self).inset(16);
|
|
||||||
make.bottom.mas_equalTo(self);
|
[self.shareButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.height. mas_equalTo(1);
|
make.width.height.centerY.equalTo(self.likeView);
|
||||||
}];
|
make.left.mas_equalTo(self.commentView.mas_right).mas_offset(5);
|
||||||
|
}];
|
||||||
|
|
||||||
|
|
||||||
|
[self.reportButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.right.mas_equalTo(self).offset(-12);
|
||||||
|
make.centerY.mas_equalTo(self.commentView);
|
||||||
|
make.size.mas_equalTo(CGSizeMake(22, 22));
|
||||||
|
}];
|
||||||
|
} else {
|
||||||
|
self.lineView.hidden = YES;
|
||||||
|
[self.likeView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.left.mas_equalTo(18);
|
||||||
|
make.height.mas_equalTo(18);
|
||||||
|
make.top.mas_equalTo(self).offset(10);
|
||||||
|
make.width.greaterThanOrEqualTo(@62);
|
||||||
|
}];
|
||||||
|
[self.likeButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.size.mas_equalTo(CGSizeMake(18, 18));
|
||||||
|
make.centerY.mas_equalTo(self.likeView);
|
||||||
|
make.left.mas_equalTo(self.likeView);
|
||||||
|
}];
|
||||||
|
[self.likeLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.left.equalTo(self.likeButton.mas_right).mas_offset(4);
|
||||||
|
make.right.equalTo(self.likeView);
|
||||||
|
make.centerY.mas_equalTo(self.likeView);
|
||||||
|
}];
|
||||||
|
|
||||||
|
[self.commentView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.centerY.height.mas_equalTo(self.likeView);
|
||||||
|
make.width.greaterThanOrEqualTo(@62);
|
||||||
|
make.left.mas_equalTo(self.likeView.mas_right).offset(5);
|
||||||
|
}];
|
||||||
|
|
||||||
|
|
||||||
|
[self.commentButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.size.mas_equalTo(CGSizeMake(18, 18));
|
||||||
|
make.centerY.mas_equalTo(self.commentView);
|
||||||
|
make.left.mas_equalTo(self.commentView);
|
||||||
|
}];
|
||||||
|
|
||||||
|
[self.commentLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.left.mas_equalTo(self.commentButton.mas_right).offset(4);
|
||||||
|
make.centerY.mas_equalTo(self.commentView);
|
||||||
|
make.right.equalTo(self.commentView);
|
||||||
|
}];
|
||||||
|
|
||||||
|
[self.shareButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.width.height.centerY.equalTo(self.likeView);
|
||||||
|
make.left.mas_equalTo(self.commentView.mas_right).mas_offset(5);
|
||||||
|
}];
|
||||||
|
|
||||||
|
[self.reportButton mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.right.mas_equalTo(self).offset(-18);
|
||||||
|
make.centerY.mas_equalTo(self.commentView);
|
||||||
|
make.size.mas_equalTo(CGSizeMake(22, 22));
|
||||||
|
}];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
#pragma mark - Event Response
|
#pragma mark - Event Response
|
||||||
|
- (void)reportButtonAction:(UIButton *)sender {
|
||||||
|
|
||||||
|
NSMutableArray *array = [NSMutableArray array];
|
||||||
|
TTActionSheetConfig *action1;
|
||||||
|
if (self.monentsInfo.uid.integerValue == [AccountInfoStorage instance].getUid.integerValue) {
|
||||||
|
action1 = [TTActionSheetConfig normalTitle:YMLocalizedString(@"XPMonentsTooBarView0") clickAction:^{
|
||||||
|
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTooBarView:didClickDelete:)]) {
|
||||||
|
[self.delegate xPMonentsTooBarView:self didClickDelete:self.monentsInfo];
|
||||||
|
}
|
||||||
|
}];
|
||||||
|
[TTPopup actionSheetWithItems:@[action1]];
|
||||||
|
} else {
|
||||||
|
TTActionSheetConfig *action = [TTActionSheetConfig normalTitle:YMLocalizedString(@"XPMonentsTooBarView8") clickAction:^{
|
||||||
|
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTooBarView:didClickShielding:)]) {
|
||||||
|
[self.delegate xPMonentsTooBarView:self didClickShielding:self.monentsInfo];
|
||||||
|
}
|
||||||
|
}];
|
||||||
|
|
||||||
|
TTActionSheetConfig *black = [TTActionSheetConfig normalTitle:YMLocalizedString(@"XPMineUserInfoViewController1") clickAction:^{
|
||||||
|
[self addOrRemoveBlack:NO uid:self.monentsInfo.uid];
|
||||||
|
}];
|
||||||
|
|
||||||
|
[array addObjectsFromArray:@[action, black]];
|
||||||
|
|
||||||
|
BOOL isInBlackList = [[NIMSDK sharedSDK]. userManager isUserInBlackList:self.monentsInfo.uid] || [self isSystemAccount];
|
||||||
|
if (isInBlackList) {
|
||||||
|
[array removeObject:black];
|
||||||
|
}
|
||||||
|
action1 = [TTActionSheetConfig normalTitle:YMLocalizedString(@"XPMonentsTooBarView1") clickAction:^{
|
||||||
|
NSString * url= [NSString stringWithFormat:@"%@?reportUid=%@&source=%@", URLWithType(kReportRoomURL),self.monentsInfo.uid, @"WORLDDYNAMIC"];
|
||||||
|
XPWebViewController * webVC = [[XPWebViewController alloc] init];
|
||||||
|
webVC.url = url;
|
||||||
|
[[XCCurrentVCStackManager shareManager].getCurrentVC.navigationController pushViewController:webVC animated:YES];
|
||||||
|
}];
|
||||||
|
[array addObject:action1];
|
||||||
|
[TTPopup actionSheetWithItems:array];
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
- (BOOL)isSystemAccount {
|
||||||
|
return [KeyWithType(KeyType_SecretaryUidKey) isEqualToString:[NSString stringWithFormat:@"%@", self.monentsInfo.uid]] || [KeyWithType(KeyType_SystemNotifiUidKey) isEqualToString:[NSString stringWithFormat:@"%@", self.monentsInfo.uid]] || [KeyWithType(KeyType_GuildUidKey) isEqualToString:[NSString stringWithFormat:@"%@", self.monentsInfo.uid]];
|
||||||
|
}
|
||||||
|
|
||||||
|
//加入黑名单
|
||||||
|
- (void)addOrRemoveBlack:(BOOL)isRemove uid:(NSString *)uid {
|
||||||
|
NSString *title;
|
||||||
|
NSString *message;
|
||||||
|
if (isRemove) {
|
||||||
|
title = YMLocalizedString(@"XPMineUserInfoViewController2");
|
||||||
|
message = YMLocalizedString(@"XPMineUserInfoViewController3");
|
||||||
|
}else{
|
||||||
|
title = YMLocalizedString(@"XPMineUserInfoViewController4");
|
||||||
|
message = YMLocalizedString(@"XPMineUserInfoViewController5");
|
||||||
|
}
|
||||||
|
|
||||||
|
TTAlertConfig *config = [[TTAlertConfig alloc] init];
|
||||||
|
config.title = title;
|
||||||
|
config.message = message;
|
||||||
|
|
||||||
|
[TTPopup alertWithConfig:config confirmHandler:^{
|
||||||
|
if (isRemove) {
|
||||||
|
[[NIMSDK sharedSDK].userManager removeFromBlackBlackList:uid completion:^(NSError * _Nullable error) {
|
||||||
|
if (error == nil) {
|
||||||
|
|
||||||
|
[XNDJTDDLoadingTool showSuccessWithMessage:YMLocalizedString(@"XPMineUserInfoViewController6")];
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
}];
|
||||||
|
} else {
|
||||||
|
[[NIMSDK sharedSDK].userManager addToBlackList:uid completion:^(NSError * _Nullable error) {
|
||||||
|
if (error == nil) {
|
||||||
|
|
||||||
|
[XNDJTDDLoadingTool showSuccessWithMessage:YMLocalizedString(@"XPMineUserInfoViewController7")];
|
||||||
|
|
||||||
|
}
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
} cancelHandler:^{
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
|
||||||
- (void)commonButtonAction:(UIButton *)sender {
|
- (void)commonButtonAction:(UIButton *)sender {
|
||||||
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTooBarView:didClickCommon:)]) {
|
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTooBarView:didClickCommon:)]) {
|
||||||
self.commentButton.userInteractionEnabled = YES;
|
self.commentButton.userInteractionEnabled = YES;
|
||||||
[self.delegate xPMonentsTooBarView:self didClickCommon:self.monentsInfo];
|
[self.delegate xPMonentsTooBarView:self didClickCommon:self.monentsInfo];
|
||||||
} else {
|
} else {
|
||||||
self.commentButton.userInteractionEnabled = NO;
|
self.commentButton.userInteractionEnabled = NO;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)likeButtonAction:(UIButton *)sender {
|
- (void)likeButtonAction:(UIButton *)sender {
|
||||||
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTooBarView:didClickLike:)]) {
|
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTooBarView:didClickLike:)]) {
|
||||||
[self.delegate xPMonentsTooBarView:self didClickLike:self.monentsInfo];
|
[self.delegate xPMonentsTooBarView:self didClickLike:self.monentsInfo];
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
- (void)reportButtonAction:(UIButton *)sender {
|
|
||||||
TTActionSheetConfig *action;
|
|
||||||
if (self.monentsInfo.uid.integerValue == [AccountInfoStorage instance].getUid.integerValue) {
|
|
||||||
action = [TTActionSheetConfig normalTitle:YMLocalizedString(@"XPMonentsTooBarView0") clickAction:^{
|
|
||||||
if (self.delegate && [self.delegate respondsToSelector:@selector(xPMonentsTooBarView:didClickDelete:)]) {
|
|
||||||
[self.delegate xPMonentsTooBarView:self didClickDelete:self.monentsInfo];
|
|
||||||
}
|
|
||||||
}];
|
|
||||||
} else {
|
|
||||||
action = [TTActionSheetConfig normalTitle:YMLocalizedString(@"XPMonentsTooBarView1") clickAction:^{
|
|
||||||
if ([ClientConfig shareConfig].canOpen) {
|
|
||||||
NSString * url= [NSString stringWithFormat:@"%@?reportUid=%@&source=%@", URLWithType(kReportRoomURL),self.monentsInfo.uid, @"WORLDDYNAMIC"];
|
|
||||||
XPWebViewController * webVC = [[XPWebViewController alloc] init];
|
|
||||||
webVC.url = url;
|
|
||||||
[[XCCurrentVCStackManager shareManager].getCurrentVC.navigationController pushViewController:webVC animated:YES];
|
|
||||||
} else {
|
|
||||||
[XNDJTDDLoadingTool showErrorWithMessage:YMLocalizedString(@"XPMonentsTooBarView2")];
|
|
||||||
}
|
|
||||||
|
|
||||||
}];
|
|
||||||
}
|
|
||||||
[TTPopup actionSheetWithItems:@[action]];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)shareButtonAction:(UIButton *)sender {
|
- (void)shareButtonAction:(UIButton *)sender {
|
||||||
XPShareItem *friend = [XPShareItem itemWitTag:XPShareItemTagAppFriends title:YMLocalizedString(@"XPMonentsTooBarView3") imageName:@"share_friend" disableImageName:@"share_friend"];
|
XPShareItem *cycle = [XPShareItem itemWitTag:XPShareItemTagFaceBook title:@"FaceBook" imageName:@"share_fb" disableImageName:@"share_fb"];
|
||||||
XPShareItem *cycle = [XPShareItem itemWitTag:XPShareItemTagMoments title:YMLocalizedString(@"XPMonentsTooBarView4") imageName:@"share_wechat_circle_normal" disableImageName:@"share_wechat_circle_disable"];
|
XPShareItem *wechat = [XPShareItem itemWitTag:XPShareItemTagLine title:@"Line" imageName:@"share_line" disableImageName:@"share_line"];
|
||||||
XPShareItem *wechat = [XPShareItem itemWitTag:XPShareItemTagWeChat title:YMLocalizedString(@"XPMonentsTooBarView5") imageName:@"share_wechat_normal" disableImageName:@"share_wechat_disable"];
|
XPShareItem *qq = [XPShareItem itemWitTag:XPShareItemTagCopyLink title:YMLocalizedString(@"RoomHeaderView3") imageName:@"share_copy_link" disableImageName:@"share_copy_link"];
|
||||||
XPShareItem *qq = [XPShareItem itemWitTag:XPShareItemTagQQ title:YMLocalizedString(@"XPMonentsTooBarView6") imageName:@"share_qq_normal" disableImageName:@"share_qq_disable"];
|
NSArray * items = @[wechat,cycle, qq];
|
||||||
XPShareItem *qqzone = [XPShareItem itemWitTag:XPShareItemTagQQZone title:YMLocalizedString(@"XPMonentsTooBarView7") imageName:@"share_qqzone_normal" disableImageName:@"share_qqzone_disable"];
|
CGFloat margin = 15;
|
||||||
NSArray * items = @[wechat,cycle, qq, qqzone];
|
CGSize itemSize = CGSizeMake((KScreenWidth-2*margin)/4, 65);
|
||||||
CGFloat margin = 15;
|
XPShareInfoModel * shareInfo = [[XPShareInfoModel alloc] init];
|
||||||
CGSize itemSize = CGSizeMake((KScreenWidth-2*margin)/4, 65);
|
NSString * title= self.monentsInfo.nick;
|
||||||
XPShareInfoModel * shareInfo = [[XPShareInfoModel alloc] init];
|
if (self.monentsInfo.nick.length > 6) {
|
||||||
NSString * title= self.monentsInfo.nick;
|
title = [title substringToIndex:6];
|
||||||
if (self.monentsInfo.nick.length > 6) {
|
}
|
||||||
title = [title substringToIndex:6];
|
shareInfo.nick = title;
|
||||||
}
|
shareInfo.content = self.monentsInfo.content;
|
||||||
shareInfo.nick = title;
|
shareInfo.imageUrl = self.monentsInfo.avatar;
|
||||||
shareInfo.content = self.monentsInfo.content;
|
shareInfo.shareTitle = [NSString stringWithFormat:YMLocalizedString(@"XPMonentsTooBarView7"), title];
|
||||||
shareInfo.imageUrl = self.monentsInfo.avatar;
|
shareInfo.shareContent = self.monentsInfo.content;
|
||||||
shareInfo.shareTitle = [NSString stringWithFormat:YMLocalizedString(@"XPMonentsTooBarView8"), title];
|
shareInfo.shareImageUrl = self.monentsInfo.avatar;
|
||||||
shareInfo.shareContent = self.monentsInfo.content;
|
NSString * uid = [AccountInfoStorage instance].getUid;
|
||||||
shareInfo.shareImageUrl = self.monentsInfo.avatar;
|
NSString *urlStr = [NSString stringWithFormat:@"%@/%@?uid=%@&dynamicId=%@&worldId=%ld",API_HOST_URL, URLWithType(kMonentsShareURL), uid, self.monentsInfo.dynamicId, self.monentsInfo.worldId];
|
||||||
NSString * uid = [AccountInfoStorage instance].getUid;
|
shareInfo.shareUrl = urlStr;
|
||||||
NSString *urlStr = [NSString stringWithFormat:@"%@/%@?uid=%@&dynamicId=%@&worldId=%ld",API_HOST_URL, URLWithType(kMonentsShareURL), uid, self.monentsInfo.dynamicId, self.monentsInfo.worldId];
|
shareInfo.dynamicId = self.monentsInfo.dynamicId;
|
||||||
shareInfo.shareUrl = urlStr;
|
shareInfo.uid = self.monentsInfo.uid;
|
||||||
shareInfo.dynamicId = self.monentsInfo.dynamicId;
|
shareInfo.worldId = [NSString stringWithFormat:@"%ld", self.monentsInfo.worldId];
|
||||||
shareInfo.uid = self.monentsInfo.uid;
|
XPShareView *shareView = [[XPShareView alloc] initWithItems:items itemSize:itemSize shareInfo:shareInfo];
|
||||||
shareInfo.worldId = [NSString stringWithFormat:@"%ld", self.monentsInfo.worldId];
|
shareView.delegate = self;
|
||||||
XPShareView *shareView = [[XPShareView alloc] initWithItems:items itemSize:itemSize shareInfo:shareInfo];
|
[TTPopup popupView:shareView style:TTPopupStyleActionSheet];
|
||||||
shareView.delegate = self;
|
|
||||||
[TTPopup popupView:shareView style:TTPopupStyleActionSheet];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - #pragma mark - XCShareViewDelegate
|
#pragma mark - #pragma mark - XCShareViewDelegate
|
||||||
- (void)shareView:(XPShareView *)shareView shareFail:(NSString *)message {
|
- (void)shareView:(XPShareView *)shareView shareFail:(NSString *)message {
|
||||||
[TTPopup dismiss];
|
[TTPopup dismiss];
|
||||||
[XNDJTDDLoadingTool showErrorWithMessage:message];
|
[XNDJTDDLoadingTool showErrorWithMessage:message];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)shareView:(XPShareView *)shareView didSuccess:(XPShareInfoModel *)shareInfo{
|
- (void)shareView:(XPShareView *)shareView didSuccess:(XPShareInfoModel *)shareInfo{
|
||||||
[Api userShareMonents:^(BaseModel * _Nullable data, NSInteger code, NSString * _Nullable msg) {
|
[Api userShareMonents:^(BaseModel * _Nullable data, NSInteger code, NSString * _Nullable msg) {
|
||||||
|
|
||||||
} dynamicId:shareInfo.dynamicId uid:shareInfo.uid worldId:shareInfo.worldId shareUid:[AccountInfoStorage instance].getUid];
|
} dynamicId:shareInfo.dynamicId uid:shareInfo.uid worldId:shareInfo.worldId shareUid:[AccountInfoStorage instance].getUid];
|
||||||
[TTPopup dismiss];
|
[TTPopup dismiss];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)shareViewDidClickCancel:(XPShareView *)shareView {
|
- (void)shareViewDidClickCancel:(XPShareView *)shareView {
|
||||||
[TTPopup dismiss];
|
[TTPopup dismiss];
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - Getters And Setters
|
#pragma mark - Getters And Setters
|
||||||
- (void)setMonentsInfo:(MonentsInfoModel *)monentsInfo {
|
- (void)setMonentsInfo:(MonentsInfoModel *)monentsInfo {
|
||||||
_monentsInfo = monentsInfo;
|
_monentsInfo = monentsInfo;
|
||||||
if (_monentsInfo) {
|
if (_monentsInfo) {
|
||||||
self.likeButton.selected = _monentsInfo.isLike;
|
self.likeButton.selected = _monentsInfo.isLike;
|
||||||
self.likeLabel.text = _monentsInfo.likeCount.length > 0 ? _monentsInfo.likeCount : @"0";
|
self.likeLabel.text = _monentsInfo.likeCount.length > 0 ? _monentsInfo.likeCount : @"0";
|
||||||
self.commentLabel.text = _monentsInfo.commentCount.length > 0 ? _monentsInfo.commentCount : @"0";
|
self.commentLabel.text = _monentsInfo.commentCount.length > 0 ? _monentsInfo.commentCount : @"0";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
- (UIView *)likeView {
|
- (UIView *)likeView {
|
||||||
if (!_likeView) {
|
if (!_likeView) {
|
||||||
_likeView = [[UIView alloc] init];
|
_likeView = [[UIView alloc] init];
|
||||||
_likeView.backgroundColor = [UIColor clearColor];
|
_likeView.backgroundColor = [UIColor clearColor];
|
||||||
}
|
}
|
||||||
return _likeView;
|
return _likeView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (UIButton *)likeButton {
|
- (UIButton *)likeButton {
|
||||||
if (!_likeButton) {
|
if (!_likeButton) {
|
||||||
_likeButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
_likeButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
||||||
[_likeButton setImage:[UIImage imageNamed:@"monents_info_like_count_normal"] forState:UIControlStateNormal];
|
[_likeButton setImage:[UIImage imageNamed:@"monents_info_like_count_normal"] forState:UIControlStateNormal];
|
||||||
[_likeButton setImage:[UIImage imageNamed:@"monents_info_like_count_select"] forState:UIControlStateSelected];
|
[_likeButton setImage:[UIImage imageNamed:@"monents_info_like_count_select"] forState:UIControlStateSelected];
|
||||||
[_likeButton addTarget:self action:@selector(likeButtonAction:) forControlEvents:UIControlEventTouchUpInside];
|
[_likeButton addTarget:self action:@selector(likeButtonAction:) forControlEvents:UIControlEventTouchUpInside];
|
||||||
}
|
[_likeButton setEnlargeEdgeWithTop:10 right:10 bottom:10 left:10];
|
||||||
return _likeButton;
|
}
|
||||||
|
return _likeButton;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (UILabel *)likeLabel {
|
- (UILabel *)likeLabel {
|
||||||
if (!_likeLabel) {
|
if (!_likeLabel) {
|
||||||
_likeLabel = [[UILabel alloc] init];
|
_likeLabel = [[UILabel alloc] init];
|
||||||
_likeLabel.font = [UIFont systemFontOfSize:12 weight:UIFontWeightMedium];
|
_likeLabel.font = [UIFont systemFontOfSize:12 weight:UIFontWeightMedium];
|
||||||
_likeLabel.textColor = [DJDKMIMOMColor mainTextColor];
|
_likeLabel.textColor = [DJDKMIMOMColor mainTextColor];
|
||||||
}
|
}
|
||||||
return _likeLabel;
|
return _likeLabel;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
- (UIView *)commentView {
|
- (UIView *)commentView {
|
||||||
if (!_commentView) {
|
if (!_commentView) {
|
||||||
_commentView = [[UIView alloc] init];
|
_commentView = [[UIView alloc] init];
|
||||||
_commentView.backgroundColor = [UIColor clearColor];
|
_commentView.backgroundColor = [UIColor clearColor];
|
||||||
}
|
}
|
||||||
return _commentView;
|
return _commentView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (UIButton *)commentButton {
|
- (UIButton *)commentButton {
|
||||||
if (!_commentButton) {
|
if (!_commentButton) {
|
||||||
_commentButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
_commentButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
||||||
[_commentButton setImage:[UIImage imageNamed:@"monents_info_comment_count"] forState:UIControlStateNormal];
|
[_commentButton setImage:[UIImage imageNamed:@"monents_info_comment_count"] forState:UIControlStateNormal];
|
||||||
[_commentButton setImage:[UIImage imageNamed:@"monents_info_comment_count"] forState:UIControlStateSelected];
|
[_commentButton setImage:[UIImage imageNamed:@"monents_info_comment_count"] forState:UIControlStateSelected];
|
||||||
[_commentButton addTarget:self action:@selector(commonButtonAction:) forControlEvents:UIControlEventTouchUpInside];
|
[_commentButton addTarget:self action:@selector(commonButtonAction:) forControlEvents:UIControlEventTouchUpInside];
|
||||||
}
|
[_commentButton setEnlargeEdgeWithTop:10 right:10 bottom:10 left:10];
|
||||||
return _commentButton;
|
}
|
||||||
|
return _commentButton;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (UILabel *)commentLabel {
|
- (UILabel *)commentLabel {
|
||||||
if (!_commentLabel) {
|
if (!_commentLabel) {
|
||||||
_commentLabel = [[UILabel alloc] init];
|
_commentLabel = [[UILabel alloc] init];
|
||||||
_commentLabel.font = [UIFont systemFontOfSize:12 weight:UIFontWeightMedium];
|
_commentLabel.font = [UIFont systemFontOfSize:12 weight:UIFontWeightMedium];
|
||||||
_commentLabel.textColor = [DJDKMIMOMColor mainTextColor];
|
_commentLabel.textColor = [DJDKMIMOMColor mainTextColor];
|
||||||
}
|
}
|
||||||
return _commentLabel;
|
return _commentLabel;
|
||||||
}
|
|
||||||
|
|
||||||
- (UIButton *)reportButton {
|
|
||||||
if (!_reportButton) {
|
|
||||||
_reportButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
|
||||||
[_reportButton setImage:[UIImage imageNamed:@"monents_info_like_report"] forState:UIControlStateNormal];
|
|
||||||
[_reportButton setImage:[UIImage imageNamed:@"monents_info_like_report"] forState:UIControlStateSelected];
|
|
||||||
[_reportButton addTarget:self action:@selector(reportButtonAction:) forControlEvents:UIControlEventTouchUpInside];
|
|
||||||
}
|
|
||||||
return _reportButton;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (UIButton *)shareButton {
|
- (UIButton *)shareButton {
|
||||||
if (!_shareButton) {
|
if (!_shareButton) {
|
||||||
_shareButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
_shareButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
||||||
[_shareButton setImage:[UIImage imageNamed:@"monents_info_like_share"] forState:UIControlStateNormal];
|
[_shareButton setImage:[UIImage imageNamed:@"monents_info_like_share"] forState:UIControlStateNormal];
|
||||||
[_shareButton setImage:[UIImage imageNamed:@"monents_info_like_share"] forState:UIControlStateSelected];
|
[_shareButton setImage:[UIImage imageNamed:@"monents_info_like_share"] forState:UIControlStateSelected];
|
||||||
_shareButton.hidden = YES;
|
[_shareButton addTarget:self action:@selector(shareButtonAction:) forControlEvents:UIControlEventTouchUpInside];
|
||||||
[_shareButton addTarget:self action:@selector(shareButtonAction:) forControlEvents:UIControlEventTouchUpInside];
|
_shareButton.hidden = YES;
|
||||||
}
|
}
|
||||||
return _shareButton;
|
return _shareButton;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (UIView *)lineView {
|
- (UIView *)lineView {
|
||||||
if (!_lineView) {
|
if (!_lineView) {
|
||||||
_lineView = [[UIView alloc] init];
|
_lineView = [[UIView alloc] init];
|
||||||
_lineView.backgroundColor = [DJDKMIMOMColor dividerColor];
|
_lineView.backgroundColor = [DJDKMIMOMColor dividerColor];
|
||||||
}
|
_lineView.hidden = YES;
|
||||||
return _lineView;
|
}
|
||||||
|
return _lineView;
|
||||||
|
}
|
||||||
|
- (UIButton *)reportButton {
|
||||||
|
if (!_reportButton) {
|
||||||
|
_reportButton = [UIButton buttonWithType:UIButtonTypeCustom];
|
||||||
|
[_reportButton setImage:[UIImage imageNamed:@"monents_info_like_report"] forState:UIControlStateNormal];
|
||||||
|
[_reportButton setImage:[UIImage imageNamed:@"monents_info_like_report"] forState:UIControlStateSelected];
|
||||||
|
[_reportButton addTarget:self action:@selector(reportButtonAction:) forControlEvents:UIControlEventTouchUpInside];
|
||||||
|
[_reportButton setEnlargeEdgeWithTop:10 right:10 bottom:10 left:10];
|
||||||
|
}
|
||||||
|
return _reportButton;
|
||||||
}
|
}
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
@@ -206,6 +206,10 @@ NS_ASSUME_NONNULL_BEGIN
|
|||||||
+(void)requestRoomFirstCharegWindow:(HttpRequestHelperCompletion)completion roomUid:(NSString *)roomUid;
|
+(void)requestRoomFirstCharegWindow:(HttpRequestHelperCompletion)completion roomUid:(NSString *)roomUid;
|
||||||
///更新首充弹窗次数
|
///更新首充弹窗次数
|
||||||
+(void)updateRoomFirstCharegWindow:(HttpRequestHelperCompletion)completion roomUid:(NSString *)roomUid;
|
+(void)updateRoomFirstCharegWindow:(HttpRequestHelperCompletion)completion roomUid:(NSString *)roomUid;
|
||||||
|
/// 屏蔽
|
||||||
|
/// @param completion 完成
|
||||||
|
/// @param type type为0 => 屏蔽动态, objId 为 动态id, type为1 => 屏蔽房间, objId 为 用户uid
|
||||||
|
+ (void)requesstShielding:(HttpRequestHelperCompletion)completion type:(NSString *)type objId:(NSString *)objId;
|
||||||
@end
|
@end
|
||||||
|
|
||||||
NS_ASSUME_NONNULL_END
|
NS_ASSUME_NONNULL_END
|
||||||
|
@@ -281,5 +281,10 @@
|
|||||||
[self makeRequest:fang method:HttpRequestHelperMethodPOST completion:completion, __FUNCTION__,roomUid,nil];
|
[self makeRequest:fang method:HttpRequestHelperMethodPOST completion:completion, __FUNCTION__,roomUid,nil];
|
||||||
|
|
||||||
}
|
}
|
||||||
|
/// 屏蔽
|
||||||
|
/// @param completion 完成
|
||||||
|
/// @param type type为0 => 屏蔽动态, objId 为 动态id, type为1 => 屏蔽房间, objId 为 用户uid
|
||||||
|
+ (void)requesstShielding:(HttpRequestHelperCompletion)completion type:(NSString *)type objId:(NSString *)objId{
|
||||||
|
[self makeRequest:@"user/black/add" method:HttpRequestHelperMethodPOST completion:completion, __FUNCTION__, type,objId, nil];
|
||||||
|
}
|
||||||
@end
|
@end
|
||||||
|
@@ -29,7 +29,7 @@
|
|||||||
///分页控件
|
///分页控件
|
||||||
@property (nonatomic, strong) JXCategoryTitleView *titleView;
|
@property (nonatomic, strong) JXCategoryTitleView *titleView;
|
||||||
///分页lineView
|
///分页lineView
|
||||||
@property (nonatomic, strong) JXCategoryListContainerView *containerView;
|
@property (nonatomic, strong) JXCategoryListContainerView *pi_containerView;
|
||||||
///初级森林
|
///初级森林
|
||||||
@property (nonatomic,strong) XPTreasureFairyPrizeSubView *normalView;
|
@property (nonatomic,strong) XPTreasureFairyPrizeSubView *normalView;
|
||||||
///史诗森林
|
///史诗森林
|
||||||
@@ -53,7 +53,7 @@
|
|||||||
- (void)initSubViews {
|
- (void)initSubViews {
|
||||||
self.backgroundColor = [UIColor clearColor];
|
self.backgroundColor = [UIColor clearColor];
|
||||||
[self addSubview:self.titleView];
|
[self addSubview:self.titleView];
|
||||||
[self addSubview:self.containerView];
|
[self addSubview:self.pi_containerView];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)initSubViewConstraints {
|
- (void)initSubViewConstraints {
|
||||||
@@ -64,7 +64,7 @@
|
|||||||
make.top.mas_equalTo(self).offset(0);
|
make.top.mas_equalTo(self).offset(0);
|
||||||
}];
|
}];
|
||||||
|
|
||||||
[self.containerView mas_makeConstraints:^(MASConstraintMaker *make) {
|
[self.pi_containerView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.left.right.bottom.mas_equalTo(self);
|
make.left.right.bottom.mas_equalTo(self);
|
||||||
make.top.mas_equalTo(self.titleView.mas_bottom).offset(13);
|
make.top.mas_equalTo(self.titleView.mas_bottom).offset(13);
|
||||||
}];
|
}];
|
||||||
@@ -117,7 +117,7 @@
|
|||||||
_titleView.contentEdgeInsetLeft = 0;
|
_titleView.contentEdgeInsetLeft = 0;
|
||||||
_titleView.contentEdgeInsetRight = 0;
|
_titleView.contentEdgeInsetRight = 0;
|
||||||
_titleView.cellWidth = 60;
|
_titleView.cellWidth = 60;
|
||||||
_titleView.listContainer = self.containerView;
|
_titleView.listContainer = self.pi_containerView;
|
||||||
|
|
||||||
JXCategoryIndicatorImageView *lineView = [[JXCategoryIndicatorImageView alloc] init];
|
JXCategoryIndicatorImageView *lineView = [[JXCategoryIndicatorImageView alloc] init];
|
||||||
lineView.indicatorImageViewSize = CGSizeMake(60, 4);
|
lineView.indicatorImageViewSize = CGSizeMake(60, 4);
|
||||||
@@ -131,13 +131,13 @@
|
|||||||
return _titleView;
|
return _titleView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (JXCategoryListContainerView *)containerView {
|
- (JXCategoryListContainerView *)pi_containerView {
|
||||||
if (!_containerView) {
|
if (!_pi_containerView) {
|
||||||
_containerView = [[JXCategoryListContainerView alloc] initWithType:JXCategoryListContainerType_ScrollView delegate:self];
|
_pi_containerView = [[JXCategoryListContainerView alloc] initWithType:JXCategoryListContainerType_ScrollView delegate:self];
|
||||||
_containerView.defaultSelectedIndex = 0;
|
_pi_containerView.defaultSelectedIndex = 0;
|
||||||
_containerView.scrollView.tag = 1009;
|
_pi_containerView.scrollView.tag = 1009;
|
||||||
}
|
}
|
||||||
return _containerView;
|
return _pi_containerView;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (NSArray<NSString *> *)titles {
|
- (NSArray<NSString *> *)titles {
|
||||||
|
Before Width: | Height: | Size: 1.1 MiB |
BIN
YuMi/Resources/pi_new_mine_info_online.svga
Normal file
BIN
YuMi/Resources/pi_new_mine_info_sound_play.svga
Normal file
@@ -1,15 +1,16 @@
|
|||||||
//
|
//
|
||||||
// UploadFile.m
|
// UploadFile.m
|
||||||
// YUMI
|
// xplan-ios
|
||||||
//
|
//
|
||||||
// Created by YUMI on 2022/2/23.
|
// Created by GreenLand on 2022/2/23.
|
||||||
//
|
//
|
||||||
|
|
||||||
#import "UploadFile.h"
|
#import "UploadFile.h"
|
||||||
#import <Qiniu/QiniuSDK.h>
|
#import <Qiniu/QiniuSDK.h>
|
||||||
#import <AFNetworking.h>
|
#import <AFNetworking.h>
|
||||||
@implementation UploadFile
|
|
||||||
|
|
||||||
|
@implementation UploadFile
|
||||||
|
//zoneAs0
|
||||||
/// 上传一个文件
|
/// 上传一个文件
|
||||||
/// @param filePath 文件地址
|
/// @param filePath 文件地址
|
||||||
/// @param fileName 文件的名字
|
/// @param fileName 文件的名字
|
||||||
@@ -22,7 +23,7 @@
|
|||||||
success:(void (^)(NSString *key, NSDictionary *resp))success
|
success:(void (^)(NSString *key, NSDictionary *resp))success
|
||||||
failure:(void (^)(NSNumber *resCode, NSString *message))failure {
|
failure:(void (^)(NSNumber *resCode, NSString *message))failure {
|
||||||
QNConfiguration *config = [QNConfiguration build:^(QNConfigurationBuilder *builder) {
|
QNConfiguration *config = [QNConfiguration build:^(QNConfigurationBuilder *builder) {
|
||||||
builder.zone = [QNFixedZone zone2];
|
builder.zone = [QNFixedZone zoneAs0];
|
||||||
}];
|
}];
|
||||||
QNUploadManager *upManager = [[QNUploadManager alloc] initWithConfiguration:config];
|
QNUploadManager *upManager = [[QNUploadManager alloc] initWithConfiguration:config];
|
||||||
[upManager putFile:filePath key:fileName token:token complete:^(QNResponseInfo *info, NSString *key, NSDictionary *resp) {
|
[upManager putFile:filePath key:fileName token:token complete:^(QNResponseInfo *info, NSString *key, NSDictionary *resp) {
|
||||||
|
BIN
YuMi/pi_app_logo_bg.png
Normal file
After Width: | Height: | Size: 190 KiB |
@@ -344,7 +344,7 @@
|
|||||||
"XPMineUserInfoHeaderView2" = "%ld粉丝";
|
"XPMineUserInfoHeaderView2" = "%ld粉丝";
|
||||||
"XPMineUserInfoHeaderView3" = "直播中";
|
"XPMineUserInfoHeaderView3" = "直播中";
|
||||||
"XPMineUserInfoHeaderView4" = "录制声音卡";
|
"XPMineUserInfoHeaderView4" = "录制声音卡";
|
||||||
|
"XPMineUserInfoHeaderView5" = "录制声音卡";
|
||||||
///XPMineUserInfoHeaderTagView
|
///XPMineUserInfoHeaderTagView
|
||||||
"XPMineUserInfoHeaderTagView0"="设置你的个人标签";
|
"XPMineUserInfoHeaderTagView0"="设置你的个人标签";
|
||||||
"XPMineUserInfoDateView0" = "取消";
|
"XPMineUserInfoDateView0" = "取消";
|
||||||
@@ -380,6 +380,17 @@
|
|||||||
"XPMineDataClanTableViewCell2" = "公会";
|
"XPMineDataClanTableViewCell2" = "公会";
|
||||||
"XPMineDataClanTableViewCell3" = "公会·房间";
|
"XPMineDataClanTableViewCell3" = "公会·房间";
|
||||||
"XPMineDataClanTableViewCell4" = "申请加入";
|
"XPMineDataClanTableViewCell4" = "申请加入";
|
||||||
|
"XPMineDataClanTableViewCell5" = "暂未加入公会";
|
||||||
|
"XPMineDataClanTableViewCell6" = "个人资料";
|
||||||
|
"XPMineDataClanTableViewCell7" = "星座:";
|
||||||
|
"XPMineDataClanTableViewCell8" = "生日:";
|
||||||
|
"XPMineDataClanTableViewCell9" = "房间:";
|
||||||
|
"XPMineDataClanTableViewCell10" = "公会:";
|
||||||
|
"XPMineDataClanTableViewCell11" = "该用户暂未加入房间";
|
||||||
|
"XPMineDataClanTableViewCell12" = "暂未加入房间";
|
||||||
|
"XPMineDataClanTableViewCell13" = "地区:";
|
||||||
|
"XPMineDataClanTableViewCell14" = "更多";
|
||||||
|
|
||||||
|
|
||||||
"XPMineUserInfoTableViewCell0" = "%@号";
|
"XPMineUserInfoTableViewCell0" = "%@号";
|
||||||
"XPMineUserInfoTableViewCell1" = "我是个默认签名";
|
"XPMineUserInfoTableViewCell1" = "我是个默认签名";
|
||||||
@@ -393,21 +404,25 @@
|
|||||||
|
|
||||||
"XPMineRechargeTableViewCell0" = "鑽石";
|
"XPMineRechargeTableViewCell0" = "鑽石";
|
||||||
|
|
||||||
|
///XPMineUserInfoViewController.m
|
||||||
"XPMineUserInfoViewController0" = "举报";
|
"XPMineUserInfoViewController0" = "举报";
|
||||||
"XPMineUserInfoViewController1" = "您的请求我们已经收到,我们将儘快处理";
|
"XPMineUserInfoViewController1" = "拉黑用户";
|
||||||
"XPMineUserInfoViewController2" = "拉黑";
|
"XPMineUserInfoViewController2" = "移除黑名单";
|
||||||
"XPMineUserInfoViewController3" = "移除黑名单";
|
"XPMineUserInfoViewController3" = "移除黑名单,你将正常收到对方的消息";
|
||||||
"XPMineUserInfoViewController4" = "移除黑名单,你将正常收到对方的消息";
|
"XPMineUserInfoViewController4" = "加入黑名单";
|
||||||
"XPMineUserInfoViewController5" = "加入黑名单";
|
"XPMineUserInfoViewController5" = "加入黑名单,你将不再收到对方的消息";
|
||||||
"XPMineUserInfoViewController6" = "加入黑名单,你将不再收到对方的消息";
|
"XPMineUserInfoViewController6" = "移出黑名单成功";
|
||||||
"XPMineUserInfoViewController7" = "移出黑名单成功";
|
"XPMineUserInfoViewController7" = "加入黑名单成功";
|
||||||
"XPMineUserInfoViewController8" = "加入黑名单成功";
|
"XPMineUserInfoViewController8" = "私信";
|
||||||
"XPMineUserInfoViewController9" = "编辑";
|
"XPMineUserInfoViewController9" = "关注";
|
||||||
"XPMineUserInfoViewController10" = "私信";
|
"XPMineUserInfoViewController10" = "已关注";
|
||||||
"XPMineUserInfoViewController11" = "关注";
|
"XPMineUserInfoViewController11" = "资料";
|
||||||
"XPMineUserInfoViewController12" = "已关注";
|
"XPMineUserInfoViewController12" = "动态";
|
||||||
"XPMineUserInfoViewController14" = "动态";
|
"XPMineUserInfoViewController13" = "礼物墙";
|
||||||
|
///XPMineUserInfoGiftWallViewController.m
|
||||||
|
"XPMineUserInfoGiftWallViewController0" = "礼物";
|
||||||
|
"XPMineUserInfoGiftWallViewController1" = "普通礼物";
|
||||||
|
"XPMineUserInfoGiftWallViewController2" = "幸运礼物";
|
||||||
"XPMineUserInfoAlbumViewController0" = "我的相册";
|
"XPMineUserInfoAlbumViewController0" = "我的相册";
|
||||||
"XPMineUserInfoAlbumViewController1" = "拍照上传";
|
"XPMineUserInfoAlbumViewController1" = "拍照上传";
|
||||||
"XPMineUserInfoAlbumViewController3" = "相机权限受限,点击确定去系统设置";
|
"XPMineUserInfoAlbumViewController3" = "相机权限受限,点击确定去系统设置";
|
||||||
@@ -423,18 +438,11 @@
|
|||||||
"XPMineUserInfoAlbumViewController16" = "编辑";
|
"XPMineUserInfoAlbumViewController16" = "编辑";
|
||||||
"XPMineUserInfoAlbumViewController17" = "完成";
|
"XPMineUserInfoAlbumViewController17" = "完成";
|
||||||
|
|
||||||
"XPMineUserDataViewController0" = "为了营造更安全的网络环境\n保护您和他人的财产安全\n请先进行实名认证";
|
///XPMineUserDataViewController.m
|
||||||
"XPMineUserDataViewController1" = "确定";
|
"XPMineUserDataViewController0" = "申请成功,等待管理员审核";
|
||||||
"XPMineUserDataViewController2" = "实名认证";
|
"XPMineUserDataViewController1" = "动态";
|
||||||
"XPMineUserDataViewController3" = "申请成功,等待管理员审核";
|
"XPMineUserDataViewController2" = "默认动态不能点赞";
|
||||||
"XPMineUserDataViewController4" = "默认动态不能点赞";
|
"XPMineUserDataViewController3" = "默认动态不能评论";
|
||||||
"XPMineUserDataViewController5" = "默认动态不能评论";
|
|
||||||
"XPMineSimpleUserInfoHeaderView0" = "我是个默认签名";
|
|
||||||
"XPMineSimpleUserInfoHeaderView1" = "粉丝";
|
|
||||||
"XPMineSimpleUserInfoHeaderView2" = "直播中";
|
|
||||||
"XPMineSimpleUserInfoHeaderView3" = "礼物牆";
|
|
||||||
"XPMineSimpleUserInfoHeaderView5" = "幸运礼物";
|
|
||||||
"XPMineSimpleUserInfoHeaderView6" = "动态";
|
|
||||||
|
|
||||||
"XPMineSimpleUserInfoViewController0" = "举报";
|
"XPMineSimpleUserInfoViewController0" = "举报";
|
||||||
"XPMineSimpleUserInfoViewController1" = "您的请求我们已经收到,我们将儘快处理";
|
"XPMineSimpleUserInfoViewController1" = "您的请求我们已经收到,我们将儘快处理";
|
||||||
|
@@ -344,6 +344,7 @@
|
|||||||
"XPMineUserInfoHeaderView2" = "%ld粉絲";
|
"XPMineUserInfoHeaderView2" = "%ld粉絲";
|
||||||
"XPMineUserInfoHeaderView3" = "直播中";
|
"XPMineUserInfoHeaderView3" = "直播中";
|
||||||
"XPMineUserInfoHeaderView4" = "錄制聲音卡";
|
"XPMineUserInfoHeaderView4" = "錄制聲音卡";
|
||||||
|
"XPMineUserInfoHeaderView5" = "我是個默認簽名";
|
||||||
///XPMineUserInfoIndividualTagView
|
///XPMineUserInfoIndividualTagView
|
||||||
"XPMineUserInfoIndividualTagView0"="TA的標簽";
|
"XPMineUserInfoIndividualTagView0"="TA的標簽";
|
||||||
"XPMineUserInfoIndividualTagView1"="我的標簽";
|
"XPMineUserInfoIndividualTagView1"="我的標簽";
|
||||||
@@ -379,7 +380,7 @@
|
|||||||
"XPMineFriendEmptyTableViewCell0" = "暫無數據";
|
"XPMineFriendEmptyTableViewCell0" = "暫無數據";
|
||||||
|
|
||||||
"XPMineDataGiftTableViewCell0" = "普通禮物";
|
"XPMineDataGiftTableViewCell0" = "普通禮物";
|
||||||
"XPMineDataGiftTableViewCell2" = "幸運禮物";
|
"XPMineDataGiftTableViewCell1" = "幸運禮物";
|
||||||
|
|
||||||
"XPMineUserInfoEmptyCollectionViewCell0" = "還未收到過禮物";
|
"XPMineUserInfoEmptyCollectionViewCell0" = "還未收到過禮物";
|
||||||
|
|
||||||
@@ -388,6 +389,20 @@
|
|||||||
"XPMineDataClanTableViewCell2" = "公會";
|
"XPMineDataClanTableViewCell2" = "公會";
|
||||||
"XPMineDataClanTableViewCell3" = "公會·房間";
|
"XPMineDataClanTableViewCell3" = "公會·房間";
|
||||||
"XPMineDataClanTableViewCell4" = "申請加入";
|
"XPMineDataClanTableViewCell4" = "申請加入";
|
||||||
|
"XPMineDataClanTableViewCell5" = "暫未加入公會";
|
||||||
|
"XPMineDataClanTableViewCell6" = "個人資料";
|
||||||
|
"XPMineDataClanTableViewCell7" = "星座:";
|
||||||
|
"XPMineDataClanTableViewCell8" = "生日:";
|
||||||
|
"XPMineDataClanTableViewCell9" = "房間:";
|
||||||
|
"XPMineDataClanTableViewCell10" = "公會:";
|
||||||
|
"XPMineDataClanTableViewCell11" = "該用戶暫未加入房間";
|
||||||
|
"XPMineDataClanTableViewCell12" = "暫未加入房間";
|
||||||
|
"XPMineDataClanTableViewCell13" = "地區:";
|
||||||
|
"XPMineDataClanTableViewCell14" = "更多";
|
||||||
|
///XPMineUserInfoGiftWallViewController.m
|
||||||
|
"XPMineUserInfoGiftWallViewController0" = "禮物";
|
||||||
|
"XPMineUserInfoGiftWallViewController1" = "普通禮物";
|
||||||
|
"XPMineUserInfoGiftWallViewController2" = "幸運禮物";
|
||||||
|
|
||||||
"XPMineUserInfoTableViewCell0" = "%@號";
|
"XPMineUserInfoTableViewCell0" = "%@號";
|
||||||
"XPMineUserInfoTableViewCell1" = "我是個默認簽名";
|
"XPMineUserInfoTableViewCell1" = "我是個默認簽名";
|
||||||
@@ -401,20 +416,21 @@
|
|||||||
|
|
||||||
"XPMineRechargeTableViewCell0" = "鑽石";
|
"XPMineRechargeTableViewCell0" = "鑽石";
|
||||||
|
|
||||||
|
///XPMineUserInfoViewController.m
|
||||||
"XPMineUserInfoViewController0" = "舉報";
|
"XPMineUserInfoViewController0" = "舉報";
|
||||||
"XPMineUserInfoViewController1" = "您的請求我們已經收到,我們將儘快處理";
|
"XPMineUserInfoViewController1" = "拉黑用戶";
|
||||||
"XPMineUserInfoViewController2" = "拉黑";
|
"XPMineUserInfoViewController2" = "移除黑名單";
|
||||||
"XPMineUserInfoViewController3" = "移除黑名單";
|
"XPMineUserInfoViewController3" = "移除黑名單,你將正常收到對方的消息";
|
||||||
"XPMineUserInfoViewController4" = "移除黑名單,你將正常收到對方的消息";
|
"XPMineUserInfoViewController4" = "加入黑名單";
|
||||||
"XPMineUserInfoViewController5" = "加入黑名單";
|
"XPMineUserInfoViewController5" = "加入黑名單,你將不再收到對方的消息";
|
||||||
"XPMineUserInfoViewController6" = "加入黑名單,你將不再收到對方的消息";
|
"XPMineUserInfoViewController6" = "移出黑名單成功";
|
||||||
"XPMineUserInfoViewController7" = "移出黑名單成功";
|
"XPMineUserInfoViewController7" = "加入黑名單成功";
|
||||||
"XPMineUserInfoViewController8" = "加入黑名單成功";
|
"XPMineUserInfoViewController8" = "私信";
|
||||||
"XPMineUserInfoViewController9" = "編輯";
|
"XPMineUserInfoViewController9" = "關註";
|
||||||
"XPMineUserInfoViewController10" = "私信";
|
"XPMineUserInfoViewController10" = "已關註";
|
||||||
"XPMineUserInfoViewController11" = "關註";
|
"XPMineUserInfoViewController11" = "資料";
|
||||||
"XPMineUserInfoViewController12" = "已關註";
|
"XPMineUserInfoViewController12" = "動態";
|
||||||
"XPMineUserInfoViewController14" = "動態";
|
"XPMineUserInfoViewController13" = "禮物墻";
|
||||||
|
|
||||||
"XPMineUserInfoAlbumViewController0" = "我的相冊";
|
"XPMineUserInfoAlbumViewController0" = "我的相冊";
|
||||||
"XPMineUserInfoAlbumViewController1" = "拍照上傳";
|
"XPMineUserInfoAlbumViewController1" = "拍照上傳";
|
||||||
@@ -431,18 +447,10 @@
|
|||||||
"XPMineUserInfoAlbumViewController16" = "編輯";
|
"XPMineUserInfoAlbumViewController16" = "編輯";
|
||||||
"XPMineUserInfoAlbumViewController17" = "完成";
|
"XPMineUserInfoAlbumViewController17" = "完成";
|
||||||
|
|
||||||
"XPMineUserDataViewController0" = "為了營造更安全的網絡環境\n保護您和他人的財產安全\n請先進行實名認證";
|
"XPMineUserDataViewController0" = "申請成功,等待管理員審核";
|
||||||
"XPMineUserDataViewController1" = "確定";
|
"XPMineUserDataViewController1" = "動態";
|
||||||
"XPMineUserDataViewController2" = "實名認證";
|
"XPMineUserDataViewController2" = "默認動態不能點贊";
|
||||||
"XPMineUserDataViewController3" = "申請成功,等待管理員審核";
|
"XPMineUserDataViewController3" = "默認動態不能評論";
|
||||||
"XPMineUserDataViewController4" = "默認動態不能點贊";
|
|
||||||
"XPMineUserDataViewController5" = "默認動態不能評論";
|
|
||||||
"XPMineSimpleUserInfoHeaderView0" = "我是個默認簽名";
|
|
||||||
"XPMineSimpleUserInfoHeaderView1" = "粉絲";
|
|
||||||
"XPMineSimpleUserInfoHeaderView2" = "直播中";
|
|
||||||
"XPMineSimpleUserInfoHeaderView3" = "禮物牆";
|
|
||||||
"XPMineSimpleUserInfoHeaderView5" = "幸運禮物";
|
|
||||||
"XPMineSimpleUserInfoHeaderView6" = "動態";
|
|
||||||
|
|
||||||
"XPMineSimpleUserInfoViewController0" = "舉報";
|
"XPMineSimpleUserInfoViewController0" = "舉報";
|
||||||
"XPMineSimpleUserInfoViewController1" = "您的請求我們已經收到,我們將儘快處理";
|
"XPMineSimpleUserInfoViewController1" = "您的請求我們已經收到,我們將儘快處理";
|
||||||
|