Steven hai 1 ano
pai
achega
bbed073ad0
Modificáronse 41 ficheiros con 488 adicións e 186 borrados
  1. 10 0
      KulexiuForStudent/KulexiuForStudent.xcodeproj/project.pbxproj
  2. 22 0
      KulexiuForStudent/KulexiuForStudent/Assets.xcassets/Chat/group_role_teacher.imageset/Contents.json
  3. BIN=BIN
      KulexiuForStudent/KulexiuForStudent/Assets.xcassets/Chat/group_role_teacher.imageset/group_role_teacher@2x.png
  4. BIN=BIN
      KulexiuForStudent/KulexiuForStudent/Assets.xcassets/Chat/group_role_teacher.imageset/group_role_teacher@3x.png
  5. 22 0
      KulexiuForStudent/KulexiuForStudent/Assets.xcassets/Chat/group_tenant.imageset/Contents.json
  6. BIN=BIN
      KulexiuForStudent/KulexiuForStudent/Assets.xcassets/Chat/group_tenant.imageset/group_tenant@2x.png
  7. BIN=BIN
      KulexiuForStudent/KulexiuForStudent/Assets.xcassets/Chat/group_tenant.imageset/group_tenant@3x.png
  8. 3 0
      KulexiuForStudent/KulexiuForStudent/Common/Base/KSBaseWKWebViewController.m
  9. 20 9
      KulexiuForStudent/KulexiuForStudent/Common/Define/KSDomain.h
  10. 2 0
      KulexiuForStudent/KulexiuForStudent/Common/Define/UserKeyHeader.h
  11. 3 0
      KulexiuForStudent/KulexiuForStudent/Common/ThirdPart/FSCalendar/FSCalendarCell.m
  12. 19 3
      KulexiuForStudent/KulexiuForStudent/InstitutionModule/Home/Controller/TenantDarkViewController.m
  13. 9 24
      KulexiuForStudent/KulexiuForStudent/InstitutionModule/Home/View/MoreMusicPage/MorePageSearchView.xib
  14. 5 0
      KulexiuForStudent/KulexiuForStudent/InstitutionModule/Home/View/TenantHomeSubjectListCell.xib
  15. 2 2
      KulexiuForStudent/KulexiuForStudent/InstitutionModule/Mine/Controller/INSSettingViewController.m
  16. 12 4
      KulexiuForStudent/KulexiuForStudent/InstitutionModule/Mine/Controller/InsititutionMineViewController.m
  17. 3 2
      KulexiuForStudent/KulexiuForStudent/InstitutionModule/Mine/View/InstitutionMineBodyView.xib
  18. 1 1
      KulexiuForStudent/KulexiuForStudent/InstitutionModule/Mine/View/InstitutionMineNavView.xib
  19. 22 9
      KulexiuForStudent/KulexiuForStudent/Module/Chat/Group/Controller/GroupSettingViewController.m
  20. 8 9
      KulexiuForStudent/KulexiuForStudent/Module/Chat/Group/View/GroupMemberListCell.m
  21. 38 22
      KulexiuForStudent/KulexiuForStudent/Module/Chat/Group/View/GroupMemberListCell.xib
  22. 23 21
      KulexiuForStudent/KulexiuForStudent/Module/Chat/Group/View/GroupSettingBodyView.m
  23. 1 1
      KulexiuForStudent/KulexiuForStudent/Module/Chat/Group/View/GroupSettingBodyView.xib
  24. 2 2
      KulexiuForStudent/KulexiuForStudent/Module/Chat/View/ChatAddressBodyView.m
  25. 2 0
      KulexiuForStudent/KulexiuForStudent/Module/Chat/View/ContractListCell.m
  26. 11 10
      KulexiuForStudent/KulexiuForStudent/Module/Chat/View/ContractListCell.xib
  27. 4 0
      KulexiuForStudent/KulexiuForStudent/Module/Chat/View/GroupListViewCell.m
  28. 20 0
      KulexiuForStudent/KulexiuForStudent/Module/Chat/View/GroupOwnerTagView.h
  29. 29 0
      KulexiuForStudent/KulexiuForStudent/Module/Chat/View/GroupOwnerTagView.m
  30. 39 0
      KulexiuForStudent/KulexiuForStudent/Module/Chat/View/GroupOwnerTagView.xib
  31. 1 0
      KulexiuForStudent/KulexiuForStudent/Module/Course/Controller/CourseViewController.m
  32. 1 0
      KulexiuForStudent/KulexiuForStudent/Module/Live/Controller/LiveVideoRoomViewController.m
  33. 9 9
      KulexiuForStudent/KulexiuForStudent/Module/Live/Model/KSEnterLiveroomManager.m
  34. 2 1
      KulexiuForStudent/KulexiuForStudent/Module/Live/Model/LiveModuleService.h
  35. 4 2
      KulexiuForStudent/KulexiuForStudent/Module/Live/Model/LiveModuleService.m
  36. 2 0
      KulexiuForStudent/KulexiuForStudent/Module/TXClassRoom/Controller/TXClassroomViewController.m
  37. 34 13
      KulexiuForStudent/KulexiuForStudent/Module/TXClassRoom/View/MainContainerView/TXClassroomMainContainer.m
  38. 3 1
      KulexiuForStudent/KulexiuForStudent/Module/TXClassRoom/View/MainContainerView/VideoMaskView.h
  39. 29 6
      KulexiuForStudent/KulexiuForStudent/Module/TXClassRoom/View/MainContainerView/VideoMaskView.m
  40. 35 33
      KulexiuForStudent/KulexiuForStudent/Module/TXClassRoom/View/VideoList/TXClassroomVideoListCell.m
  41. 36 2
      KulexiuForStudent/KulexiuForStudent/Module/TXLive/Controller/TXLiveRoomViewController.m

+ 10 - 0
KulexiuForStudent/KulexiuForStudent.xcodeproj/project.pbxproj

@@ -508,6 +508,8 @@
 		BC2DFF5828BE143A0056105A /* HomeTempLiveCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = BC2DFF5628BE143A0056105A /* HomeTempLiveCell.xib */; };
 		BC2DFF5B28C097D60056105A /* talentAnimation.json in Resources */ = {isa = PBXBuildFile; fileRef = BC2DFF5A28C097D60056105A /* talentAnimation.json */; };
 		BC2DFF5D28C097DC0056105A /* styleAnimation.json in Resources */ = {isa = PBXBuildFile; fileRef = BC2DFF5C28C097DC0056105A /* styleAnimation.json */; };
+		BC36A5082AB406A5002FEFB1 /* GroupOwnerTagView.m in Sources */ = {isa = PBXBuildFile; fileRef = BC36A5072AB406A5002FEFB1 /* GroupOwnerTagView.m */; };
+		BC36A50A2AB406AB002FEFB1 /* GroupOwnerTagView.xib in Resources */ = {isa = PBXBuildFile; fileRef = BC36A5092AB406AB002FEFB1 /* GroupOwnerTagView.xib */; };
 		BC3A4EAB28DAC0CD001C4428 /* ShareLiveDisplayView.m in Sources */ = {isa = PBXBuildFile; fileRef = BC3A4EAA28DAC0CD001C4428 /* ShareLiveDisplayView.m */; };
 		BC3A4EAD28DAC0D6001C4428 /* ShareLiveDisplayView.xib in Resources */ = {isa = PBXBuildFile; fileRef = BC3A4EAC28DAC0D6001C4428 /* ShareLiveDisplayView.xib */; };
 		BC3A4EB128DAE074001C4428 /* KSQRCreateManager.m in Sources */ = {isa = PBXBuildFile; fileRef = BC3A4EB028DAE074001C4428 /* KSQRCreateManager.m */; };
@@ -2028,6 +2030,9 @@
 		BC2DFF5628BE143A0056105A /* HomeTempLiveCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = HomeTempLiveCell.xib; sourceTree = "<group>"; };
 		BC2DFF5A28C097D60056105A /* talentAnimation.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = talentAnimation.json; sourceTree = "<group>"; };
 		BC2DFF5C28C097DC0056105A /* styleAnimation.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = styleAnimation.json; sourceTree = "<group>"; };
+		BC36A5062AB406A5002FEFB1 /* GroupOwnerTagView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GroupOwnerTagView.h; sourceTree = "<group>"; };
+		BC36A5072AB406A5002FEFB1 /* GroupOwnerTagView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GroupOwnerTagView.m; sourceTree = "<group>"; };
+		BC36A5092AB406AB002FEFB1 /* GroupOwnerTagView.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = GroupOwnerTagView.xib; sourceTree = "<group>"; };
 		BC3818192A40262200B74F26 /* KSDomain.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = KSDomain.h; sourceTree = "<group>"; };
 		BC3A4EA928DAC0CD001C4428 /* ShareLiveDisplayView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ShareLiveDisplayView.h; sourceTree = "<group>"; };
 		BC3A4EAA28DAC0CD001C4428 /* ShareLiveDisplayView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ShareLiveDisplayView.m; sourceTree = "<group>"; };
@@ -3462,6 +3467,9 @@
 				BCDE358D289A7D8700A9A560 /* KSGroupTagImageView.m */,
 				BC756CB428FE4E5D00AA9ECB /* KSChatTagView.h */,
 				BC756CB528FE4E5D00AA9ECB /* KSChatTagView.m */,
+				BC36A5062AB406A5002FEFB1 /* GroupOwnerTagView.h */,
+				BC36A5072AB406A5002FEFB1 /* GroupOwnerTagView.m */,
+				BC36A5092AB406AB002FEFB1 /* GroupOwnerTagView.xib */,
 			);
 			path = View;
 			sourceTree = "<group>";
@@ -7082,6 +7090,7 @@
 				BC71D268288804CD0010F14B /* img_25.png in Resources */,
 				BC7E77112900F39700EB37AF /* TuningForkSettingView.xib in Resources */,
 				BCCE95D92AB0440400AB6385 /* singleMusic_Ani.json in Resources */,
+				BC36A50A2AB406AB002FEFB1 /* GroupOwnerTagView.xib in Resources */,
 				BCC583C928A9EC6400BAB4CF /* cloud_animation_11.png in Resources */,
 				BC71D264288804CD0010F14B /* img_41.png in Resources */,
 				BC71D267288804CD0010F14B /* img_42.png in Resources */,
@@ -7706,6 +7715,7 @@
 				2723B5BB27F157B100E0B90B /* ChatAddressBodyView.m in Sources */,
 				2779357427E324A70010E277 /* StoreButton.m in Sources */,
 				BC71D27F288807680010F14B /* AnimationHelper.m in Sources */,
+				BC36A5082AB406A5002FEFB1 /* GroupOwnerTagView.m in Sources */,
 				277935A927E324A80010E277 /* MSSBrowseActionSheet.m in Sources */,
 				275FA1E027E7351900CFEA2E /* RecordCheckManager.m in Sources */,
 				BC8B641528F3B5AC00A08D16 /* KSAwardAlertView.m in Sources */,

+ 22 - 0
KulexiuForStudent/KulexiuForStudent/Assets.xcassets/Chat/group_role_teacher.imageset/Contents.json

@@ -0,0 +1,22 @@
+{
+  "images" : [
+    {
+      "idiom" : "universal",
+      "scale" : "1x"
+    },
+    {
+      "filename" : "group_role_teacher@2x.png",
+      "idiom" : "universal",
+      "scale" : "2x"
+    },
+    {
+      "filename" : "group_role_teacher@3x.png",
+      "idiom" : "universal",
+      "scale" : "3x"
+    }
+  ],
+  "info" : {
+    "author" : "xcode",
+    "version" : 1
+  }
+}

BIN=BIN
KulexiuForStudent/KulexiuForStudent/Assets.xcassets/Chat/group_role_teacher.imageset/group_role_teacher@2x.png


BIN=BIN
KulexiuForStudent/KulexiuForStudent/Assets.xcassets/Chat/group_role_teacher.imageset/group_role_teacher@3x.png


+ 22 - 0
KulexiuForStudent/KulexiuForStudent/Assets.xcassets/Chat/group_tenant.imageset/Contents.json

@@ -0,0 +1,22 @@
+{
+  "images" : [
+    {
+      "idiom" : "universal",
+      "scale" : "1x"
+    },
+    {
+      "filename" : "group_tenant@2x.png",
+      "idiom" : "universal",
+      "scale" : "2x"
+    },
+    {
+      "filename" : "group_tenant@3x.png",
+      "idiom" : "universal",
+      "scale" : "3x"
+    }
+  ],
+  "info" : {
+    "author" : "xcode",
+    "version" : 1
+  }
+}

BIN=BIN
KulexiuForStudent/KulexiuForStudent/Assets.xcassets/Chat/group_tenant.imageset/group_tenant@2x.png


BIN=BIN
KulexiuForStudent/KulexiuForStudent/Assets.xcassets/Chat/group_tenant.imageset/group_tenant@3x.png


+ 3 - 0
KulexiuForStudent/KulexiuForStudent/Common/Base/KSBaseWKWebViewController.m

@@ -239,6 +239,9 @@ typedef NS_ENUM(NSInteger, CHOOSETYPE) {
         // 加载进度条和title
         [_myWebView addObserver:self forKeyPath:@"estimatedProgress" options:NSKeyValueObservingOptionNew context:nil];
         [_myWebView addObserver:self forKeyPath:@"title" options:NSKeyValueObservingOptionNew context:NULL];
+        if (@available(iOS 16.4, *)) {
+            _myWebView.inspectable = YES;
+        }
         [self.view addSubview:_myWebView];
         [_myWebView mas_makeConstraints:^(MASConstraintMaker *make) {
             make.left.right.mas_equalTo(self.view);

+ 20 - 9
KulexiuForStudent/KulexiuForStudent/Common/Define/KSDomain.h

@@ -13,20 +13,31 @@
 
 //#ifdef DEBUG
 
-#define hostURL (@"https://dev.colexiu.com")
-#define SEALCLASSHOST (@"https://dev.colexiu.com/api-classroom")
-//#define SEALCLASSHOST (@"http://192.168.3.143:8000/api-classroom")
-
-#define WEBHOST (@"https://dev.colexiu.com/student")
-#define TENANT_WEBHOST (@"https://dev.colexiu.com/tenant")
-#define SOCKET_URL (@"wss://dev.colexiu.com/audioAnalysis")
+// 测试环境
+
+//#define hostURL (@"https://dev.colexiu.com")
+//#define SEALCLASSHOST (@"https://dev.colexiu.com/api-classroom")
+//#define WEBHOST (@"https://dev.colexiu.com/student")
+//#define TENANT_WEBHOST (@"https://dev.colexiu.com/tenant")
+//#define SOCKET_URL (@"wss://dev.colexiu.com/audioAnalysis")
+//#define JSPUSH_ENVIRONMENT (NO)
+//#define RCIM_KEY (@"0vnjpoad0jbdz")
+//#define SUBMIT_UUID (NO)
+//#define CONFIG_TXSDKAPPID (1400805079)
+//#define TXOfflinePushCertificateIDForAPNS (39557)
+
+
+// 开发环境
+#define hostURL (@"https://test.colexiu.com")
+#define SEALCLASSHOST (@"https://test.colexiu.com/api-classroom")
+#define WEBHOST (@"https://test.colexiu.com/student")
+#define TENANT_WEBHOST (@"https://test.colexiu.com/tenant")
+#define SOCKET_URL (@"wss://test.colexiu.com/audioAnalysis")
 #define JSPUSH_ENVIRONMENT (NO)
 #define RCIM_KEY (@"0vnjpoad0jbdz")
 #define SUBMIT_UUID (NO)
 #define CONFIG_TXSDKAPPID (1400805079)
 #define TXOfflinePushCertificateIDForAPNS (39557)
-
-
 //#else
 
 //#define hostURL (@"https://online.colexiu.com")

+ 2 - 0
KulexiuForStudent/KulexiuForStudent/Common/Define/UserKeyHeader.h

@@ -46,6 +46,8 @@
 
 #define GROUP_FAN_LOGO (@"chat_fansGroup_logo")
 #define GROUP_COURSE_LOGO (@"chat_group_Logo")
+#define GROUP_TENANT_LOGO (@"tenant_group_default_avatal")
+
 
 #define USERDEFAULT_LOGO (@"user_default_avatal")
 #define USER_LOGO_RECTANGLE (@"user_avatarRectangle")

+ 3 - 0
KulexiuForStudent/KulexiuForStudent/Common/ThirdPart/FSCalendar/FSCalendarCell.m

@@ -288,6 +288,9 @@
     if (!self.dateIsToday && _isHightlight) {
         return _appearance.backgroundColors[@(FSCalendarCellStateHightlight)];
     }
+    if (self.dateIsToday && _isHightlight) {
+        return _appearance.backgroundColors[@(FSCalendarCellStateHightlight)];
+    }
     return self.preferredFillDefaultColor ?: [self colorForCurrentStateInDictionary:_appearance.backgroundColors];
 }
 

+ 19 - 3
KulexiuForStudent/KulexiuForStudent/InstitutionModule/Home/Controller/TenantDarkViewController.m

@@ -95,7 +95,9 @@
 }
 
 - (void)showActivateView {
-    
+    KSBaseWKWebViewController *webCtrl = [[KSBaseWKWebViewController alloc] init];
+    webCtrl.url = [NSString stringWithFormat:@"%@/#/activation-code", TENANT_WEBHOST];
+    [self.navigationController pushViewController:webCtrl animated:YES];
 }
 
 - (void)requsetTicket {
@@ -229,10 +231,24 @@
 - (void)pagerView:(TYCyclePagerView *)pageView didSelectedItemCell:(__kindof UICollectionViewCell *)cell atIndex:(NSInteger)index {
     BOOL isLock = self.mineInfo.tenantAlbumStatus == 1 ? YES : NO;
     if (isLock) {
-        
+        KSBaseWKWebViewController *ctrl = [[KSBaseWKWebViewController alloc] init];
+        ctrl.url = [NSString stringWithFormat:@"%@%@",TENANT_WEBHOST,@"/#/train-tool"];
+        [self.navigationController pushViewController:ctrl animated:YES];
     }
     else { // 跳转到对应页面
-        
+        NSString *subjectType = @"";
+        if (index == 0) {
+            subjectType = @"SUBJECT";
+        }
+        else if (index == 1) {
+            subjectType = @"MUSIC";
+        }
+        else {
+            subjectType = @"ENSEMBLE";
+        }
+        KSBaseWKWebViewController *webCtrl = [[KSBaseWKWebViewController alloc] init];
+        webCtrl.url = [NSString stringWithFormat:@"%@/#/train-list?subjectType=%@", TENANT_WEBHOST,subjectType];
+        [self.navigationController pushViewController:webCtrl animated:YES];
     }
 }
 

+ 9 - 24
KulexiuForStudent/KulexiuForStudent/InstitutionModule/Home/View/MoreMusicPage/MorePageSearchView.xib

@@ -17,14 +17,14 @@
                     <rect key="frame" x="13" y="16" width="367" height="34"/>
                     <subviews>
                         <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="tenant_sortDown" translatesAutoresizingMaskIntoConstraints="NO" id="No0-5i-GfE">
-                            <rect key="frame" x="32.666666666666664" y="14.666666666666668" width="9" height="5"/>
+                            <rect key="frame" x="0.0" y="14.666666666666668" width="0.0" height="5"/>
                             <constraints>
                                 <constraint firstAttribute="height" constant="5" id="CD7-Ve-xLK"/>
-                                <constraint firstAttribute="width" constant="9" id="VV1-Of-jpk"/>
+                                <constraint firstAttribute="width" id="VV1-Of-jpk"/>
                             </constraints>
                         </imageView>
                         <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Xcb-gz-yas">
-                            <rect key="frame" x="53.666666666666657" y="0.0" width="313.33333333333337" height="34"/>
+                            <rect key="frame" x="0.0" y="0.0" width="367" height="34"/>
                             <subviews>
                                 <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="search_red" translatesAutoresizingMaskIntoConstraints="NO" id="9rs-fB-o8b">
                                     <rect key="frame" x="12" y="9" width="16" height="16"/>
@@ -34,12 +34,12 @@
                                     </constraints>
                                 </imageView>
                                 <textField opaque="NO" contentMode="scaleToFill" horizontalHuggingPriority="248" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请输入专辑关键词" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="Mx6-O3-EOH">
-                                    <rect key="frame" x="34.000000000000014" y="0.0" width="214.33333333333337" height="34"/>
+                                    <rect key="frame" x="34" y="0.0" width="268" height="34"/>
                                     <fontDescription key="fontDescription" type="system" pointSize="14"/>
                                     <textInputTraits key="textInputTraits"/>
                                 </textField>
                                 <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="cif-Ba-pW6">
-                                    <rect key="frame" x="254.33333333333331" y="3" width="56" height="28"/>
+                                    <rect key="frame" x="308" y="3" width="56" height="28"/>
                                     <color key="backgroundColor" red="1" green="0.34901960784313724" blue="0.57647058823529407" alpha="1" colorSpace="calibratedRGB"/>
                                     <constraints>
                                         <constraint firstAttribute="height" constant="28" id="Sdr-Vj-7JE"/>
@@ -82,36 +82,21 @@
                                 </userDefinedRuntimeAttribute>
                             </userDefinedRuntimeAttributes>
                         </view>
-                        <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="乐器" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="74R-HR-vA5">
-                            <rect key="frame" x="0.0" y="8.6666666666666679" width="28.666666666666668" height="17"/>
-                            <constraints>
-                                <constraint firstAttribute="width" relation="lessThanOrEqual" constant="80" id="b0C-NQ-2Oy"/>
-                                <constraint firstAttribute="width" relation="greaterThanOrEqual" constant="20" id="yVH-qg-dZq"/>
-                            </constraints>
+                        <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="74R-HR-vA5">
+                            <rect key="frame" x="0.0" y="17" width="0.0" height="0.0"/>
                             <fontDescription key="fontDescription" type="system" pointSize="14"/>
                             <color key="textColor" red="0.074509803921568626" green="0.078431372549019607" blue="0.082352941176470587" alpha="1" colorSpace="calibratedRGB"/>
                             <nil key="highlightedColor"/>
                         </label>
-                        <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="ye7-0Y-ZU4">
-                            <rect key="frame" x="0.0" y="0.0" width="41.666666666666664" height="34"/>
-                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
-                            <connections>
-                                <action selector="modifySubject:" destination="iN0-l3-epB" eventType="touchUpInside" id="X60-ss-hgg"/>
-                            </connections>
-                        </button>
                     </subviews>
                     <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
                     <constraints>
-                        <constraint firstItem="No0-5i-GfE" firstAttribute="leading" secondItem="74R-HR-vA5" secondAttribute="trailing" constant="4" id="8Hz-bm-euZ"/>
+                        <constraint firstItem="No0-5i-GfE" firstAttribute="leading" secondItem="74R-HR-vA5" secondAttribute="trailing" id="8Hz-bm-euZ"/>
                         <constraint firstAttribute="bottom" secondItem="Xcb-gz-yas" secondAttribute="bottom" id="8am-Sq-xTr"/>
-                        <constraint firstItem="No0-5i-GfE" firstAttribute="trailing" secondItem="ye7-0Y-ZU4" secondAttribute="trailing" id="CPf-du-Rhy"/>
-                        <constraint firstItem="Xcb-gz-yas" firstAttribute="leading" secondItem="No0-5i-GfE" secondAttribute="trailing" constant="12" id="K2b-eJ-aeO"/>
+                        <constraint firstItem="Xcb-gz-yas" firstAttribute="leading" secondItem="No0-5i-GfE" secondAttribute="trailing" id="K2b-eJ-aeO"/>
                         <constraint firstItem="Xcb-gz-yas" firstAttribute="top" secondItem="eCa-KK-SiZ" secondAttribute="top" id="PWv-Ee-NEo"/>
-                        <constraint firstItem="ye7-0Y-ZU4" firstAttribute="leading" secondItem="eCa-KK-SiZ" secondAttribute="leading" id="Sk2-o0-ezV"/>
-                        <constraint firstItem="ye7-0Y-ZU4" firstAttribute="top" secondItem="eCa-KK-SiZ" secondAttribute="top" id="ecg-xO-xuz"/>
                         <constraint firstAttribute="trailing" secondItem="Xcb-gz-yas" secondAttribute="trailing" id="elS-mA-tpd"/>
                         <constraint firstItem="74R-HR-vA5" firstAttribute="centerY" secondItem="eCa-KK-SiZ" secondAttribute="centerY" id="f3A-B6-q9i"/>
-                        <constraint firstAttribute="bottom" secondItem="ye7-0Y-ZU4" secondAttribute="bottom" id="hmq-j9-Ib5"/>
                         <constraint firstItem="74R-HR-vA5" firstAttribute="leading" secondItem="eCa-KK-SiZ" secondAttribute="leading" id="mAV-l5-Pox"/>
                         <constraint firstAttribute="height" constant="34" id="r5Y-6f-fAg"/>
                         <constraint firstItem="No0-5i-GfE" firstAttribute="centerY" secondItem="74R-HR-vA5" secondAttribute="centerY" id="wv2-Pw-d44"/>

+ 5 - 0
KulexiuForStudent/KulexiuForStudent/InstitutionModule/Home/View/TenantHomeSubjectListCell.xib

@@ -44,6 +44,11 @@
                             <constraint firstItem="YXt-cM-3da" firstAttribute="centerX" secondItem="yWf-kO-jnd" secondAttribute="centerX" id="mNT-fr-2lr"/>
                             <constraint firstItem="yWf-kO-jnd" firstAttribute="centerX" secondItem="g0T-Fy-c1K" secondAttribute="centerX" id="sBo-bW-UI9"/>
                         </constraints>
+                        <userDefinedRuntimeAttributes>
+                            <userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
+                                <real key="value" value="10"/>
+                            </userDefinedRuntimeAttribute>
+                        </userDefinedRuntimeAttributes>
                     </view>
                 </subviews>
             </view>

+ 2 - 2
KulexiuForStudent/KulexiuForStudent/InstitutionModule/Mine/Controller/INSSettingViewController.m

@@ -102,9 +102,9 @@
 
         }
             break;
-        case INSETTINGTYPE_SUBJECT:
+        case INSETTINGTYPE_SUBJECT: // 9月18同步机构学员不可修改声部
         {
-            [self showInstrumentView];
+//            [self showInstrumentView];
 
         }
             break;

+ 12 - 4
KulexiuForStudent/KulexiuForStudent/InstitutionModule/Mine/Controller/InsititutionMineViewController.m

@@ -105,7 +105,9 @@
             break;
         case INSMINETYPE_TOOL:
         {
-            
+            KSBaseWKWebViewController *ctrl = [[KSBaseWKWebViewController alloc] init];
+            ctrl.url = [NSString stringWithFormat:@"%@%@",TENANT_WEBHOST,@"/#/train-tool"];
+            [self.navigationController pushViewController:ctrl animated:YES];
         }
             break;
         case INSMINETYPE_MUSIC:
@@ -117,7 +119,9 @@
             break;
         case INSMINETYPE_TRAIN:
         {
-            
+            KSBaseWKWebViewController *ctrl = [[KSBaseWKWebViewController alloc] init];
+            ctrl.url = [NSString stringWithFormat:@"%@%@",TENANT_WEBHOST,@"/#/memberRecord"];
+            [self.navigationController pushViewController:ctrl animated:YES];
         }
             break;
         case INSMINETYPE_ORDER:
@@ -129,12 +133,16 @@
             break;
         case INSMINETYPE_RANK:
         {
-            
+            KSBaseWKWebViewController *webCtrl = [[KSBaseWKWebViewController alloc] init];
+            webCtrl.url = [NSString stringWithFormat:@"%@/#/ranking-list", TENANT_WEBHOST];
+            [self.navigationController pushViewController:webCtrl animated:YES];
         }
             break;
         case INSMINETYPE_CODE:
         {
-            
+            KSBaseWKWebViewController *webCtrl = [[KSBaseWKWebViewController alloc] init];
+            webCtrl.url = [NSString stringWithFormat:@"%@/#/activation-code", TENANT_WEBHOST];
+            [self.navigationController pushViewController:webCtrl animated:YES];
         }
             break;
         case INSMINETYPE_HELP:

+ 3 - 2
KulexiuForStudent/KulexiuForStudent/InstitutionModule/Mine/View/InstitutionMineBodyView.xib

@@ -292,7 +292,7 @@
                         <view tag="1003" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Sny-pb-TWZ">
                             <rect key="frame" x="0.0" y="51" width="73.333333333333329" height="74"/>
                             <subviews>
-                                <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="insititution_mine_code" translatesAutoresizingMaskIntoConstraints="NO" id="z6K-YU-QmJ">
+                                <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="insititution_mine_music" translatesAutoresizingMaskIntoConstraints="NO" id="z6K-YU-QmJ">
                                     <rect key="frame" x="20.666666666666664" y="2" width="32" height="32"/>
                                     <gestureRecognizers/>
                                     <constraints>
@@ -427,7 +427,7 @@
                             <color key="textColor" red="0.074509803921568626" green="0.078431372549019607" blue="0.082352941176470587" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                             <nil key="highlightedColor"/>
                         </label>
-                        <view tag="1006" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="JPB-oG-7OI">
+                        <view tag="1007" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="JPB-oG-7OI">
                             <rect key="frame" x="293.66666666666669" y="51" width="73.333333333333314" height="74"/>
                             <subviews>
                                 <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="insititution_mine_code" translatesAutoresizingMaskIntoConstraints="NO" id="fq9-6v-NL0">
@@ -834,6 +834,7 @@
         <image name="insititution_mine_code" width="32" height="32"/>
         <image name="insititution_mine_eveluate" width="32" height="32"/>
         <image name="insititution_mine_header" width="58" height="50"/>
+        <image name="insititution_mine_music" width="32" height="32"/>
         <image name="insititution_mine_order" width="32" height="32"/>
         <image name="insititution_mine_rank" width="32" height="32"/>
         <image name="insititution_mine_subject" width="13" height="13"/>

+ 1 - 1
KulexiuForStudent/KulexiuForStudent/InstitutionModule/Mine/View/InstitutionMineNavView.xib

@@ -31,7 +31,7 @@
                                         <action selector="buttonAction:" destination="iN0-l3-epB" eventType="touchUpInside" id="cZx-c1-gq8"/>
                                     </connections>
                                 </button>
-                                <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="uBH-qe-Dun">
+                                <view hidden="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="uBH-qe-Dun">
                                     <rect key="frame" x="0.0" y="43" width="393" height="1"/>
                                     <color key="backgroundColor" red="0.94901960784313721" green="0.94901960784313721" blue="0.94901960784313721" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                                     <constraints>

+ 22 - 9
KulexiuForStudent/KulexiuForStudent/Module/Chat/Group/Controller/GroupSettingViewController.m

@@ -70,6 +70,18 @@
 }
 
 - (void)evaluateMessge {
+    
+    NSMutableArray *memberArray = [NSMutableArray array];
+    for (GroupMemberModel *model in self.sourceArray) {
+        if (model.isAdmin) {
+            [memberArray insertObject:model atIndex:0];
+        }
+        else {
+            [memberArray addObject:model];
+        }
+    }
+    self.sourceArray = [NSMutableArray arrayWithArray:memberArray];
+    
     [self.bodyView evaluateStudentArray:self.sourceArray];
 }
 
@@ -188,13 +200,13 @@
             break;
         case GROUPSETTING_DISMISS: // 发消息
         {
-//            if (self.sourceModel) {
-//                [self dismissGroup];
-//            }
-//            else {
-//                [self MBPShow:@"您已不在当前群聊"];
-//            }
-            [self backAction];
+            if (self.sourceModel) {
+                [self dismissGroup];
+            }
+            else {
+                [self MBPShow:@"您已不在当前群聊"];
+            }
+//            [self backAction];
         }
             break;
         default:
@@ -214,10 +226,11 @@
 - (void)quitGroup {
     [self showhud];
     [KSNetworkingManager quitImGroupRequest:KS_POST groupId:self.groupId success:^(NSDictionary * _Nonnull dic) {
+        [self removehub];
         if ([dic ks_integerValueForKey:@"code"] == 200 && [dic ks_boolValueForKey:@"status"]) {
             MJWeakSelf;
-            [self KSShowMsg:@"退出成功" promptCompletion:^{
-                [weakSelf removehub];
+            [self KSShowMsg:@"你已退出该群聊" promptCompletion:^{
+                [weakSelf removeCurrentConversation];
                 [weakSelf.navigationController popToRootViewControllerAnimated:YES];
             }];
         }

+ 8 - 9
KulexiuForStudent/KulexiuForStudent/Module/Chat/Group/View/GroupMemberListCell.m

@@ -10,9 +10,7 @@
 
 @interface GroupMemberListCell ()
 
-@property (weak, nonatomic) IBOutlet UIImageView *ownerImage;
-@property (weak, nonatomic) IBOutlet NSLayoutConstraint *ownerWidth;
-@property (weak, nonatomic) IBOutlet NSLayoutConstraint *nameLeft;
+@property (weak, nonatomic) IBOutlet UIView *ownerTagView;
 
 @property (weak, nonatomic) IBOutlet UIImageView *memberLogo;
 
@@ -20,6 +18,8 @@
 
 @property (weak, nonatomic) IBOutlet UIImageView *typeView;
 
+@property (weak, nonatomic) IBOutlet NSLayoutConstraint *typeViewWidth;
+
 @property (nonatomic, copy) ChatCallback callback;
 
 @property (nonatomic, strong) GroupMemberModel *sourceModel;
@@ -58,20 +58,19 @@
             self.chatButton.userInteractionEnabled = NO;
         }
         if (model.isAdmin) {
-            self.nameLeft.constant = 4.0f;
-            self.ownerWidth.constant = 34.0f;
-            self.ownerImage.hidden = NO;
+            self.ownerTagView.hidden = NO;
         }
         else {
-            self.nameLeft.constant = 0.0f;
-            self.ownerWidth.constant = 0.0f;
-            self.ownerImage.hidden = YES;
+            self.ownerTagView.hidden = YES;
         }
+        
         if ([model.roleType isEqualToString:@"TEACHER"]) {
             self.typeView.hidden = NO;
+            self.typeViewWidth.constant = 41.0f;
         }
         else {
             self.typeView.hidden = YES;
+            self.typeViewWidth.constant = 0.0f;
         }
     }
 }

+ 38 - 22
KulexiuForStudent/KulexiuForStudent/Module/Chat/Group/View/GroupMemberListCell.xib

@@ -21,7 +21,7 @@
                     <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="3bd-Vo-rTM">
                         <rect key="frame" x="0.0" y="0.0" width="320" height="64"/>
                         <subviews>
-                            <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="GW3-Oz-aPr">
+                            <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="user_avatarRectangle" translatesAutoresizingMaskIntoConstraints="NO" id="GW3-Oz-aPr">
                                 <rect key="frame" x="14" y="10" width="44" height="44"/>
                                 <constraints>
                                     <constraint firstAttribute="width" constant="44" id="Mcn-Si-qXx"/>
@@ -34,7 +34,7 @@
                                 </userDefinedRuntimeAttributes>
                             </imageView>
                             <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="张三" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Vhp-Wi-YsA">
-                                <rect key="frame" x="107" y="21" width="33" height="22"/>
+                                <rect key="frame" x="69" y="21" width="33" height="22"/>
                                 <constraints>
                                     <constraint firstAttribute="height" constant="22" id="Js9-hD-GW8"/>
                                 </constraints>
@@ -54,34 +54,51 @@
                                     <action selector="chatAction:" destination="KGk-i7-Jjw" eventType="touchUpInside" id="zCp-eY-UZG"/>
                                 </connections>
                             </button>
-                            <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="group_ownerList" translatesAutoresizingMaskIntoConstraints="NO" id="qqr-xe-xWm">
-                                <rect key="frame" x="69" y="23" width="34" height="18"/>
+                            <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="dcn-Rh-TwP">
+                                <rect key="frame" x="16" y="41" width="40" height="15"/>
+                                <subviews>
+                                    <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="群主" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="R54-zn-qMI">
+                                        <rect key="frame" x="8.5" y="0.5" width="23" height="14"/>
+                                        <fontDescription key="fontDescription" type="system" weight="medium" pointSize="11"/>
+                                        <color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                        <nil key="highlightedColor"/>
+                                    </label>
+                                </subviews>
+                                <color key="backgroundColor" red="1" green="0.30196078431372547" blue="0.44705882352941173" alpha="1" colorSpace="calibratedRGB"/>
                                 <constraints>
-                                    <constraint firstAttribute="width" constant="34" id="d6B-m0-bcK"/>
-                                    <constraint firstAttribute="height" constant="18" id="yGQ-mL-173"/>
+                                    <constraint firstAttribute="height" constant="15" id="FQs-vL-FYp"/>
+                                    <constraint firstItem="R54-zn-qMI" firstAttribute="centerX" secondItem="dcn-Rh-TwP" secondAttribute="centerX" id="HE1-4D-XlW"/>
+                                    <constraint firstItem="R54-zn-qMI" firstAttribute="centerY" secondItem="dcn-Rh-TwP" secondAttribute="centerY" id="N32-P6-zqU"/>
+                                    <constraint firstAttribute="width" constant="40" id="tSL-pp-ypb"/>
                                 </constraints>
-                            </imageView>
-                            <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="chat_talentList" translatesAutoresizingMaskIntoConstraints="NO" id="V3Z-gz-k2w">
-                                <rect key="frame" x="14" y="40" width="44" height="14"/>
+                                <userDefinedRuntimeAttributes>
+                                    <userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
+                                        <real key="value" value="7.5"/>
+                                    </userDefinedRuntimeAttribute>
+                                </userDefinedRuntimeAttributes>
+                            </view>
+                            <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="group_role_teacher" translatesAutoresizingMaskIntoConstraints="NO" id="2T3-oJ-zPX">
+                                <rect key="frame" x="105" y="22" width="41" height="20"/>
                                 <constraints>
-                                    <constraint firstAttribute="width" constant="44" id="1WR-Pc-gtP"/>
-                                    <constraint firstAttribute="height" constant="14" id="S1M-3m-wGg"/>
+                                    <constraint firstAttribute="height" constant="20" id="DPH-1c-0ah"/>
+                                    <constraint firstAttribute="width" constant="41" id="KLd-9O-eWg"/>
                                 </constraints>
                             </imageView>
                         </subviews>
                         <color key="backgroundColor" systemColor="systemBackgroundColor"/>
                         <constraints>
+                            <constraint firstItem="C2d-wO-ajH" firstAttribute="leading" relation="greaterThanOrEqual" secondItem="2T3-oJ-zPX" secondAttribute="trailing" constant="10" id="1uo-kS-tVu"/>
                             <constraint firstItem="Vhp-Wi-YsA" firstAttribute="centerY" secondItem="GW3-Oz-aPr" secondAttribute="centerY" id="4jm-Nc-ex4"/>
                             <constraint firstItem="C2d-wO-ajH" firstAttribute="leading" relation="greaterThanOrEqual" secondItem="Vhp-Wi-YsA" secondAttribute="trailing" constant="12" id="Aoh-be-l3n"/>
+                            <constraint firstItem="2T3-oJ-zPX" firstAttribute="centerY" secondItem="Vhp-Wi-YsA" secondAttribute="centerY" id="IAd-z1-kEf"/>
+                            <constraint firstItem="2T3-oJ-zPX" firstAttribute="leading" secondItem="Vhp-Wi-YsA" secondAttribute="trailing" constant="3" id="KfX-tO-KFE"/>
                             <constraint firstItem="GW3-Oz-aPr" firstAttribute="centerY" secondItem="3bd-Vo-rTM" secondAttribute="centerY" id="Mw8-KH-Nlc"/>
-                            <constraint firstItem="V3Z-gz-k2w" firstAttribute="bottom" secondItem="GW3-Oz-aPr" secondAttribute="bottom" id="XDN-3Q-VsG"/>
+                            <constraint firstItem="dcn-Rh-TwP" firstAttribute="bottom" secondItem="GW3-Oz-aPr" secondAttribute="bottom" constant="2" id="NAq-1W-bux"/>
                             <constraint firstAttribute="trailing" secondItem="C2d-wO-ajH" secondAttribute="trailing" constant="14" id="a77-uB-Due"/>
-                            <constraint firstItem="V3Z-gz-k2w" firstAttribute="centerX" secondItem="GW3-Oz-aPr" secondAttribute="centerX" id="cQw-k2-Hvh"/>
                             <constraint firstItem="C2d-wO-ajH" firstAttribute="centerY" secondItem="Vhp-Wi-YsA" secondAttribute="centerY" id="cZb-Vp-Luy"/>
                             <constraint firstItem="GW3-Oz-aPr" firstAttribute="leading" secondItem="3bd-Vo-rTM" secondAttribute="leading" constant="14" id="g2u-Nh-Bgq"/>
-                            <constraint firstItem="Vhp-Wi-YsA" firstAttribute="leading" secondItem="qqr-xe-xWm" secondAttribute="trailing" constant="4" id="qXP-PU-oDm"/>
-                            <constraint firstItem="qqr-xe-xWm" firstAttribute="leading" secondItem="GW3-Oz-aPr" secondAttribute="trailing" constant="11" id="ufc-42-4db"/>
-                            <constraint firstItem="Vhp-Wi-YsA" firstAttribute="centerY" secondItem="qqr-xe-xWm" secondAttribute="centerY" id="wDN-FY-zqd"/>
+                            <constraint firstItem="Vhp-Wi-YsA" firstAttribute="leading" secondItem="GW3-Oz-aPr" secondAttribute="trailing" constant="11" id="yVr-KY-v8z"/>
+                            <constraint firstItem="dcn-Rh-TwP" firstAttribute="centerX" secondItem="GW3-Oz-aPr" secondAttribute="centerX" id="zau-cl-15M"/>
                         </constraints>
                         <userDefinedRuntimeAttributes>
                             <userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
@@ -103,18 +120,17 @@
                 <outlet property="chatButton" destination="C2d-wO-ajH" id="F2p-LE-BIc"/>
                 <outlet property="memberLogo" destination="GW3-Oz-aPr" id="sPh-qx-eoq"/>
                 <outlet property="memberName" destination="Vhp-Wi-YsA" id="5VD-Ix-Oua"/>
-                <outlet property="nameLeft" destination="qXP-PU-oDm" id="xZu-cz-adF"/>
-                <outlet property="ownerImage" destination="qqr-xe-xWm" id="1qi-YL-kwV"/>
-                <outlet property="ownerWidth" destination="d6B-m0-bcK" id="Yus-cM-ofV"/>
-                <outlet property="typeView" destination="V3Z-gz-k2w" id="OnM-Id-B8X"/>
+                <outlet property="ownerTagView" destination="dcn-Rh-TwP" id="QaV-5P-xyI"/>
+                <outlet property="typeView" destination="2T3-oJ-zPX" id="2zr-D1-GLS"/>
+                <outlet property="typeViewWidth" destination="KLd-9O-eWg" id="IJk-YD-JRz"/>
             </connections>
             <point key="canvasLocation" x="131.8840579710145" y="63.616071428571423"/>
         </tableViewCell>
     </objects>
     <resources>
-        <image name="chat_talentList" width="44" height="14"/>
-        <image name="group_ownerList" width="34" height="18"/>
+        <image name="group_role_teacher" width="41" height="20"/>
         <image name="tenant_chat_chat" width="22" height="22"/>
+        <image name="user_avatarRectangle" width="44" height="44"/>
         <systemColor name="systemBackgroundColor">
             <color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
         </systemColor>

+ 23 - 21
KulexiuForStudent/KulexiuForStudent/Module/Chat/Group/View/GroupSettingBodyView.m

@@ -8,6 +8,7 @@
 #import "GroupSettingBodyView.h"
 #import "GroupMemberModel.h"
 #import "GroupListModel.h"
+#import "GroupOwnerTagView.h"
 
 typedef void(^ChooseMemberCallback)(NSString *targetId);
 
@@ -19,11 +20,11 @@ typedef void(^ChooseMemberCallback)(NSString *targetId);
 
 @property (nonatomic, strong) NSString *targetId;
 
-@property (nonatomic, strong) UIImageView *roleTypeView;
-
 @property (nonatomic, copy) ChooseMemberCallback callback;
 
-- (void)configMemberWithUrl:(NSString *)url name:(NSString *)name targetId:(NSString *)targetId roleType:(NSString *)roleType callback:(ChooseMemberCallback)callback;
+@property (nonatomic, strong) GroupOwnerTagView *tagView;
+
+- (void)configMemberWithUrl:(NSString *)url name:(NSString *)name targetId:(NSString *)targetId isOwner:(BOOL)isOwner callback:(ChooseMemberCallback)callback;
 
 @end
 
@@ -41,12 +42,12 @@ typedef void(^ChooseMemberCallback)(NSString *targetId);
 - (void)initView {
     
     self.memberLabel = [[UILabel alloc] init];
-    self.memberLabel.textColor = HexRGB(0x666666);
-    [self.memberLabel setFont:[UIFont systemFontOfSize:14.0f]];
+    self.memberLabel.textColor = HexRGB(0x777777);
+    [self.memberLabel setFont:[UIFont systemFontOfSize:13.0f]];
     [self.memberLabel setTextAlignment:NSTextAlignmentCenter];
     [self addSubview:self.memberLabel];
     [self.memberLabel mas_makeConstraints:^(MASConstraintMaker *make) {
-        make.width.mas_equalTo(self.mas_width);
+        make.width.mas_equalTo(45);
         make.centerX.mas_equalTo(self.mas_centerX);
         make.height.mas_equalTo(20);
         make.bottom.mas_equalTo(self.mas_bottom).offset(-19);
@@ -61,22 +62,21 @@ typedef void(^ChooseMemberCallback)(NSString *targetId);
     [self addSubview:self.memberLogo];
     [self.memberLogo mas_makeConstraints:^(MASConstraintMaker *make) {
         make.centerX.mas_equalTo(self.mas_centerX);
-        make.width.height.mas_equalTo(40);
+        make.width.height.mas_equalTo(45);
         make.bottom.mas_equalTo(self.memberLabel.mas_top).offset(-2);
     }];
     UITapGestureRecognizer *tapGesture = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(tapAction:)];
     [self addGestureRecognizer:tapGesture];
     
-    self.roleTypeView = [[UIImageView alloc] initWithImage:[UIImage imageNamed:@"chat_teacherTag"]];
-    [self addSubview:self.roleTypeView];
-    [self.roleTypeView mas_makeConstraints:^(MASConstraintMaker *make) {
+    self.tagView = [GroupOwnerTagView shareInstance];
+    [self addSubview:self.tagView];
+    [self.tagView mas_makeConstraints:^(MASConstraintMaker *make) {
         make.width.mas_equalTo(40);
+        make.height.mas_equalTo(15);
         make.centerX.mas_equalTo(self.memberLogo.mas_centerX);
-        make.height.mas_equalTo(13);
-        make.bottom.mas_equalTo(self.memberLogo.mas_bottom);
+        make.bottom.mas_equalTo(self.memberLogo.mas_bottom).offset(2);
     }];
-    self.roleTypeView.hidden = YES;
-    
+    self.tagView.hidden = YES;
 }
 
 - (void)tapAction:(UITapGestureRecognizer *)gesture {
@@ -85,20 +85,23 @@ typedef void(^ChooseMemberCallback)(NSString *targetId);
     }
 }
 
-- (void)configMemberWithUrl:(NSString *)url name:(NSString *)name targetId:(NSString *)targetId roleType:(NSString *)roleType callback:(ChooseMemberCallback)callback {
+
+
+- (void)configMemberWithUrl:(NSString *)url name:(NSString *)name targetId:(NSString *)targetId isOwner:(BOOL)isOwner callback:(ChooseMemberCallback)callback {
     if (callback) {
         self.callback = callback;
     }
     [self.memberLogo sd_setImageWithURL:[NSURL URLWithString:[url getUrlEndcodeString]] placeholderImage:[UIImage imageNamed:CHAT_USER_DEFAULT_LOGO]];
     self.memberLabel.text = [NSString returnNoNullStringWithString:name];
     self.targetId = targetId;
-    if ([roleType isEqualToString:@"TEACHER"]) {
-        self.roleTypeView.hidden = NO;
+    if (isOwner) {
+        self.tagView.hidden = NO;
     }
     else {
-        self.roleTypeView.hidden = YES;
+        self.tagView.hidden = YES;
     }
 }
+
 @end
 
 
@@ -177,9 +180,8 @@ typedef void(^ChooseMemberCallback)(NSString *targetId);
         CGRect frame = CGRectMake(width * i, 0, width, 100);
         GroupMemberModel *model = [studentArray objectAtIndex:i];
         MemberView *view = [[MemberView alloc] initWithFrame:frame];
-
-        [view configMemberWithUrl:model.avatar name:model.nickname targetId:model.imUserId roleType:model.roleType callback:^(NSString *targetId) {
-
+        [view configMemberWithUrl:model.avatar name:model.nickname targetId:model.imUserId isOwner:model.isAdmin callback:^(NSString *targetId) {
+                    
         }];
         [self.memberView addSubview:view];
     }

+ 1 - 1
KulexiuForStudent/KulexiuForStudent/Module/Chat/Group/View/GroupSettingBodyView.xib

@@ -316,7 +316,7 @@
                     <constraints>
                         <constraint firstAttribute="height" constant="44" id="zlf-6G-YkC"/>
                     </constraints>
-                    <state key="normal" title="发消息"/>
+                    <state key="normal" title="退出群聊"/>
                     <userDefinedRuntimeAttributes>
                         <userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
                             <real key="value" value="22"/>

+ 2 - 2
KulexiuForStudent/KulexiuForStudent/Module/Chat/View/ChatAddressBodyView.m

@@ -427,14 +427,14 @@
 }
 
 - (CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section {
-    if (self.selectIndex == 1) {
+    if (self.selectIndex == 0) {
         return CGFLOAT_MIN;
     }
     return 30;
 }
 
 - (UIView *)tableView:(UITableView *)tableView viewForHeaderInSection:(NSInteger)section {
-    if (self.selectIndex == 1) {
+    if (self.selectIndex == 0) {
         return [UIView new];
     }
     UIView *view = [[UIView alloc] initWithFrame:CGRectMake(0, 0, kScreenWidth, 30)];

+ 2 - 0
KulexiuForStudent/KulexiuForStudent/Module/Chat/View/ContractListCell.m

@@ -26,6 +26,7 @@
     self.selectionStyle = UITableViewCellSelectionStyleNone;
 }
 
+
 - (void)configWithSource:(id)sourceModel {
     if ([sourceModel isKindOfClass:[FriendListModel class]]) {
         FriendListModel *model = sourceModel;
@@ -37,6 +38,7 @@
             self.friendName.text = model.friendNickname;
         }
         self.friendName.text = [NSString returnNoNullStringWithString:model.friendNickname];
+        
         if ([model.roleType isEqualToString:@"TEACHER"]) {
             self.roleType.hidden = NO;
         }

+ 11 - 10
KulexiuForStudent/KulexiuForStudent/Module/Chat/View/ContractListCell.xib

@@ -1,9 +1,9 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="21225" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="21701" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
     <device id="retina6_1" orientation="portrait" appearance="light"/>
     <dependencies>
         <deployment identifier="iOS"/>
-        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21207"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21679"/>
         <capability name="Safe area layout guides" minToolsVersion="9.0"/>
         <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
     </dependencies>
@@ -45,22 +45,23 @@
                             <constraint firstAttribute="height" constant="1" id="pLM-MY-tjk"/>
                         </constraints>
                     </view>
-                    <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="chat_talentList" translatesAutoresizingMaskIntoConstraints="NO" id="wE9-mv-fQZ">
-                        <rect key="frame" x="14" y="50.5" width="44" height="14"/>
+                    <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="group_role_teacher" translatesAutoresizingMaskIntoConstraints="NO" id="PIX-mL-Eal">
+                        <rect key="frame" x="122" y="32.5" width="41" height="20"/>
                         <constraints>
-                            <constraint firstAttribute="height" constant="14" id="31K-VC-pL8"/>
-                            <constraint firstAttribute="width" constant="44" id="hUJ-sa-RuA"/>
+                            <constraint firstAttribute="height" constant="20" id="7rj-gT-out"/>
+                            <constraint firstAttribute="width" constant="41" id="GOS-an-xk5"/>
                         </constraints>
                     </imageView>
                 </subviews>
                 <constraints>
                     <constraint firstItem="8fl-pa-IHx" firstAttribute="centerY" secondItem="vI1-v5-uMm" secondAttribute="centerY" id="9PL-c3-9J3"/>
-                    <constraint firstItem="wE9-mv-fQZ" firstAttribute="centerX" secondItem="vI1-v5-uMm" secondAttribute="centerX" id="Bi2-yQ-N9p"/>
                     <constraint firstItem="ZD7-0R-OoK" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="72" id="DPF-fF-mtx"/>
+                    <constraint firstItem="PIX-mL-Eal" firstAttribute="centerY" secondItem="8fl-pa-IHx" secondAttribute="centerY" id="QGb-pT-BxN"/>
                     <constraint firstAttribute="bottom" secondItem="ZD7-0R-OoK" secondAttribute="bottom" id="Qy0-N6-dQU"/>
+                    <constraint firstItem="PIX-mL-Eal" firstAttribute="leading" secondItem="8fl-pa-IHx" secondAttribute="trailing" constant="4" id="Wj1-dm-hei"/>
+                    <constraint firstAttribute="trailing" relation="greaterThanOrEqual" secondItem="PIX-mL-Eal" secondAttribute="trailing" constant="12" id="Z1L-3T-Z8D"/>
                     <constraint firstItem="8fl-pa-IHx" firstAttribute="leading" secondItem="vI1-v5-uMm" secondAttribute="trailing" constant="11" id="fdz-o1-pUv"/>
                     <constraint firstAttribute="trailing" secondItem="ZD7-0R-OoK" secondAttribute="trailing" id="qkd-cr-TeW"/>
-                    <constraint firstItem="wE9-mv-fQZ" firstAttribute="bottom" secondItem="vI1-v5-uMm" secondAttribute="bottom" id="vb6-na-6sB"/>
                     <constraint firstItem="vI1-v5-uMm" firstAttribute="centerY" secondItem="H2p-sc-9uM" secondAttribute="centerY" id="vgm-ZS-Nds"/>
                     <constraint firstItem="vI1-v5-uMm" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="14" id="yHs-ea-3Xd"/>
                 </constraints>
@@ -70,13 +71,13 @@
             <connections>
                 <outlet property="friendAvatar" destination="vI1-v5-uMm" id="U0E-W5-93f"/>
                 <outlet property="friendName" destination="8fl-pa-IHx" id="ADl-id-NuZ"/>
-                <outlet property="roleType" destination="wE9-mv-fQZ" id="DhH-hR-dPW"/>
+                <outlet property="roleType" destination="PIX-mL-Eal" id="HlX-dd-1nb"/>
             </connections>
             <point key="canvasLocation" x="178.2608695652174" y="95.424107142857139"/>
         </tableViewCell>
     </objects>
     <resources>
         <image name="chat_personLogo" width="44" height="44"/>
-        <image name="chat_talentList" width="44" height="14"/>
+        <image name="group_role_teacher" width="41" height="20"/>
     </resources>
 </document>

+ 4 - 0
KulexiuForStudent/KulexiuForStudent/Module/Chat/View/GroupListViewCell.m

@@ -37,6 +37,10 @@
             defaultLogo = GROUP_FAN_LOGO;
             typeLogo = @"group_fans";
         }
+        else if ([model.type isEqualToString:@"ORG"]) {
+            defaultLogo = GROUP_TENANT_LOGO;
+            typeLogo = @"group_tenant";
+        }
         else {
             defaultLogo = GROUP_COURSE_LOGO;
             typeLogo = @"group_course";

+ 20 - 0
KulexiuForStudent/KulexiuForStudent/Module/Chat/View/GroupOwnerTagView.h

@@ -0,0 +1,20 @@
+//
+//  GroupOwnerTagView.h
+//  KulexiuForStudent
+//
+//  Created by 王智 on 2023/9/15.
+//
+
+#import <UIKit/UIKit.h>
+
+NS_ASSUME_NONNULL_BEGIN
+
+@interface GroupOwnerTagView : UIView
+
++ (instancetype)shareInstance;
+
+- (void)configBgColor:(UIColor *)color;
+
+@end
+
+NS_ASSUME_NONNULL_END

+ 29 - 0
KulexiuForStudent/KulexiuForStudent/Module/Chat/View/GroupOwnerTagView.m

@@ -0,0 +1,29 @@
+//
+//  GroupOwnerTagView.m
+//  KulexiuForStudent
+//
+//  Created by 王智 on 2023/9/15.
+//
+
+#import "GroupOwnerTagView.h"
+
+@implementation GroupOwnerTagView
+
+
++ (instancetype)shareInstance {
+    GroupOwnerTagView *view = [[[NSBundle mainBundle] loadNibNamed:@"GroupOwnerTagView" owner:nil options:nil] firstObject];
+    return view;
+}
+
+- (void)configBgColor:(UIColor *)color {
+    self.backgroundColor = color;
+}
+/*
+// Only override drawRect: if you perform custom drawing.
+// An empty implementation adversely affects performance during animation.
+- (void)drawRect:(CGRect)rect {
+    // Drawing code
+}
+*/
+
+@end

+ 39 - 0
KulexiuForStudent/KulexiuForStudent/Module/Chat/View/GroupOwnerTagView.xib

@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="21701" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
+    <device id="retina6_12" orientation="portrait" appearance="light"/>
+    <dependencies>
+        <deployment identifier="iOS"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21679"/>
+        <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
+    </dependencies>
+    <objects>
+        <placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
+        <placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
+        <view contentMode="scaleToFill" id="iN0-l3-epB" customClass="GroupOwnerTagView">
+            <rect key="frame" x="0.0" y="0.0" width="40" height="15"/>
+            <autoresizingMask key="autoresizingMask"/>
+            <subviews>
+                <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="群主" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Yoi-DH-Nlx">
+                    <rect key="frame" x="8.6666666666666643" y="0.66666666666666696" width="23" height="14"/>
+                    <fontDescription key="fontDescription" type="system" weight="medium" pointSize="11"/>
+                    <color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                    <nil key="highlightedColor"/>
+                </label>
+            </subviews>
+            <color key="backgroundColor" red="1" green="0.30196078431372547" blue="0.44705882352941173" alpha="1" colorSpace="calibratedRGB"/>
+            <constraints>
+                <constraint firstItem="Yoi-DH-Nlx" firstAttribute="centerY" secondItem="iN0-l3-epB" secondAttribute="centerY" id="8H6-gz-IsM"/>
+                <constraint firstItem="Yoi-DH-Nlx" firstAttribute="centerX" secondItem="iN0-l3-epB" secondAttribute="centerX" id="RoA-1a-Bac"/>
+            </constraints>
+            <nil key="simulatedTopBarMetrics"/>
+            <nil key="simulatedBottomBarMetrics"/>
+            <freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
+            <userDefinedRuntimeAttributes>
+                <userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
+                    <real key="value" value="7.5"/>
+                </userDefinedRuntimeAttribute>
+            </userDefinedRuntimeAttributes>
+            <point key="canvasLocation" x="-182.44274809160305" y="-71.83098591549296"/>
+        </view>
+    </objects>
+</document>

+ 1 - 0
KulexiuForStudent/KulexiuForStudent/Module/Course/Controller/CourseViewController.m

@@ -230,6 +230,7 @@
     self.calendar.appearance.subtitleTodayColor = HexRGB(0xff6363);
     self.calendar.appearance.subtitleDefaultColor = HexRGB(0xff6363);
     self.calendar.appearance.subtitleSelectionColor = [UIColor whiteColor];
+    self.calendar.appearance.titleTodayColor = THEMECOLOR;
     self.calendar.dataSource = self;
     self.calendar.delegate = self;
     //    self.calendar.firstWeekday = 2;

+ 1 - 0
KulexiuForStudent/KulexiuForStudent/Module/Live/Controller/LiveVideoRoomViewController.m

@@ -1285,6 +1285,7 @@ static int clickPraiseBtnTimes  = 0;
 
 #pragma mark -- 退出直播间回掉服务
 - (void)quitNotiferService {
+
     [KSNetworkingManager LiveroomQuit:KS_POST success:^(NSDictionary * _Nonnull dic) {
         if ([dic ks_integerValueForKey:@"errCode"] == 0) {
             NSLog(@"success");

+ 9 - 9
KulexiuForStudent/KulexiuForStudent/Module/Live/Model/KSEnterLiveroomManager.m

@@ -55,15 +55,15 @@ static BOOL isRequestRoomMsg  = NO;
     NSDictionary *configDic = [NSJSONSerialization JSONObjectWithData:jsonData
                                                               options:NSJSONReadingMutableContainers
                                                                 error:&err];
-    BOOL enableRecord = NO;
-    if (configDic) {
-        liveVC.enableChat = ![configDic ks_boolValueForKey:@"whether_chat"];
-        liveVC.enableSeat = ![configDic ks_boolValueForKey:@"whether_mic"];
-        liveVC.enableLike = ![configDic ks_boolValueForKey:@"whether_like"];
-        liveVC.hideCartButton = [configDic ks_integerValueForKey:@"whether_view_shop_cart"] == 1 ? YES : NO;
-        // 是否录制
-        enableRecord = [configDic ks_boolValueForKey:@"whether_video"];
-    }
+//    BOOL enableRecord = NO;
+//    if (configDic) {
+//        liveVC.enableChat = ![configDic ks_boolValueForKey:@"whether_chat"];
+//        liveVC.enableSeat = ![configDic ks_boolValueForKey:@"whether_mic"];
+//        liveVC.enableLike = ![configDic ks_boolValueForKey:@"whether_like"];
+//        liveVC.hideCartButton = [configDic ks_integerValueForKey:@"whether_view_shop_cart"] == 1 ? YES : NO;
+//        // 是否录制
+//        enableRecord = [configDic ks_boolValueForKey:@"whether_video"];
+//    }
     
     
     liveVC.UserSig = [source ks_stringValueForKey:@"userSig"];

+ 2 - 1
KulexiuForStudent/KulexiuForStudent/Module/Live/Model/LiveModuleService.h

@@ -35,9 +35,10 @@ NS_ASSUME_NONNULL_BEGIN
 
 /// 退出直播间
 /// @param post post json
+/// @param quitTime 离开时间
 /// @param success 成功
 /// @param faliure 失败
-+ (void)LiveroomQuit:(NSString *)post success:(void(^)(NSDictionary *dic))success faliure:(void(^)(NSError *error))faliure;
++ (void)LiveroomQuit:(NSString *)post time:(NSInteger)quitTime success:(void(^)(NSDictionary *dic))success faliure:(void(^)(NSError *error))faliure;
 @end
 
 NS_ASSUME_NONNULL_END

+ 4 - 2
KulexiuForStudent/KulexiuForStudent/Module/Live/Model/LiveModuleService.m

@@ -46,14 +46,16 @@
 
 /// 退出直播间
 /// @param post post json
+/// @param quitTime 离开时间
 /// @param success 成功
 /// @param faliure 失败
-+ (void)LiveroomQuit:(NSString *)post success:(void(^)(NSDictionary *dic))success faliure:(void(^)(NSError *error))faliure {
++ (void)LiveroomQuit:(NSString *)post time:(NSInteger)quitTime success:(void(^)(NSDictionary *dic))success faliure:(void(^)(NSError *error))faliure {
     NSString *url = [NSString stringWithFormat:@"%@%@", hostURL, @"/api-student/liveRoom/syncUserStatus"];
     NSMutableDictionary *parm = [NSMutableDictionary dictionary];
     [parm setValue:@"iOS" forKey:@"os"];
     [parm setValue:@"3" forKey:@"status"];
-    [parm setValue:UserDefault(UIDKey) forKey:@"userid"];
+    [parm setValue:UserDefault(IM_USERID) forKey:@"userid"];
+    [parm setValue:@(quitTime) forKey:@"time"];
     [KSNetworkingManager LiveRoomRequest:post url:url parms:@[parm] success:success faliure:faliure];
 }
 @end

+ 2 - 0
KulexiuForStudent/KulexiuForStudent/Module/TXClassRoom/Controller/TXClassroomViewController.m

@@ -922,9 +922,11 @@
         else {
             self.maskView.closeCameraView.hidden = NO;
         }
+        
         [ClassroomService sharedService].currentRoom.currentMaskUserId = currentUserID;
         [TRTC_MANAGER renderLocalUserInView:self.maskView.maskVideoView isCameraEnable:member.cameraEnable];
         [self.view addSubview:self.maskView];
+        [self.maskView configUserAvatar:member.headUrl];
         self.squareOn = YES;
     }
 }

+ 34 - 13
KulexiuForStudent/KulexiuForStudent/Module/TXClassRoom/View/MainContainerView/TXClassroomMainContainer.m

@@ -16,8 +16,9 @@
 
 @property (nonatomic, strong) UIView *tapGestureView;
 
-@property (nonatomic, strong) UIImageView *closeCameraView;
+@property (nonatomic, strong) UIView *closeCameraView;
 
+@property (nonatomic, strong) UIImageView *avatarView;
 
 @end
 
@@ -95,24 +96,27 @@
 - (void)containerViewRenderView:(RoomMember *)member {
     self.videoBackView.hidden = NO;
     self.videoView.hidden = NO;
+    [self.avatarView sd_setImageWithURL:[NSURL URLWithString:[member.headUrl getUrlEndcodeString]] placeholderImage:[UIImage imageNamed:USERDEFAULT_LOGO]];
+
     if([[ClassroomService sharedService].currentRoom.currentMemberId isEqualToString:member.userId]) {
-        if (member.cameraEnable) {
-            self.closeCameraView.hidden = YES;
-        }
-        else {
-            self.closeCameraView.hidden = NO;
-        }
+
         if ([self canRenderVideo:member]) {
             [TRTC_MANAGER renderLocalUserInView:self.videoView isCameraEnable:member.cameraEnable];
             [LocalRenderManager shareInstance].hadRenderMainView = YES;
         }
         
     }else {
-        self.closeCameraView.hidden = YES;
         [LocalRenderManager shareInstance].hadRenderMainView = NO;
 
         [TRTC_MANAGER renderRemoteUser:member.userId inView:self.videoView];
     }
+    
+    if (member.cameraEnable) {
+        self.closeCameraView.hidden = YES;
+    }
+    else {
+        self.closeCameraView.hidden = NO;
+    }
     self.member = member;
     if ([member.userId isEqualToString:[ClassroomService sharedService].currentRoom.currentMember.userId]) {
         [self.displayView configWithName:member.name isShare:YES];
@@ -238,16 +242,33 @@
     return _displayView;
 }
 
-- (UIImageView *)closeCameraView {
+- (UIView *)closeCameraView {
     if (!_closeCameraView) {
-        UIImage *img = [TRTC_MANAGER generalCloseImage];
-        _closeCameraView = [[UIImageView alloc] initWithImage:img];
-        _closeCameraView.backgroundColor = [UIColor clearColor];
-        _closeCameraView.contentMode = UIViewContentModeScaleAspectFill;
+        _closeCameraView = [[UIView alloc] initWithFrame:CGRectZero];
+        _closeCameraView.backgroundColor = HexRGB(0xE9EDF3);
+        [_closeCameraView addSubview:self.avatarView];
+        [self.avatarView mas_makeConstraints:^(MASConstraintMaker *make) {
+            make.centerX.mas_equalTo(_closeCameraView.mas_centerX);
+            make.centerY.mas_equalTo(_closeCameraView.mas_centerY);
+            make.width.height.mas_equalTo(82);
+        }];
     }
     return _closeCameraView;
 }
 
+- (UIImageView *)avatarView {
+    if (!_avatarView) {
+        _avatarView = [[UIImageView alloc] init];
+        _avatarView.layer.cornerRadius = 41;
+        _avatarView.clipsToBounds = YES;
+        _avatarView.layer.borderColor = [UIColor whiteColor].CGColor;
+        _avatarView.layer.borderWidth = 1.0f;
+        _avatarView.contentMode = UIViewContentModeScaleAspectFill;
+    }
+    return _avatarView;
+}
+
+
 - (void)changeVideoFrameFull:(BOOL)isFull {
     if (isFull) {
         CGFloat width = KLandscapeWidth;

+ 3 - 1
KulexiuForStudent/KulexiuForStudent/Module/TXClassRoom/View/MainContainerView/VideoMaskView.h

@@ -12,7 +12,9 @@ NS_ASSUME_NONNULL_BEGIN
 
 @interface VideoMaskView : UIView
 
-@property (nonatomic, strong) UIImageView *closeCameraView;
+@property (nonatomic, strong) UIView *closeCameraView;
+
+- (void)configUserAvatar:(NSString *)avatarUrl;
 
 - (instancetype)initWithFrame:(CGRect)frame;
 

+ 29 - 6
KulexiuForStudent/KulexiuForStudent/Module/TXClassRoom/View/MainContainerView/VideoMaskView.m

@@ -17,9 +17,12 @@
 
 @property (nonatomic, strong) UIView *backView;
 
+@property (nonatomic, strong) UIImageView *avatarView;
+
 @end
 
 @implementation VideoMaskView
+
 - (instancetype)initWithFrame:(CGRect)frame {
     self = [super initWithFrame:frame];
     if(self) {
@@ -49,6 +52,10 @@
     }];
 }
 
+- (void)configUserAvatar:(NSString *)avatarUrl {
+    [self.avatarView sd_setImageWithURL:[NSURL URLWithString:[avatarUrl getUrlEndcodeString]] placeholderImage:[UIImage imageNamed:USERDEFAULT_LOGO]];
+}
+
 - (void)addDismisTarget:(id)target action:(SEL)act{
     [self.dismissBtn addTarget:target action:act forControlEvents:UIControlEventTouchUpInside];
 }
@@ -94,15 +101,31 @@
     return _dismissBtn;
 }
 
-- (UIImageView *)closeCameraView {
+- (UIView *)closeCameraView {
     if (!_closeCameraView) {
-        UIImage *img = [TRTC_MANAGER generalCloseImage];
-
-        _closeCameraView = [[UIImageView alloc] initWithImage:img];
-        _closeCameraView.backgroundColor = [UIColor clearColor];
-        _closeCameraView.contentMode = UIViewContentModeScaleAspectFill;
+        _closeCameraView = [[UIView alloc] initWithFrame:CGRectZero];
+        _closeCameraView.backgroundColor = HexRGB(0xE9EDF3);
+        [_closeCameraView addSubview:self.avatarView];
+        [self.avatarView mas_makeConstraints:^(MASConstraintMaker *make) {
+            make.centerX.mas_equalTo(_closeCameraView.mas_centerX);
+            make.centerY.mas_equalTo(_closeCameraView.mas_centerY);
+            make.width.height.mas_equalTo(82);
+        }];
     }
     return _closeCameraView;
 }
 
+- (UIImageView *)avatarView {
+    if (!_avatarView) {
+        _avatarView = [[UIImageView alloc] init];
+        _avatarView.layer.cornerRadius = 41;
+        _avatarView.clipsToBounds = YES;
+        _avatarView.layer.borderColor = [UIColor whiteColor].CGColor;
+        _avatarView.layer.borderWidth = 1.0f;
+        _avatarView.contentMode = UIViewContentModeScaleAspectFill;
+    }
+    return _avatarView;
+}
+
+
 @end

+ 35 - 33
KulexiuForStudent/KulexiuForStudent/Module/TXClassRoom/View/VideoList/TXClassroomVideoListCell.m

@@ -18,6 +18,8 @@
 @property (nonatomic, strong) UIView *backGroundView;
 @property (nonatomic, strong) UIView *closeCameraView;
 
+@property (nonatomic, strong) UIImageView *avatarView;
+
 @property (nonatomic, strong) UILabel *nameLable;
 @property (nonatomic, strong) UILabel *handUpLabel;
 
@@ -165,6 +167,8 @@
         self.roleView.hidden = YES;
     }
     else {
+        [self.avatarView sd_setImageWithURL:[NSURL URLWithString:[member.headUrl getUrlEndcodeString]] placeholderImage:[UIImage imageNamed:USERDEFAULT_LOGO]];
+
         self.member = member;
         self.userId = member.userId;
         [self remakeNameLable:member];
@@ -231,12 +235,6 @@
     }
     self.videoView.hidden = NO;
     if([[ClassroomService sharedService].currentRoom.currentMemberId isEqualToString:member.userId]) {
-        if (member.cameraEnable) {
-            self.closeCameraView.hidden = YES;
-        }
-        else {
-            self.closeCameraView.hidden = NO;
-        }
         [TRTC_MANAGER renderLocalUserInView:self.videoView isCameraEnable:member.cameraEnable];
     }else {
         self.closeCameraView.hidden = YES;
@@ -244,6 +242,12 @@
         [TRTC_MANAGER renderRemoteUser:member.userId inView:self.videoView];
     }
     
+    if (member.cameraEnable) {
+        self.closeCameraView.hidden = YES;
+    }
+    else {
+        self.closeCameraView.hidden = NO;
+    }
     BOOL isMicEnable = member.microphoneEnable;
     NSString *imgName = @"";
     if (isMicEnable) {
@@ -328,33 +332,6 @@
     return _backGroundView;
 }
 
-- (UIView *)closeCameraView {
-    if (!_closeCameraView) {
-        _closeCameraView = [[UIView alloc] init];
-        _closeCameraView.backgroundColor = HexRGB(0xE9EDF3);
-        UIView *layerView = [[UIView alloc] initWithFrame:CGRectZero];
-        layerView.backgroundColor = HexRGB(0xffffff);
-        layerView.layer.cornerRadius = 21;
-        [_closeCameraView addSubview:layerView];
-        [layerView mas_makeConstraints:^(MASConstraintMaker *make) {
-            make.centerX.mas_equalTo(_closeCameraView.mas_centerX);
-            make.centerY.mas_equalTo(_closeCameraView.mas_centerY);
-            make.width.height.mas_equalTo(42);
-        }];
-        UIImageView *imageView = [[UIImageView alloc] init];
-        [imageView sd_setImageWithURL:[NSURL URLWithString:[self.member.url getUrlEndcodeString]] placeholderImage:[UIImage imageNamed:USERDEFAULT_LOGO]];
-        imageView.layer.cornerRadius = 20;
-        imageView.clipsToBounds = YES;
-        imageView.contentMode = UIViewContentModeScaleAspectFill;
-        [layerView addSubview:imageView];
-        [imageView mas_makeConstraints:^(MASConstraintMaker *make) {
-            make.centerX.mas_equalTo(_closeCameraView.mas_centerX);
-            make.centerY.mas_equalTo(_closeCameraView.mas_centerY);
-            make.width.height.mas_equalTo(40);
-        }];
-    }
-    return _closeCameraView;
-}
 
 
 - (UIView *)videoView {
@@ -537,5 +514,30 @@
     }];
 }
 
+- (UIView *)closeCameraView {
+    if (!_closeCameraView) {
+        _closeCameraView = [[UIView alloc] initWithFrame:CGRectZero];
+        _closeCameraView.backgroundColor = HexRGB(0xE9EDF3);
+        [_closeCameraView addSubview:self.avatarView];
+        [self.avatarView mas_makeConstraints:^(MASConstraintMaker *make) {
+            make.centerX.mas_equalTo(_closeCameraView.mas_centerX);
+            make.centerY.mas_equalTo(_closeCameraView.mas_centerY);
+            make.width.height.mas_equalTo(42);
+        }];
+    }
+    return _closeCameraView;
+}
+
+- (UIImageView *)avatarView {
+    if (!_avatarView) {
+        _avatarView = [[UIImageView alloc] init];
+        _avatarView.layer.cornerRadius = 21;
+        _avatarView.clipsToBounds = YES;
+        _avatarView.layer.borderColor = [UIColor whiteColor].CGColor;
+        _avatarView.layer.borderWidth = 1.0f;
+        _avatarView.contentMode = UIViewContentModeScaleAspectFill;
+    }
+    return _avatarView;
+}
 
 @end

+ 36 - 2
KulexiuForStudent/KulexiuForStudent/Module/TXLive/Controller/TXLiveRoomViewController.m

@@ -160,6 +160,13 @@ typedef NS_ENUM(NSInteger, MICSTATUS) {
 
 @property (nonatomic, assign) BOOL isConnectedFailed;
 
+#pragma mark --- 时间统计
+// 后端返回进入教室时间戳 ms
+@property (nonatomic, assign) NSTimeInterval enterTime;
+
+// 进入教室时间date
+@property (nonatomic, strong) NSDate *enterDate;
+
 @end
 
 //  用于记录点赞消息连续点击的次数
@@ -371,7 +378,7 @@ static int clickPraiseBtnTimes  = 0;
         }
     });
 }
-
+ 
 - (void)checkPlayerStatus {
     if (self.isCloseRoom) {
         return;
@@ -630,6 +637,10 @@ static int clickPraiseBtnTimes  = 0;
 #pragma mark -- 加入直播间和退出直播间回到服务
 - (void)notiferJoinSuccessToServiceCallback:(void(^)(void))callback {
     [LiveModuleService LiveroomJoinRequest:KS_GET roomId:self.roomId success:^(NSDictionary * _Nonnull dic) {
+        NSTimeInterval enterTime = [dic ks_integerValueForKey:@"data"];
+        self.enterTime = enterTime;
+        NSDate *currentDate = [NSDate date];
+        self.enterDate = currentDate;
         callback();
     } faliure:^(NSError * _Nonnull error) {
         callback();
@@ -637,7 +648,17 @@ static int clickPraiseBtnTimes  = 0;
 }
 
 - (void)quitNotiferService {
-    [LiveModuleService LiveroomQuit:KS_POST success:^(NSDictionary * _Nonnull dic) {
+    NSDate *currentDate = [NSDate date];
+    NSTimeInterval timeInterval = [currentDate timeIntervalSinceDate:self.enterDate];
+    NSInteger time = (NSInteger)(timeInterval *1000);
+    if (self.enterTime > 0) {
+        time = self.enterTime + time;
+    }
+    else {
+        time = (NSInteger)([currentDate timeIntervalSince1970] *1000);
+    }
+    
+    [LiveModuleService LiveroomQuit:KS_POST time:time success:^(NSDictionary * _Nonnull dic) {
         if ([dic ks_integerValueForKey:@"errCode"] == 0) {
             NSLog(@"success");
         }
@@ -1603,6 +1624,19 @@ static int clickPraiseBtnTimes  = 0;
         }
     }
     
+    // 禁止连麦
+    if ([[groupInfo allKeys] containsObject:@"BAN_LINK_MIC"]) {
+        if ([[groupInfo ks_stringValueForKey:@"BAN_LINK_MIC"] isEqualToString:@"ON"]) { // 禁止
+            self.enableSeat = NO;
+        }
+        else {
+            self.enableSeat = YES;
+        }
+    }
+    else {
+        self.enableSeat = YES;
+    }
+    
 }
 
 - (void)setMuteRoomMic:(BOOL)muteRoomMic {