Procházet zdrojové kódy

修改通知显示

Steven před 1 rokem
rodič
revize
c855a63dee

+ 2 - 2
KulexiuForStudent/KulexiuForStudent.xcodeproj/project.pbxproj

@@ -4026,11 +4026,11 @@
 		277933E627E3249F0010E277 /* VoNetworking */ = {
 			isa = PBXGroup;
 			children = (
-				277933E727E3249F0010E277 /* VoNetWorking.h */,
 				277933E827E3249F0010E277 /* Cache */,
-				277933F127E3249F0010E277 /* VoNetworking+RequestManager.m */,
+				277933E727E3249F0010E277 /* VoNetWorking.h */,
 				277933F227E3249F0010E277 /* VoNetWorking.m */,
 				277933F327E3249F0010E277 /* VoNetworking+RequestManager.h */,
+				277933F127E3249F0010E277 /* VoNetworking+RequestManager.m */,
 			);
 			path = VoNetworking;
 			sourceTree = "<group>";

+ 22 - 22
KulexiuForStudent/KulexiuForStudent/Common/Define/KSDomain.h

@@ -33,17 +33,17 @@
 
 // 测试环境
 
-//#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)
-//#define WhiteBoardHostURL (@"https://test.dayaedu.com")
+#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)
+#define WhiteBoardHostURL (@"https://test.dayaedu.com")
 
 // 预生产
 //#define hostURL (@"https://ponline.colexiu.com")
@@ -61,17 +61,17 @@
 
 //#else
 
-#define hostURL (@"https://online.colexiu.com")
-#define SEALCLASSHOST (@"https://online.colexiu.com/api-classroom")
-#define WEBHOST (@"https://online.colexiu.com/student")
-#define TENANT_WEBHOST (@"https://online.colexiu.com//tenant")
-#define SOCKET_URL (@"wss://online.colexiu.com/audioAnalysis")
-#define JSPUSH_ENVIRONMENT (YES)
-#define RCIM_KEY (@"e5t4ouvpe42pa")
-#define SUBMIT_UUID (YES)
-#define CONFIG_TXSDKAPPID (1400799837)
-#define TXOfflinePushCertificateIDForAPNS (39560)
-#define WhiteBoardHostURL (@"https://online.dayaedu.com")
+//#define hostURL (@"https://online.colexiu.com")
+//#define SEALCLASSHOST (@"https://online.colexiu.com/api-classroom")
+//#define WEBHOST (@"https://online.colexiu.com/student")
+//#define TENANT_WEBHOST (@"https://online.colexiu.com//tenant")
+//#define SOCKET_URL (@"wss://online.colexiu.com/audioAnalysis")
+//#define JSPUSH_ENVIRONMENT (YES)
+//#define RCIM_KEY (@"e5t4ouvpe42pa")
+//#define SUBMIT_UUID (YES)
+//#define CONFIG_TXSDKAPPID (1400799837)
+//#define TXOfflinePushCertificateIDForAPNS (39560)
+//#define WhiteBoardHostURL (@"https://online.dayaedu.com")
 
 
 //#endif

+ 12 - 12
KulexiuForStudent/KulexiuForStudent/Common/Tools/VoNetworking/VoNetWorking.m

@@ -282,18 +282,18 @@ static NSTimeInterval   requestTimeout = 15.0f;  // 超时时间
                  parameters:parameters
                     headers:nil
   constructingBodyWithBlock:^(id<AFMultipartFormData>  _Nonnull formData) {
-      NSString *fileName = nil;
-      
-      NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
-      formatter.dateFormat = @"yyyyMMddHHmmss";
-      
-      NSString *day = [formatter stringFromDate:[NSDate date]];
-      
-      fileName = [NSString stringWithFormat:@"%@.%@",day,type];
-      
-      [formData appendPartWithFileData:data name:name fileName:fileName mimeType:mimeType];
-      
-  } progress:^(NSProgress * _Nonnull uploadProgress) {
+        NSString *fileName = nil;
+        
+        NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
+        formatter.dateFormat = @"yyyyMMddHHmmss";
+        
+        NSString *day = [formatter stringFromDate:[NSDate date]];
+        
+        fileName = [NSString stringWithFormat:@"%@.%@",day,type];
+        
+        [formData appendPartWithFileData:data name:name fileName:fileName mimeType:mimeType];
+        
+    } progress:^(NSProgress * _Nonnull uploadProgress) {
       if (progressBlock) progressBlock (uploadProgress.completedUnitCount,uploadProgress.totalUnitCount);
       
   } success:^(NSURLSessionDataTask * _Nonnull task, id  _Nullable responseObject) {

+ 1 - 2
KulexiuForStudent/KulexiuForStudent/InstitutionModule/Mine/Controller/TenantNotiferCenterController.m

@@ -246,8 +246,7 @@
         _tableView.dataSource = self;
         _tableView.separatorStyle = UITableViewCellSeparatorStyleNone;
         [_tableView registerNib:[UINib nibWithNibName:@"TenantNotiferMessageCell" bundle:[NSBundle mainBundle]] forCellReuseIdentifier:@"TenantNotiferMessageCell"];
-        _tableView.estimatedRowHeight = 77.0f;
-        _tableView.rowHeight = UITableViewAutomaticDimension;
+        _tableView.rowHeight = 85.0f;
         UIView *bottomView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, kScreenWidth, 15)];
         bottomView.backgroundColor = [UIColor clearColor];
         _tableView.tableFooterView = bottomView;

+ 1 - 1
KulexiuForStudent/KulexiuForStudent/InstitutionModule/Mine/View/TenantNotiferMessageCell.m

@@ -65,7 +65,7 @@
     NSString *messgage = [NSString returnNoNullStringWithString:self.model.content];
     NSMutableParagraphStyle *paragraphStyle = [[NSMutableParagraphStyle alloc] init];
     [paragraphStyle setLineSpacing:4];//调整行间距
-    paragraphStyle.lineBreakMode = NSLineBreakByTruncatingTail;
+    paragraphStyle.lineBreakMode = NSLineBreakByWordWrapping;
     
     NSMutableAttributedString *attrStr = [[NSMutableAttributedString alloc] initWithString:messgage attributes:@{NSParagraphStyleAttributeName:paragraphStyle,NSFontAttributeName:[UIFont systemFontOfSize:13.0f],NSForegroundColorAttributeName:HexRGB(0x7a7a7a)}];
     self.descMessageLabel.attributedText = attrStr;

+ 8 - 9
KulexiuForStudent/KulexiuForStudent/InstitutionModule/Mine/View/TenantNotiferMessageCell.xib

@@ -1,9 +1,9 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="22155" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="22505" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
     <device id="retina6_12" orientation="portrait" appearance="light"/>
     <dependencies>
         <deployment identifier="iOS"/>
-        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22131"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22504"/>
         <capability name="Safe area layout guides" minToolsVersion="9.0"/>
         <capability name="System colors in document resources" minToolsVersion="11.0"/>
         <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
@@ -11,15 +11,15 @@
     <objects>
         <placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
         <placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
-        <tableViewCell contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" rowHeight="77" id="KGk-i7-Jjw" customClass="TenantNotiferMessageCell">
-            <rect key="frame" x="0.0" y="0.0" width="392" height="77"/>
+        <tableViewCell contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" rowHeight="79" id="KGk-i7-Jjw" customClass="TenantNotiferMessageCell">
+            <rect key="frame" x="0.0" y="0.0" width="392" height="85"/>
             <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
             <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="KGk-i7-Jjw" id="H2p-sc-9uM">
-                <rect key="frame" x="0.0" y="0.0" width="392" height="77"/>
+                <rect key="frame" x="0.0" y="0.0" width="392" height="85"/>
                 <autoresizingMask key="autoresizingMask"/>
                 <subviews>
                     <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="sXQ-qt-Apo">
-                        <rect key="frame" x="0.0" y="0.0" width="392" height="77"/>
+                        <rect key="frame" x="0.0" y="0.0" width="392" height="85"/>
                         <subviews>
                             <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="notifer_unknow" translatesAutoresizingMaskIntoConstraints="NO" id="enL-C5-C4b">
                                 <rect key="frame" x="13" y="16" width="45" height="45"/>
@@ -34,7 +34,7 @@
                                 </userDefinedRuntimeAttributes>
                             </imageView>
                             <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="您好,长笛基础教学·李老师的直播课60分钟后…教学·李老师的直播课60分钟后…" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="2" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="VaQ-F3-F4D">
-                                <rect key="frame" x="68" y="40" width="311" height="21"/>
+                                <rect key="frame" x="68" y="40" width="311" height="31.333333333333329"/>
                                 <fontDescription key="fontDescription" type="system" pointSize="13"/>
                                 <color key="textColor" red="0.46666666666666667" green="0.46666666666666667" blue="0.46666666666666667" alpha="1" colorSpace="calibratedRGB"/>
                                 <nil key="highlightedColor"/>
@@ -80,7 +80,6 @@
                             <constraint firstAttribute="trailing" secondItem="yv6-Zy-niG" secondAttribute="trailing" constant="13" id="Ua4-8b-grZ"/>
                             <constraint firstItem="DUl-Lh-1pe" firstAttribute="top" secondItem="enL-C5-C4b" secondAttribute="top" id="a7v-8v-T9t"/>
                             <constraint firstItem="yv6-Zy-niG" firstAttribute="leading" relation="greaterThanOrEqual" secondItem="4hp-bA-Hl4" secondAttribute="trailing" constant="10" id="bB4-7H-0wV"/>
-                            <constraint firstAttribute="bottom" secondItem="VaQ-F3-F4D" secondAttribute="bottom" constant="16" id="biJ-km-wLb"/>
                             <constraint firstItem="DUl-Lh-1pe" firstAttribute="trailing" secondItem="enL-C5-C4b" secondAttribute="trailing" id="eJ9-uX-ODl"/>
                             <constraint firstItem="enL-C5-C4b" firstAttribute="top" secondItem="sXQ-qt-Apo" secondAttribute="top" constant="16" id="gUN-XK-NpD"/>
                             <constraint firstItem="VaQ-F3-F4D" firstAttribute="top" secondItem="4hp-bA-Hl4" secondAttribute="bottom" constant="2" id="s4z-0X-1DW"/>
@@ -105,7 +104,7 @@
                 <outlet property="timeLabel" destination="yv6-Zy-niG" id="Z9G-gW-5BN"/>
                 <outlet property="topTitleLabel" destination="4hp-bA-Hl4" id="KnM-ZK-7Ua"/>
             </connections>
-            <point key="canvasLocation" x="117.55725190839694" y="11.267605633802818"/>
+            <point key="canvasLocation" x="117.55725190839694" y="-5.2816901408450709"/>
         </tableViewCell>
     </objects>
     <resources>

+ 1 - 2
KulexiuForStudent/KulexiuForStudent/Module/Home/NoticeCenter/Controller/NotiferMessageViewController.m

@@ -342,8 +342,7 @@
         _tableView.dataSource = self;
         _tableView.separatorStyle = UITableViewCellSeparatorStyleNone;
         [_tableView registerNib:[UINib nibWithNibName:@"NotiferMessageCell" bundle:[NSBundle mainBundle]] forCellReuseIdentifier:@"NotiferMessageCell"];
-        _tableView.estimatedRowHeight = 125.0f;
-        _tableView.rowHeight = UITableViewAutomaticDimension;
+        _tableView.rowHeight = 85.0f;
         UIView *bottomView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, kScreenWidth, 15)];
         bottomView.backgroundColor = HexRGB(0xf6f8f9);
         _tableView.tableFooterView = bottomView;

+ 13 - 14
KulexiuForStudent/KulexiuForStudent/Module/Home/NoticeCenter/View/NotiferMessageCell.xib

@@ -1,23 +1,23 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="22155" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="22505" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
     <device id="retina6_1" orientation="portrait" appearance="light"/>
     <dependencies>
         <deployment identifier="iOS"/>
-        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22131"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22504"/>
         <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"/>
-        <tableViewCell autoresizesSubviews="NO" contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" rowHeight="108" id="KGk-i7-Jjw" customClass="NotiferMessageCell">
-            <rect key="frame" x="0.0" y="0.0" width="425" height="108"/>
+        <tableViewCell autoresizesSubviews="NO" contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" rowHeight="93" id="KGk-i7-Jjw" customClass="NotiferMessageCell">
+            <rect key="frame" x="0.0" y="0.0" width="425" height="88"/>
             <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
             <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="KGk-i7-Jjw" id="H2p-sc-9uM">
-                <rect key="frame" x="0.0" y="0.0" width="425" height="108"/>
+                <rect key="frame" x="0.0" y="0.0" width="425" height="88"/>
                 <autoresizingMask key="autoresizingMask"/>
                 <subviews>
                     <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="notifer_unknow" translatesAutoresizingMaskIntoConstraints="NO" id="3FS-75-ZgU">
-                        <rect key="frame" x="16" y="22" width="44" height="44"/>
+                        <rect key="frame" x="16" y="16" width="44" height="44"/>
                         <constraints>
                             <constraint firstAttribute="height" constant="44" id="Abw-Pq-4OW"/>
                             <constraint firstAttribute="width" constant="44" id="cte-lB-Tzl"/>
@@ -29,7 +29,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="dWN-rA-dKm">
-                        <rect key="frame" x="70" y="22" width="65.5" height="22"/>
+                        <rect key="frame" x="70" y="16" width="65.5" height="22"/>
                         <constraints>
                             <constraint firstAttribute="height" constant="22" id="Amz-LZ-Qr5"/>
                         </constraints>
@@ -38,13 +38,13 @@
                         <nil key="highlightedColor"/>
                     </label>
                     <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="您好,长笛基础教学·李老师的直播课60分钟后…教学·李老师的直播课60分钟后…" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="2" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="aCp-hw-uSQ">
-                        <rect key="frame" x="70" y="46" width="339" height="40"/>
-                        <fontDescription key="fontDescription" type="system" pointSize="14"/>
+                        <rect key="frame" x="70" y="40" width="339" height="31.5"/>
+                        <fontDescription key="fontDescription" type="system" pointSize="13"/>
                         <color key="textColor" red="0.47843137254901957" green="0.47843137254901957" blue="0.47843137254901957" alpha="1" colorSpace="calibratedRGB"/>
                         <nil key="highlightedColor"/>
                     </label>
                     <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="2022-3-25" textAlignment="right" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="PnY-EC-LkF">
-                        <rect key="frame" x="334" y="26" width="75" height="14"/>
+                        <rect key="frame" x="334" y="20" width="75" height="14"/>
                         <constraints>
                             <constraint firstAttribute="width" constant="75" id="xi5-Bf-5eR"/>
                         </constraints>
@@ -53,7 +53,7 @@
                         <nil key="highlightedColor"/>
                     </label>
                     <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="heX-9o-hn0">
-                        <rect key="frame" x="140.5" y="19" width="6" height="6"/>
+                        <rect key="frame" x="140.5" y="13" width="6" height="6"/>
                         <color key="backgroundColor" red="1" green="0.074509803921568626" blue="0.074509803921568626" alpha="1" colorSpace="calibratedRGB"/>
                         <constraints>
                             <constraint firstAttribute="width" constant="6" id="4aE-tI-b0y"/>
@@ -67,8 +67,7 @@
                     </view>
                 </subviews>
                 <constraints>
-                    <constraint firstAttribute="bottom" secondItem="aCp-hw-uSQ" secondAttribute="bottom" constant="22" id="0DI-6H-dc0"/>
-                    <constraint firstItem="dWN-rA-dKm" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" constant="22" id="0gk-xb-9OT"/>
+                    <constraint firstItem="dWN-rA-dKm" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" constant="16" id="0gk-xb-9OT"/>
                     <constraint firstItem="PnY-EC-LkF" firstAttribute="leading" relation="greaterThanOrEqual" secondItem="dWN-rA-dKm" secondAttribute="trailing" constant="10" id="9xN-aV-SK3"/>
                     <constraint firstItem="dWN-rA-dKm" firstAttribute="top" secondItem="3FS-75-ZgU" secondAttribute="top" id="BCS-5z-wma"/>
                     <constraint firstItem="dWN-rA-dKm" firstAttribute="leading" secondItem="3FS-75-ZgU" secondAttribute="trailing" constant="10" id="FNS-ca-wiG"/>
@@ -90,7 +89,7 @@
                 <outlet property="timeLabel" destination="PnY-EC-LkF" id="vJS-8I-7KV"/>
                 <outlet property="topTitleLabel" destination="dWN-rA-dKm" id="lsT-AW-Yo5"/>
             </connections>
-            <point key="canvasLocation" x="207.97101449275365" y="58.258928571428569"/>
+            <point key="canvasLocation" x="207.97101449275365" y="53.236607142857139"/>
         </tableViewCell>
     </objects>
     <resources>