Sfoglia il codice sorgente

loading功能优化

Steven 1 anno fa
parent
commit
4c92bbdf77
19 ha cambiato i file con 147 aggiunte e 53 eliminazioni
  1. 8 8
      KulexiuForStudent/KulexiuForStudent.xcodeproj/project.pbxproj
  2. 1 0
      KulexiuForStudent/KulexiuForStudent/Common/Base/KSAccompanyWebViewController.m
  3. 2 4
      KulexiuForStudent/KulexiuForStudent/Common/Base/KSBaseWKWebViewController.m
  4. 6 0
      KulexiuForStudent/KulexiuForStudent/Common/Base/KSNetworkingManager.h
  5. 11 0
      KulexiuForStudent/KulexiuForStudent/Common/Base/KSNetworkingManager.m
  6. 1 1
      KulexiuForStudent/KulexiuForStudent/Common/Base/LoadingManager/KSHudLoagingManager.m
  7. 13 0
      KulexiuForStudent/KulexiuForStudent/Common/Define/KSDomain.h
  8. 2 2
      KulexiuForStudent/KulexiuForStudent/Common/ThirdPart/TZImagePickerController/TZImagePickerController.m
  9. 7 8
      KulexiuForStudent/KulexiuForStudent/InstitutionModule/Home/Controller/TenantMoreViewController.m
  10. 1 1
      KulexiuForStudent/KulexiuForStudent/InstitutionModule/Home/Model/HomeMusicSheetLayout.m
  11. 12 13
      KulexiuForStudent/KulexiuForStudent/Module/Home/Controller/HomeViewController.m
  12. 17 0
      KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/Controller/AboutUsViewController.m
  13. 24 6
      KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/Controller/FeedbackViewController.m
  14. 2 0
      KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/View/AboutUsBodyView.h
  15. 5 0
      KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/View/AboutUsBodyView.m
  16. 24 10
      KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/View/AboutUsBodyView.xib
  17. 2 0
      KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/View/FeedbackBodyView.h
  18. 7 0
      KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/View/FeedbackBodyView.m
  19. 2 0
      KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/View/FeedbackBodyView.xib

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

@@ -8469,11 +8469,11 @@
 				INFOPLIST_KEY_CFBundleDisplayName = "酷乐秀";
 				INFOPLIST_KEY_LSSupportsOpeningDocumentsInPlace = YES;
 				INFOPLIST_KEY_NSAppleMusicUsageDescription = "App需要您的同意访问媒体资料库权限,用于播放媒体服务";
-				INFOPLIST_KEY_NSCameraUsageDescription = "APP需要您的同意,访问您的相机,以便您正常使用上传图片、视频课程等服务";
+				INFOPLIST_KEY_NSCameraUsageDescription = "请开启摄像头权限,打开后可以使用聊天拍摄视频和图片等功能。你可以通过系统“设置”进行权限的管理。";
 				INFOPLIST_KEY_NSLocationWhenInUseUsageDescription = "App需要您的同意访问定位权限,用来记录签到信息";
-				INFOPLIST_KEY_NSMicrophoneUsageDescription = "App需要您的同意访问麦克风权限,用于您的语音服务、视频教学";
-				INFOPLIST_KEY_NSPhotoLibraryAddUsageDescription = "App需要您的同意访问您的相册权限,用于您的图片课件上传服务";
-				INFOPLIST_KEY_NSPhotoLibraryUsageDescription = "App需要您的同意访问您的相册权限,用于您的图片课件上传服务";
+				INFOPLIST_KEY_NSMicrophoneUsageDescription = "请开启麦克风权限,打开后可以使用聊天语音消息和智能评测等功能。你可以通过系统“设置”进行权限的管理。";
+				INFOPLIST_KEY_NSPhotoLibraryAddUsageDescription = "请开启相册权限,打开后可以保存智能评测录制的视频和图片。你可以通过系统“设置”进行权限的管理";
+				INFOPLIST_KEY_NSPhotoLibraryUsageDescription = "请开启相册权限,打开后可以保存智能评测录制的视频和图片。你可以通过系统“设置”进行权限的管理";
 				INFOPLIST_KEY_NSUserTrackingUsageDescription = "App需要您的授权,该标识符将用于向您投进行定制化消息推送服务";
 				INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
 				INFOPLIST_KEY_UILaunchStoryboardName = LaunchScreen;
@@ -8548,11 +8548,11 @@
 				INFOPLIST_KEY_CFBundleDisplayName = "酷乐秀";
 				INFOPLIST_KEY_LSSupportsOpeningDocumentsInPlace = YES;
 				INFOPLIST_KEY_NSAppleMusicUsageDescription = "App需要您的同意访问媒体资料库权限,用于播放媒体服务";
-				INFOPLIST_KEY_NSCameraUsageDescription = "APP需要您的同意,访问您的相机,以便您正常使用上传图片、视频课程等服务";
+				INFOPLIST_KEY_NSCameraUsageDescription = "请开启摄像头权限,打开后可以使用聊天拍摄视频和图片等功能。你可以通过系统“设置”进行权限的管理。";
 				INFOPLIST_KEY_NSLocationWhenInUseUsageDescription = "App需要您的同意访问定位权限,用来记录签到信息";
-				INFOPLIST_KEY_NSMicrophoneUsageDescription = "App需要您的同意访问麦克风权限,用于您的语音服务、视频教学";
-				INFOPLIST_KEY_NSPhotoLibraryAddUsageDescription = "App需要您的同意访问您的相册权限,用于您的图片课件上传服务";
-				INFOPLIST_KEY_NSPhotoLibraryUsageDescription = "App需要您的同意访问您的相册权限,用于您的图片课件上传服务";
+				INFOPLIST_KEY_NSMicrophoneUsageDescription = "请开启麦克风权限,打开后可以使用聊天语音消息和智能评测等功能。你可以通过系统“设置”进行权限的管理。";
+				INFOPLIST_KEY_NSPhotoLibraryAddUsageDescription = "请开启相册权限,打开后可以保存智能评测录制的视频和图片。你可以通过系统“设置”进行权限的管理";
+				INFOPLIST_KEY_NSPhotoLibraryUsageDescription = "请开启相册权限,打开后可以保存智能评测录制的视频和图片。你可以通过系统“设置”进行权限的管理";
 				INFOPLIST_KEY_NSUserTrackingUsageDescription = "App需要您的授权,该标识符将用于向您投进行定制化消息推送服务";
 				INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
 				INFOPLIST_KEY_UILaunchStoryboardName = LaunchScreen;

+ 1 - 0
KulexiuForStudent/KulexiuForStudent/Common/Base/KSAccompanyWebViewController.m

@@ -203,6 +203,7 @@
 }
 
 - (void)initWebView {
+    [self.scrollView removeFromSuperview];
     [self.view addSubview:self.navView];
     CGFloat topHeight = kNaviBarHeight;
     [self.navView mas_makeConstraints:^(MASConstraintMaker *make) {

+ 2 - 4
KulexiuForStudent/KulexiuForStudent/Common/Base/KSBaseWKWebViewController.m

@@ -175,7 +175,7 @@ typedef NS_ENUM(NSInteger, CHOOSETYPE) {
 }
 
 - (void)initWebView {
-    
+    [self.scrollView removeFromSuperview];
     [self.view addSubview:self.navView];
     CGFloat topHeight = kNaviBarHeight;
     if (self.hideTop) {
@@ -239,9 +239,7 @@ 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);

+ 6 - 0
KulexiuForStudent/KulexiuForStudent/Common/Base/KSNetworkingManager.h

@@ -922,6 +922,12 @@ NS_ASSUME_NONNULL_BEGIN
 /// @param success 成功
 /// @param faliure 失败
 + (void)userTenantAlbumRecordRequest:(NSString *)post success:(void(^)(NSDictionary *dic))success faliure:(void(^)(NSError *error))faliure;
+
+/// 查询配置客服电话和手机号
+/// @param post post
+/// @param success 成功
+/// @param faliure 失败
++ (void)queryConfigRequest:(NSString *)post success:(void(^)(NSDictionary *dic))success faliure:(void(^)(NSError *error))faliure;
 @end
 
 NS_ASSUME_NONNULL_END

+ 11 - 0
KulexiuForStudent/KulexiuForStudent/Common/Base/KSNetworkingManager.m

@@ -1786,4 +1786,15 @@
     NSMutableDictionary *parm = [NSMutableDictionary dictionary];
     [self request:post andWithUrl:url and:parm success:success faliure:faliure];
 }
+
+/// 查询配置客服电话和手机号
+/// @param post post
+/// @param success 成功
+/// @param faliure 失败
++ (void)queryConfigRequest:(NSString *)post success:(void(^)(NSDictionary *dic))success faliure:(void(^)(NSError *error))faliure {
+    [self configRequestMethodJSON];
+    NSString *url = [NSString stringWithFormat:@"%@%@", hostURL, @"/api-auth/user/queryConfig"];
+    NSMutableDictionary *parm = [NSMutableDictionary dictionary];
+    [self request:post andWithUrl:url and:parm success:success faliure:faliure];
+}
 @end

+ 1 - 1
KulexiuForStudent/KulexiuForStudent/Common/Base/LoadingManager/KSHudLoagingManager.m

@@ -31,7 +31,7 @@
 - (void)showHUD {
     dispatch_main_async_safe(^{
         [self removeLoadingView];
-        UIWindow *window = [[UIApplication sharedApplication ] keyWindow];
+        UIWindow *window = [NSObject getKeyWindow];
         self.HUD = [window addHUDActivityViewToView:nil
                                                        HintsText:@"加载中..."
                                                            Image:nil

+ 13 - 0
KulexiuForStudent/KulexiuForStudent/Common/Define/KSDomain.h

@@ -41,6 +41,19 @@
 //#define SUBMIT_UUID (NO)
 //#define CONFIG_TXSDKAPPID (1400805079)
 //#define TXOfflinePushCertificateIDForAPNS (39557)
+
+// 预生产
+//#define hostURL (@"https://ponline.colexiu.com")
+//#define SEALCLASSHOST (@"https://ponline.colexiu.com/api-classroom")
+//#define WEBHOST (@"https://ponline.colexiu.com/student")
+//#define TENANT_WEBHOST (@"https://ponline.colexiu.com//tenant")
+//#define SOCKET_URL (@"wss://ponline.colexiu.com/audioAnalysis")
+//#define JSPUSH_ENVIRONMENT (YES)
+//#define RCIM_KEY (@"e5t4ouvpe42pa")
+//#define SUBMIT_UUID (YES)
+//#define CONFIG_TXSDKAPPID (1400799837)
+//#define TXOfflinePushCertificateIDForAPNS (39560)
+
 //#else
 
 //#define hostURL (@"https://online.colexiu.com")

+ 2 - 2
KulexiuForStudent/KulexiuForStudent/Common/ThirdPart/TZImagePickerController/TZImagePickerController.m

@@ -208,7 +208,7 @@
             NSString *appName = [TZCommonTools tz_getAppName];
             NSString *tipText = [NSString stringWithFormat:[NSBundle tz_localizedStringForKey:@"Allow %@ to access your album in \"Settings -> Privacy -> Photos\""],appName];
             _tipLabel.text = tipText;
-            [self.view addSubview:_tipLabel];
+//            [self.view addSubview:_tipLabel];
             
             _settingBtn = [UIButton buttonWithType:UIButtonTypeSystem];
             [_settingBtn setTitle:self.settingBtnTitleStr forState:UIControlStateNormal];
@@ -217,7 +217,7 @@
             [_settingBtn addTarget:self action:@selector(settingBtnClick) forControlEvents:UIControlEventTouchUpInside];
             _settingBtn.autoresizingMask = UIViewAutoresizingFlexibleWidth;
 
-            [self.view addSubview:_settingBtn];
+//            [self.view addSubview:_settingBtn];
             
             if ([PHPhotoLibrary authorizationStatus] == 0) {
                 _timer = [NSTimer scheduledTimerWithTimeInterval:0.2 target:self selector:@selector(observeAuthrizationStatusChange) userInfo:nil repeats:NO];

+ 7 - 8
KulexiuForStudent/KulexiuForStudent/InstitutionModule/Home/Controller/TenantMoreViewController.m

@@ -34,6 +34,9 @@
 #import "SmallToolViewController.h"
 #import "HomeMusicSheetLayout.h"
 
+#define COLLECTION_WIDTH ((NSInteger)(KPortraitWidth * 0.83))
+#define COLLECTION_HEIGHT (243)
+
 @interface TenantMoreViewController ()<UICollectionViewDelegate, UICollectionViewDelegateFlowLayout,UICollectionViewDataSource,TYCyclePagerViewDataSource,TYCyclePagerViewDelegate>
 
 @property (nonatomic, copy) SwitchDarkCallback callback;
@@ -537,8 +540,7 @@
 
     }
     else {
-        NSInteger width = (NSInteger)(KPortraitWidth * 0.83);
-        return CGSizeMake(width, 243);
+        return CGSizeMake(COLLECTION_WIDTH, COLLECTION_HEIGHT);
     }
 }
 
@@ -726,9 +728,8 @@
 
 - (UICollectionView *)recommendMusicCollectionView {
     if (!_recommendMusicCollectionView) {
-        NSInteger width = (NSInteger)(KPortraitWidth * 0.83);
 
-        HomeMusicSheetLayout *layout = [[HomeMusicSheetLayout alloc] initWithSectionInset:UIEdgeInsetsMake(12, 11, 12, KPortraitWidth - width) andMiniLineSapce:10 andMiniInterItemSpace:10 andItemSize:CGSizeMake(width, 243)];
+        HomeMusicSheetLayout *layout = [[HomeMusicSheetLayout alloc] initWithSectionInset:UIEdgeInsetsMake(0, 11, 0, KPortraitWidth - COLLECTION_WIDTH) andMiniLineSapce:10 andMiniInterItemSpace:10 andItemSize:CGSizeMake(COLLECTION_WIDTH, COLLECTION_HEIGHT)];
 
         _recommendMusicCollectionView = [[UICollectionView alloc] initWithFrame:CGRectZero collectionViewLayout:layout];
         _recommendMusicCollectionView.backgroundColor = [UIColor clearColor];
@@ -785,9 +786,8 @@
 
 - (UICollectionView *)newestMusicCollectionView {
     if (!_newestMusicCollectionView) {
-        NSInteger width = (NSInteger)(KPortraitWidth * 0.83);
 
-        HomeMusicSheetLayout *layout = [[HomeMusicSheetLayout alloc] initWithSectionInset:UIEdgeInsetsMake(12, 11, 12, (KPortraitWidth - width)) andMiniLineSapce:10 andMiniInterItemSpace:10 andItemSize:CGSizeMake(width, 243)];
+        HomeMusicSheetLayout *layout = [[HomeMusicSheetLayout alloc] initWithSectionInset:UIEdgeInsetsMake(0, 11, 0, (KPortraitWidth - COLLECTION_WIDTH)) andMiniLineSapce:10 andMiniInterItemSpace:10 andItemSize:CGSizeMake(COLLECTION_WIDTH, COLLECTION_HEIGHT)];
 
         _newestMusicCollectionView = [[UICollectionView alloc] initWithFrame:CGRectZero collectionViewLayout:layout];
         _newestMusicCollectionView.backgroundColor = [UIColor clearColor];
@@ -849,9 +849,8 @@
 
 - (UICollectionView *)musicCollectionView {
     if (!_musicCollectionView) {
-        NSInteger width = (NSInteger)(KPortraitWidth * 0.83);
 
-        HomeMusicSheetLayout *layout = [[HomeMusicSheetLayout alloc] initWithSectionInset:UIEdgeInsetsMake(12, 11, 12, (KPortraitWidth - width)) andMiniLineSapce:10 andMiniInterItemSpace:10 andItemSize:CGSizeMake(width, 243)];
+        HomeMusicSheetLayout *layout = [[HomeMusicSheetLayout alloc] initWithSectionInset:UIEdgeInsetsMake(0, 11, 0, (KPortraitWidth - COLLECTION_WIDTH)) andMiniLineSapce:10 andMiniInterItemSpace:10 andItemSize:CGSizeMake(COLLECTION_WIDTH, COLLECTION_HEIGHT)];
 
         _musicCollectionView = [[UICollectionView alloc] initWithFrame:CGRectZero collectionViewLayout:layout];
         _musicCollectionView.backgroundColor = [UIColor clearColor];

+ 1 - 1
KulexiuForStudent/KulexiuForStudent/InstitutionModule/Home/Model/HomeMusicSheetLayout.m

@@ -65,7 +65,7 @@
 
 - (CGPoint)targetContentOffsetForProposedContentOffset:(CGPoint)proposedContentOffset withScrollingVelocity:(CGPoint)velocity {
     CGFloat pageSpace = [self stepSpace];//计算分页步距
-    CGFloat offsetMax = self.collectionView.contentSize.width - (pageSpace + self.sectionInset.right + self.miniLineSpace);
+    CGFloat offsetMax = self.collectionView.contentSize.width - (pageSpace + self.sectionInset.right);
     CGFloat offsetMin = 0;
     /*修改之前记录的位置,如果小于最小contentsize或者大于最大contentsize则重置值*/
     if (_lastOffset.x<offsetMin) {

+ 12 - 13
KulexiuForStudent/KulexiuForStudent/Module/Home/Controller/HomeViewController.m

@@ -71,8 +71,10 @@
 #import "HomeMusicModel.h"
 
 #import "HomeDragButton.h"
+#import "HomeMusicSheetLayout.h"
 
-
+#define COLLECTION_WIDTH ((NSInteger)(KPortraitWidth * 0.83))
+#define COLLECTION_HEIGHT (320)
 #define BUTTONWIDTH (65)
 #define BUTTONHEIGHT (80)
 
@@ -1511,13 +1513,13 @@
         return CGSizeMake(100, 134);
     }
     else if (collectionView == self.recommendMusicCollectionView) {
-        return CGSizeMake(KPortraitWidth * 0.83, 320);
+        return CGSizeMake(COLLECTION_WIDTH, COLLECTION_HEIGHT);
     }
     else if (collectionView == self.newestMusicCollectionView) {
-        return CGSizeMake(KPortraitWidth * 0.83, 320);
+        return CGSizeMake(COLLECTION_WIDTH, COLLECTION_HEIGHT);
     }
     else if (collectionView == self.musicCollectionView) {
-        return CGSizeMake(KPortraitWidth * 0.83, 320);
+        return CGSizeMake(COLLECTION_WIDTH, COLLECTION_HEIGHT);
     }
     else if (collectionView == self.talentCollectionView) {
         return CGSizeMake(110, 178);
@@ -1858,9 +1860,8 @@
 
 - (UICollectionView *)recommendMusicCollectionView {
     if (!_recommendMusicCollectionView) {
-        UICollectionViewFlowLayout *layout = [[UICollectionViewFlowLayout alloc] init];
-        layout.sectionInset = UIEdgeInsetsMake(12, 14, 12, 14);
-        layout.scrollDirection = UICollectionViewScrollDirectionHorizontal;
+        HomeMusicSheetLayout *layout = [[HomeMusicSheetLayout alloc] initWithSectionInset:UIEdgeInsetsMake(0, 11, 0, KPortraitWidth - COLLECTION_WIDTH) andMiniLineSapce:10 andMiniInterItemSpace:10 andItemSize:CGSizeMake(COLLECTION_WIDTH, COLLECTION_HEIGHT)];
+
         _recommendMusicCollectionView = [[UICollectionView alloc] initWithFrame:CGRectZero collectionViewLayout:layout];
         _recommendMusicCollectionView.backgroundColor = [UIColor clearColor];
         _recommendMusicCollectionView.delegate = self;
@@ -1916,9 +1917,8 @@
 
 - (UICollectionView *)newestMusicCollectionView {
     if (!_newestMusicCollectionView) {
-        UICollectionViewFlowLayout *layout = [[UICollectionViewFlowLayout alloc] init];
-        layout.sectionInset = UIEdgeInsetsMake(12, 14, 12, 14);
-        layout.scrollDirection = UICollectionViewScrollDirectionHorizontal;
+        HomeMusicSheetLayout *layout = [[HomeMusicSheetLayout alloc] initWithSectionInset:UIEdgeInsetsMake(0, 11, 0, KPortraitWidth - COLLECTION_WIDTH) andMiniLineSapce:10 andMiniInterItemSpace:10 andItemSize:CGSizeMake(COLLECTION_WIDTH, COLLECTION_HEIGHT)];
+
         _newestMusicCollectionView = [[UICollectionView alloc] initWithFrame:CGRectZero collectionViewLayout:layout];
         _newestMusicCollectionView.backgroundColor = [UIColor clearColor];
         _newestMusicCollectionView.delegate = self;
@@ -1978,9 +1978,8 @@
 
 - (UICollectionView *)musicCollectionView {
     if (!_musicCollectionView) {
-        UICollectionViewFlowLayout *layout = [[UICollectionViewFlowLayout alloc] init];
-        layout.sectionInset = UIEdgeInsetsMake(12, 14, 12, 14);
-        layout.scrollDirection = UICollectionViewScrollDirectionHorizontal;
+        HomeMusicSheetLayout *layout = [[HomeMusicSheetLayout alloc] initWithSectionInset:UIEdgeInsetsMake(0, 11, 0, KPortraitWidth - COLLECTION_WIDTH) andMiniLineSapce:10 andMiniInterItemSpace:10 andItemSize:CGSizeMake(COLLECTION_WIDTH, COLLECTION_HEIGHT)];
+
         _musicCollectionView = [[UICollectionView alloc] initWithFrame:CGRectZero collectionViewLayout:layout];
         _musicCollectionView.backgroundColor = [UIColor clearColor];
         _musicCollectionView.delegate = self;

+ 17 - 0
KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/Controller/AboutUsViewController.m

@@ -21,6 +21,23 @@
     // Do any additional setup after loading the view.
     [self allocTitle:@"关于我们"];
     [self configUI];
+    [self requestConfig];
+}
+
+- (void)requestConfig {
+    [KSNetworkingManager queryConfigRequest:KS_POST success:^(NSDictionary * _Nonnull dic) {
+        if ([dic ks_integerValueForKey:@"code"] == 200) {
+            NSDictionary *result = [dic ks_dictionaryValueForKey:@"data"];
+            NSString *phone = [result ks_stringValueForKey:@"customerServicePhone"];
+            NSString *email = [result ks_stringValueForKey:@"customerServiceEmail"];
+            [self.bodyView configPhone:phone email:email];
+        }
+        else {
+            
+        }
+    } faliure:^(NSError * _Nonnull error) {
+        
+    }];
 }
 
 - (void)configUI {

+ 24 - 6
KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/Controller/FeedbackViewController.m

@@ -11,6 +11,8 @@
 
 @interface FeedbackViewController ()
 
+@property (nonatomic, strong) FeedbackBodyView *bodyView;
+
 @end
 
 @implementation FeedbackViewController
@@ -21,30 +23,46 @@
     [self allocTitle:@"意见反馈"];
     [self configUI];
     [self countUMEvent];
+    [self requestConfig];
 }
 
+- (void)requestConfig {
+    [KSNetworkingManager queryConfigRequest:KS_POST success:^(NSDictionary * _Nonnull dic) {
+        if ([dic ks_integerValueForKey:@"code"] == 200) {
+            NSDictionary *result = [dic ks_dictionaryValueForKey:@"data"];
+            NSString *phone = [result ks_stringValueForKey:@"customerServicePhone"];
+            NSString *email = [result ks_stringValueForKey:@"customerServiceEmail"];
+            [self.bodyView configPhone:phone email:email];
+        }
+        else {
+            
+        }
+    } faliure:^(NSError * _Nonnull error) {
+        
+    }];
+}
 
 - (void)countUMEvent {
     [USER_MANAGER sendUMEvent:@"klx_feedback"];
 }
 
 - (void)configUI {
-    FeedbackBodyView *bodyView = [FeedbackBodyView shareInstance];
-    [self.scrollView addSubview:bodyView];
+    self.bodyView = [FeedbackBodyView shareInstance];
+    [self.scrollView addSubview:self.bodyView];
     CGFloat height = kScreenHeight - kNaviBarHeight - iPhoneXSafeBottomMargin > 530 ?  kScreenHeight - kNaviBarHeight - iPhoneXSafeBottomMargin : 530;
-    [bodyView mas_makeConstraints:^(MASConstraintMaker *make) {
+    [self.bodyView mas_makeConstraints:^(MASConstraintMaker *make) {
         make.top.mas_equalTo(self.scrollView.mas_top);
         make.right.left.mas_equalTo(self.view);
         make.height.mas_equalTo(height);
     }];
     KSWeakSelf(weakSelf);
-    [bodyView submitActionCallback:^(NSString *submitStr, NSString *contactStr) {
+    [self.bodyView submitActionCallback:^(NSString *submitStr, NSString *contactStr) {
         // 提交
         [weakSelf submitWithPhone:contactStr suggestion:submitStr];
     }];
     [self.scrollView setContentSize:CGSizeMake(kScreenWidth, height)];
-    bodyView.buttonColor = CLIENT_THEMECOLOR;
-    bodyView.inputText.tintColor = CLIENT_THEMECOLOR;
+    self.bodyView.buttonColor = CLIENT_THEMECOLOR;
+    self.bodyView.inputText.tintColor = CLIENT_THEMECOLOR;
 }
 
 - (void)submitWithPhone:(NSString *)phone suggestion:(NSString *)suggession {

+ 2 - 0
KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/View/AboutUsBodyView.h

@@ -13,6 +13,8 @@ NS_ASSUME_NONNULL_BEGIN
 
 + (instancetype)shareInstance;
 
+- (void)configPhone:(NSString *)phone email:(NSString *)email;
+
 @end
 
 NS_ASSUME_NONNULL_END

+ 5 - 0
KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/View/AboutUsBodyView.m

@@ -24,6 +24,11 @@
     self.emailLabel.text = @"klx@kulexiu999.onexmail.com";
 }
 
+- (void)configPhone:(NSString *)phone email:(NSString *)email {
+    self.phoneLabel.text = [NSString returnNoNullStringWithString:phone];
+    self.emailLabel.text = [NSString returnNoNullStringWithString:email];
+}
+
 + (instancetype)shareInstance {
     AboutUsBodyView *view = [[[NSBundle mainBundle] loadNibNamed:@"AboutUsBodyView" owner:nil options:nil] firstObject];
     return view;

+ 24 - 10
KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/View/AboutUsBodyView.xib

@@ -1,9 +1,9 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="20037" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="21507" 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="20020"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21505"/>
         <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
     </dependencies>
     <objects>
@@ -17,10 +17,10 @@
                     <rect key="frame" x="14" y="15" width="386" height="300"/>
                     <subviews>
                         <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="klx_logo" translatesAutoresizingMaskIntoConstraints="NO" id="cTa-D0-od4">
-                            <rect key="frame" x="129.5" y="42" width="127" height="42"/>
+                            <rect key="frame" x="125.5" y="42" width="135" height="40"/>
                         </imageView>
                         <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="版本号:1.0.0" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="7sa-Ud-PzI">
-                            <rect key="frame" x="149.5" y="95" width="87" height="20"/>
+                            <rect key="frame" x="149.5" y="93" width="87" height="20"/>
                             <constraints>
                                 <constraint firstAttribute="height" constant="20" id="Va0-Ci-tdX"/>
                             </constraints>
@@ -32,13 +32,19 @@
                             <rect key="frame" x="0.0" y="245" width="386" height="50"/>
                             <subviews>
                                 <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="E-mail" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="zan-am-t8E">
-                                    <rect key="frame" x="16" y="15" width="48.5" height="20"/>
+                                    <rect key="frame" x="16" y="15" width="75" height="20"/>
+                                    <constraints>
+                                        <constraint firstAttribute="width" constant="75" id="ReV-Xi-cJo"/>
+                                    </constraints>
                                     <fontDescription key="fontDescription" type="system" pointSize="17"/>
                                     <color key="textColor" red="0.20000000000000001" green="0.20000000000000001" blue="0.20000000000000001" alpha="1" colorSpace="calibratedRGB"/>
                                     <nil key="highlightedColor"/>
                                 </label>
-                                <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="cnn-JH-ETQ">
-                                    <rect key="frame" x="370" y="25" width="0.0" height="0.0"/>
+                                <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="" textAlignment="right" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="cnn-JH-ETQ">
+                                    <rect key="frame" x="370" y="14" width="0.0" height="22"/>
+                                    <constraints>
+                                        <constraint firstAttribute="height" constant="22" id="gTK-eX-Fag"/>
+                                    </constraints>
                                     <fontDescription key="fontDescription" type="system" pointSize="17"/>
                                     <color key="textColor" red="0.59999999999999998" green="0.59999999999999998" blue="0.59999999999999998" alpha="1" colorSpace="calibratedRGB"/>
                                     <nil key="highlightedColor"/>
@@ -48,6 +54,7 @@
                             <constraints>
                                 <constraint firstItem="zan-am-t8E" firstAttribute="centerY" secondItem="Llz-E9-UuO" secondAttribute="centerY" id="J0e-zN-IpI"/>
                                 <constraint firstAttribute="height" constant="50" id="M1m-bo-gOH"/>
+                                <constraint firstItem="cnn-JH-ETQ" firstAttribute="leading" relation="greaterThanOrEqual" secondItem="zan-am-t8E" secondAttribute="trailing" constant="12" id="T2E-p6-3sf"/>
                                 <constraint firstItem="zan-am-t8E" firstAttribute="leading" secondItem="Llz-E9-UuO" secondAttribute="leading" constant="16" id="XIq-kX-qbY"/>
                                 <constraint firstItem="cnn-JH-ETQ" firstAttribute="centerY" secondItem="Llz-E9-UuO" secondAttribute="centerY" id="xyz-wD-GMm"/>
                                 <constraint firstAttribute="trailing" secondItem="cnn-JH-ETQ" secondAttribute="trailing" constant="16" id="zTa-6I-9Hc"/>
@@ -57,13 +64,19 @@
                             <rect key="frame" x="0.0" y="195" width="386" height="50"/>
                             <subviews>
                                 <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="客服电话" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="sAj-jF-RYu">
-                                    <rect key="frame" x="16" y="15" width="69.5" height="20"/>
+                                    <rect key="frame" x="16" y="15" width="75" height="20"/>
+                                    <constraints>
+                                        <constraint firstAttribute="width" constant="75" id="rTN-jW-vMs"/>
+                                    </constraints>
                                     <fontDescription key="fontDescription" type="system" pointSize="17"/>
                                     <color key="textColor" red="0.20000000000000001" green="0.20000000000000001" blue="0.20000000000000001" alpha="1" colorSpace="calibratedRGB"/>
                                     <nil key="highlightedColor"/>
                                 </label>
                                 <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="v4W-Tc-Z7P">
-                                    <rect key="frame" x="370" y="25" width="0.0" height="0.0"/>
+                                    <rect key="frame" x="370" y="14" width="0.0" height="22"/>
+                                    <constraints>
+                                        <constraint firstAttribute="height" constant="22" id="ZiM-nf-O52"/>
+                                    </constraints>
                                     <fontDescription key="fontDescription" type="system" pointSize="17"/>
                                     <color key="textColor" red="0.59999999999999998" green="0.59999999999999998" blue="0.59999999999999998" alpha="1" colorSpace="calibratedRGB"/>
                                     <nil key="highlightedColor"/>
@@ -86,6 +99,7 @@
                                 <constraint firstItem="uiK-CI-oZC" firstAttribute="leading" secondItem="Ebq-nd-C8r" secondAttribute="leading" constant="10" id="kNb-qR-XQk"/>
                                 <constraint firstAttribute="height" constant="50" id="lTh-2Z-bZ3"/>
                                 <constraint firstAttribute="bottom" secondItem="uiK-CI-oZC" secondAttribute="bottom" id="s3I-hR-ozV"/>
+                                <constraint firstItem="v4W-Tc-Z7P" firstAttribute="leading" relation="greaterThanOrEqual" secondItem="sAj-jF-RYu" secondAttribute="trailing" constant="12" id="tXX-hb-3OP"/>
                             </constraints>
                         </view>
                     </subviews>
@@ -139,6 +153,6 @@
         </view>
     </objects>
     <resources>
-        <image name="klx_logo" width="127" height="42"/>
+        <image name="klx_logo" width="135" height="40"/>
     </resources>
 </document>

+ 2 - 0
KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/View/FeedbackBodyView.h

@@ -21,6 +21,8 @@ NS_ASSUME_NONNULL_BEGIN
 
 - (void)submitActionCallback:(SubmitAction)action;
 
+- (void)configPhone:(NSString *)phone email:(NSString *)email;
+
 @end
 
 NS_ASSUME_NONNULL_END

+ 7 - 0
KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/View/FeedbackBodyView.m

@@ -35,6 +35,13 @@
     }
     _emailContract.text = orgEmail;
 }
+- (void)configPhone:(NSString *)phone email:(NSString *)email {
+    if (![NSString isEmptyString:email]) {
+        self.emailContract.text = [NSString stringWithFormat:@"邮箱:%@", email];
+    }
+}
+
+
 
 + (instancetype)shareInstance {
     FeedbackBodyView *view = [[[NSBundle mainBundle] loadNibNamed:@"FeedbackBodyView" owner:nil options:nil] firstObject];

+ 2 - 0
KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/View/FeedbackBodyView.xib

@@ -117,6 +117,7 @@
                 <constraint firstItem="xej-UK-bQu" firstAttribute="top" secondItem="C3X-28-3eB" secondAttribute="bottom" constant="10" id="AOy-TT-LD9"/>
                 <constraint firstItem="xej-UK-bQu" firstAttribute="leading" secondItem="C3X-28-3eB" secondAttribute="leading" id="Him-df-kQK"/>
                 <constraint firstItem="DoC-1c-3dy" firstAttribute="leading" secondItem="xej-UK-bQu" secondAttribute="leading" id="L7H-FM-5j8"/>
+                <constraint firstAttribute="trailing" relation="greaterThanOrEqual" secondItem="ZfN-9l-0US" secondAttribute="trailing" constant="10" id="M4o-mj-qpf"/>
                 <constraint firstItem="DoC-1c-3dy" firstAttribute="top" secondItem="xej-UK-bQu" secondAttribute="bottom" constant="13" id="P7h-Ep-NPN"/>
                 <constraint firstItem="T7Y-Q2-h52" firstAttribute="leading" secondItem="iN0-l3-epB" secondAttribute="leading" constant="28" id="TXw-X5-Y1u"/>
                 <constraint firstAttribute="trailing" secondItem="C3X-28-3eB" secondAttribute="trailing" constant="16" id="X8w-Bf-zC7"/>
@@ -127,6 +128,7 @@
                 <constraint firstItem="xej-UK-bQu" firstAttribute="trailing" secondItem="C3X-28-3eB" secondAttribute="trailing" id="rtR-RK-fdA"/>
                 <constraint firstItem="ZfN-9l-0US" firstAttribute="leading" secondItem="DoC-1c-3dy" secondAttribute="leading" id="sRD-xS-D9d"/>
                 <constraint firstItem="ZfN-9l-0US" firstAttribute="top" secondItem="h4X-Xm-3Ji" secondAttribute="bottom" constant="5" id="skw-3j-H4d"/>
+                <constraint firstAttribute="trailing" relation="greaterThanOrEqual" secondItem="h4X-Xm-3Ji" secondAttribute="trailing" constant="10" id="xWW-Wk-GXc"/>
                 <constraint firstAttribute="trailing" secondItem="T7Y-Q2-h52" secondAttribute="trailing" constant="28" id="zVF-uQ-UIv"/>
                 <constraint firstItem="h4X-Xm-3Ji" firstAttribute="leading" secondItem="DoC-1c-3dy" secondAttribute="leading" id="zsY-fs-Glh"/>
             </constraints>