Browse Source

好友搜索及添加

桂欢 2 years ago
parent
commit
3ebbd60fa7

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

@@ -195,6 +195,8 @@
 		3DB97DA929D6AC0A00B12754 /* LEETheme.m in Sources */ = {isa = PBXBuildFile; fileRef = 3DB97DA829D6AC0A00B12754 /* LEETheme.m */; };
 		3DE9967929E915BF00C50A83 /* SLMomentsVc.m in Sources */ = {isa = PBXBuildFile; fileRef = 3DE9967729E915BF00C50A83 /* SLMomentsVc.m */; };
 		3DE9967A29E915BF00C50A83 /* SLMomentsVc.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3DE9967829E915BF00C50A83 /* SLMomentsVc.xib */; };
+		3DE9968329EE72D300C50A83 /* SLAddFriendVc.m in Sources */ = {isa = PBXBuildFile; fileRef = 3DE9968129EE72D300C50A83 /* SLAddFriendVc.m */; };
+		3DE9968429EE72D300C50A83 /* SLAddFriendVc.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3DE9968229EE72D300C50A83 /* SLAddFriendVc.xib */; };
 		3DF3DAA129B98A7D00CAD3AB /* SLMyView.m in Sources */ = {isa = PBXBuildFile; fileRef = 3DF3DA9F29B98A7D00CAD3AB /* SLMyView.m */; };
 		3DF3DAA429B9A68800CAD3AB /* SLBaseCellView.m in Sources */ = {isa = PBXBuildFile; fileRef = 3DF3DAA329B9A68800CAD3AB /* SLBaseCellView.m */; };
 		3DF3DAA829B9A6AA00CAD3AB /* SLBaseCellView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3DF3DAA729B9A6AA00CAD3AB /* SLBaseCellView.xib */; };
@@ -598,6 +600,9 @@
 		3DE9967629E915BF00C50A83 /* SLMomentsVc.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SLMomentsVc.h; sourceTree = "<group>"; };
 		3DE9967729E915BF00C50A83 /* SLMomentsVc.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SLMomentsVc.m; sourceTree = "<group>"; };
 		3DE9967829E915BF00C50A83 /* SLMomentsVc.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = SLMomentsVc.xib; sourceTree = "<group>"; };
+		3DE9968029EE72D300C50A83 /* SLAddFriendVc.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SLAddFriendVc.h; sourceTree = "<group>"; };
+		3DE9968129EE72D300C50A83 /* SLAddFriendVc.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SLAddFriendVc.m; sourceTree = "<group>"; };
+		3DE9968229EE72D300C50A83 /* SLAddFriendVc.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = SLAddFriendVc.xib; sourceTree = "<group>"; };
 		3DF3DA9F29B98A7D00CAD3AB /* SLMyView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SLMyView.m; sourceTree = "<group>"; };
 		3DF3DAA029B98A7D00CAD3AB /* SLMyView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SLMyView.h; sourceTree = "<group>"; };
 		3DF3DAA229B9A68800CAD3AB /* SLBaseCellView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SLBaseCellView.h; sourceTree = "<group>"; };
@@ -1423,6 +1428,9 @@
 				3D19CBFD29E7DF6B0041A6B8 /* SLMomentsCommentVc.xib */,
 				3D19CC0029E7E9340041A6B8 /* SLMomentDetailTableVc.h */,
 				3D19CC0129E7E9340041A6B8 /* SLMomentDetailTableVc.m */,
+				3DE9968029EE72D300C50A83 /* SLAddFriendVc.h */,
+				3DE9968129EE72D300C50A83 /* SLAddFriendVc.m */,
+				3DE9968229EE72D300C50A83 /* SLAddFriendVc.xib */,
 			);
 			path = MomentsVc;
 			sourceTree = "<group>";
@@ -1822,6 +1830,7 @@
 				3D25105729AC8FE1000AE530 /* SLRegistViewController.xib in Resources */,
 				3D8C9F8A29AC57F300678283 /* LaunchScreen.storyboard in Resources */,
 				3D1B9CED29C038280008D01A /* SLTargetViewController.xib in Resources */,
+				3DE9968429EE72D300C50A83 /* SLAddFriendVc.xib in Resources */,
 				3D1B987B29BEE6800008D01A /* SLLxTopView.xib in Resources */,
 				3DA5AF6229B8875A009E4925 /* SLHomeViewController.xib in Resources */,
 				3D24D40829DEAF3200014D1C /* SLCreatMomentsVc.xib in Resources */,
@@ -1991,6 +2000,7 @@
 				3DB97D4429D6A86E00B12754 /* SDTimeLineRefreshHeader.m in Sources */,
 				3D8515D929CD92A400418BAB /* JXCategoryTitleBackgroundView.m in Sources */,
 				3D2D8C0729DE7404009392DA /* LeftImageDesignTxtxField.m in Sources */,
+				3DE9968329EE72D300C50A83 /* SLAddFriendVc.m in Sources */,
 				3D1B9D0229C16DD00008D01A /* SLTargetModel.m in Sources */,
 				3D2510C029AF1A8F000AE530 /* MBProgressHUD+Addition.m in Sources */,
 				3D9961F929CD2EFE0076DBD1 /* SLNestSubjectViewController.m in Sources */,

+ 22 - 0
SLAiELTS/SLAiELTS/Assets.xcassets/Moents/icon_search.imageset/Contents.json

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

BIN
SLAiELTS/SLAiELTS/Assets.xcassets/Moents/icon_search.imageset/icon_search@2x.png


BIN
SLAiELTS/SLAiELTS/Assets.xcassets/Moents/icon_search.imageset/icon_search@3x.png


+ 6 - 0
SLAiELTS/SLAiELTS/Tool/NetWorking/SLHttpCenter.m

@@ -159,6 +159,12 @@ static SLHttpCenter *handle;
     if (status != SPErrorCode_Success) {
         if (failure) {
             NSString *errorMsg = [resultDic objectForKey:kRequest_Message];
+            if (!errorMsg.length) {
+                id data = [resultDic objectForKey:kRequest_Data];
+                if (data && [data isKindOfClass:NSString.class]) {
+                    errorMsg = data;
+                }
+            }
             [ZFToast ShowWithMessage: errorMsg ?: @"网络请求失败"];
             SPRequestError *requestError = [SPRequestError errorWithReason:errorMsg errorCode:status];
             failure(resultDic);

+ 3 - 1
SLAiELTS/SLAiELTS/Tool/ZFToast/ZFToast.m

@@ -49,7 +49,9 @@ NSInteger const kRemoveTime = 3.0;
 //    [self.textLabel removeFromSuperview];
     /// @brief 创建定时器
 //    [self createTimer];
-  
+    if (![message isKindOfClass:NSString.class]) {
+        return;
+    }
     dispatch_async(dispatch_get_main_queue(), ^{
         /// @brief 初始化Label
         [self initLabel:message];

+ 1 - 0
SLAiELTS/SLAiELTS/ViewControllers/AddressBookVC/SLAddressBookVc.m

@@ -11,6 +11,7 @@
 #import "UITableView+SCIndexView.h"
 #import "SLFriendsModel.h"
 #import "SLFriensInfoVc.h"
+#import "SLAddFriendVc.h"
 
 @interface SLAddressBookVc ()<UITableViewDelegate, UITableViewDataSource>
 @property (weak, nonatomic) IBOutlet SLCustNavView *navView;

+ 3 - 0
SLAiELTS/SLAiELTS/ViewControllers/AddressBookVC/Views/AddressBookCell.h

@@ -21,4 +21,7 @@ typedef void(^SLfrendsSelBlock)(void);
 @property(nonatomic,strong)SLFriendsModel *frendModel;
 
 @property (nonatomic, copy)SLfrendsSelBlock selBlock;
+
+- (void)confignCellWith:(SLUserModel *)userModel;
+
 @end

+ 8 - 0
SLAiELTS/SLAiELTS/ViewControllers/AddressBookVC/Views/AddressBookCell.m

@@ -37,6 +37,14 @@
     }];
 }
 
+- (void)confignCellWith:(SLUserModel *)userModel {
+    self.nameLabel.text = userModel.name;
+    NSString *userImg = [userModel getUserHeadUrl];
+    [self.photoIV sd_setImageWithURL:[NSURL URLWithString:userImg] placeholderImage:[UIImage imageNamed:@"icon_ellipse"] completed:^(UIImage *image, NSError *error, SDImageCacheType cacheType, NSURL *imageURL) {
+        
+    }];
+}
+
 - (void)setSelected:(BOOL)selected animated:(BOOL)animated {
     [super setSelected:selected animated:animated];
 

+ 7 - 0
SLAiELTS/SLAiELTS/ViewControllers/Home/Views/SLCustNavView.m

@@ -8,6 +8,7 @@
 
 #import "SLCustNavView.h"
 #import "SLMikeSegment.h"
+#import "SLAddFriendVc.h"
 
 static const NSInteger ymNavBtnTag = 666665;
 
@@ -69,8 +70,14 @@ static const NSInteger ymNavQuitBtnTag = 333333;
                 CGFloat height = arr.count * 50;
                 SLMikeSegment *mikeSegment = [[SLMikeSegment alloc] initWithFrame:CGRectMake(kSCREEN_WIDTH - 132, kNavBarHeight + 6, 120, height) titleArray:arr isHor:YES];
                 mikeSegment.backgroundColor = [UIColor clearColor];
+                WS(weakSelf);
                 mikeSegment.mikeSegmentBlock = ^(SLMikeSegmentModel *model) {
                     [bView removeFromSuperview];
+                    if ([model.segTitle isEqualToString:@"添加朋友"]) {
+                        SLAddFriendVc *vc = [SLAddFriendVc loadViewControllewWithNib];
+                        [weakSelf.viewController navPushViewController:vc animated:YES];;
+                    }
+                    
                 };
                 [bView addSubview:mikeSegment];
                 UIImageView *imgView = [[UIImageView alloc] initWithImage:ImageName(@"icon_arrow_wrapper")];

+ 16 - 0
SLAiELTS/SLAiELTS/ViewControllers/Moments/MomentsVc/SLAddFriendVc.h

@@ -0,0 +1,16 @@
+//
+//  SLAddFriendVc.h
+//  SLAiELTS
+//
+//  Created by Gusont on 2023/4/18.
+//
+
+#import "SLBaseViewController.h"
+
+NS_ASSUME_NONNULL_BEGIN
+
+@interface SLAddFriendVc : SLBaseViewController
+
+@end
+
+NS_ASSUME_NONNULL_END

+ 102 - 0
SLAiELTS/SLAiELTS/ViewControllers/Moments/MomentsVc/SLAddFriendVc.m

@@ -0,0 +1,102 @@
+//
+//  SLAddFriendVc.m
+//  SLAiELTS
+//
+//  Created by Gusont on 2023/4/18.
+//
+
+#import "SLAddFriendVc.h"
+#import "LeftImageDesignTxtxField.h"
+#import "AddressBookCell.h"
+
+@interface SLAddFriendVc ()<UITextFieldDelegate, UITableViewDelegate, UITableViewDataSource>
+
+@property (weak, nonatomic) IBOutlet UITableView *tableView;
+
+@property (weak, nonatomic) IBOutlet LeftImageDesignTxtxField *textField;
+
+@property (weak, nonatomic) IBOutlet NSLayoutConstraint *topViewConst;
+
+@property (nonatomic, strong) NSMutableArray<SLUserModel *> *userModels;
+@end
+
+@implementation SLAddFriendVc
+
+- (void)viewDidLoad {
+    [super viewDidLoad];
+    // Do any additional setup after loading the view from its nib.
+    [self.tableView registerNibCellWithReuseIdentifierClass:AddressBookCell.class];
+    self.topViewConst.constant = kNavBarHeight;
+    self.navigationBar.separatorHeight = 0.0f;
+    self.title = @"添加朋友";
+}
+
+- (BOOL)textFieldShouldReturn:(UITextField *)textField {
+    [self.userModels removeAllObjects];
+    if (textField.text.length) {
+        [self requetsSearchUser:textField.text];
+    }else {
+        [self.tableView reloadData];
+    }
+    [textField endEditing:YES];
+    return YES;
+}
+
+- (void)requetsSearchUser:(NSString *)user {
+    [[SLHttpCenter SharedInstance] getWithUrl:@"/api/Contacts/SearchUser" parameter:@{@"userName" : user} success:^(id responseObject) {
+        NSArray *arr = [responseObject objectForKey:@"data"];
+        NSArray<SLUserModel *> *userModels = [SLUserModel mj_objectArrayWithKeyValuesArray:arr];
+        [self.userModels addObjectsFromArray:userModels];
+        [self.tableView reloadData];
+    } failure:^(SPRequestError *error) {
+        
+    }];
+}
+
+- (NSMutableArray<SLUserModel *> *)userModels {
+    if (!_userModels) {
+        _userModels = [NSMutableArray new];
+    }
+    return _userModels;
+}
+
+- (nonnull UITableViewCell *)tableView:(nonnull UITableView *)tableView cellForRowAtIndexPath:(nonnull NSIndexPath *)indexPath {
+    AddressBookCell *cell = (AddressBookCell *)[tableView dequeueReusableCellWithIdentifier:@"AddressBookCell"];
+    SLUserModel *userModel = [self.userModels objectAtIndex:indexPath.row];
+    [cell confignCellWith:userModel];
+    return cell;
+}
+
+- (NSInteger)tableView:(nonnull UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
+    return self.userModels.count;
+}
+
+- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
+    SLUserModel *userModel = [self.userModels objectAtIndex:indexPath.row];
+    NSString *msg = [NSString stringWithFormat:@"是否添加用户:%@ 为好友", userModel.name];
+    WS(weakSelf);
+    [SLCustomizeAlert showAletrWithTitle:@"提示" message:msg sureBtnTitle:@"确定" cancelBtnTitle:@"取消" sureBtnAction:^{
+        [[SLHttpCenter SharedInstance] getWithUrl:@"/api/Contacts/AddContacts" parameter:@{@"userId" : userModel.userId} success:^(id responseObject) {
+            [ZFToast ShowWithMessage:@"添加成功"];
+            dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(1.5 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
+                [weakSelf.navigationController popViewControllerAnimated:YES];
+            });
+        } failure:^(SPRequestError *error) {
+
+        }];
+    } cancelBtnAction:nil];
+}
+
+- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath {
+    return 72.0f;
+}
+
+-(CGFloat)tableView:(UITableView *)tableView heightForFooterInSection:(NSInteger)section{
+    return 0.001f;
+}
+
+-(CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section{
+    return 12.01;
+}
+
+@end

+ 87 - 0
SLAiELTS/SLAiELTS/ViewControllers/Moments/MomentsVc/SLAddFriendVc.xib

@@ -0,0 +1,87 @@
+<?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">
+    <device id="retina6_0" orientation="portrait" appearance="light"/>
+    <dependencies>
+        <deployment identifier="iOS"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21207"/>
+        <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"/>
+    </dependencies>
+    <objects>
+        <placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="SLAddFriendVc">
+            <connections>
+                <outlet property="tableView" destination="eXb-ne-DWH" id="iWj-8W-cVD"/>
+                <outlet property="textField" destination="uMf-ef-8EA" id="sgc-0J-RMX"/>
+                <outlet property="topViewConst" destination="2gX-nY-zCo" id="1Ur-WQ-mju"/>
+                <outlet property="view" destination="i5M-Pr-FkT" id="sfx-zR-JGt"/>
+            </connections>
+        </placeholder>
+        <placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
+        <view clearsContextBeforeDrawing="NO" contentMode="scaleToFill" id="i5M-Pr-FkT">
+            <rect key="frame" x="0.0" y="0.0" width="390" height="844"/>
+            <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
+            <subviews>
+                <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="B7C-ax-1tK">
+                    <rect key="frame" x="0.0" y="100" width="390" height="56"/>
+                    <subviews>
+                        <textField opaque="NO" contentMode="scaleToFill" horizontalHuggingPriority="248" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="姓名/字母(模糊匹配)" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="uMf-ef-8EA" customClass="LeftImageDesignTxtxField">
+                            <rect key="frame" x="16" y="8" width="358" height="40"/>
+                            <color key="backgroundColor" red="0.95294117647058818" green="0.95294117647058818" blue="0.95294117647058818" alpha="1" colorSpace="calibratedRGB"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="14"/>
+                            <textInputTraits key="textInputTraits" returnKeyType="search"/>
+                            <userDefinedRuntimeAttributes>
+                                <userDefinedRuntimeAttribute type="number" keyPath="layer.cornerRadius">
+                                    <integer key="value" value="20"/>
+                                </userDefinedRuntimeAttribute>
+                                <userDefinedRuntimeAttribute type="image" keyPath="leftImage" value="icon_search"/>
+                            </userDefinedRuntimeAttributes>
+                            <connections>
+                                <outlet property="delegate" destination="-1" id="FXO-8R-yoc"/>
+                            </connections>
+                        </textField>
+                    </subviews>
+                    <color key="backgroundColor" systemColor="systemBackgroundColor"/>
+                    <constraints>
+                        <constraint firstItem="uMf-ef-8EA" firstAttribute="leading" secondItem="B7C-ax-1tK" secondAttribute="leading" constant="16" id="Isp-5I-69M"/>
+                        <constraint firstAttribute="height" constant="56" id="RyP-fa-YDh"/>
+                        <constraint firstItem="uMf-ef-8EA" firstAttribute="centerX" secondItem="B7C-ax-1tK" secondAttribute="centerX" id="Y9D-Zz-Do7"/>
+                        <constraint firstItem="uMf-ef-8EA" firstAttribute="centerY" secondItem="B7C-ax-1tK" secondAttribute="centerY" id="uYv-ce-Gz7"/>
+                        <constraint firstItem="uMf-ef-8EA" firstAttribute="top" secondItem="B7C-ax-1tK" secondAttribute="top" constant="8" id="wU7-VF-Jba"/>
+                    </constraints>
+                </view>
+                <tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" style="grouped" separatorStyle="default" rowHeight="-1" estimatedRowHeight="-1" sectionHeaderHeight="18" estimatedSectionHeaderHeight="-1" sectionFooterHeight="18" estimatedSectionFooterHeight="-1" translatesAutoresizingMaskIntoConstraints="NO" id="eXb-ne-DWH">
+                    <rect key="frame" x="0.0" y="156" width="390" height="654"/>
+                    <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                    <connections>
+                        <outlet property="dataSource" destination="-1" id="3oa-HV-EKu"/>
+                        <outlet property="delegate" destination="-1" id="Qez-ri-bnz"/>
+                    </connections>
+                </tableView>
+            </subviews>
+            <viewLayoutGuide key="safeArea" id="Q5M-cg-NOt"/>
+            <color key="backgroundColor" systemColor="systemBackgroundColor"/>
+            <constraints>
+                <constraint firstItem="Q5M-cg-NOt" firstAttribute="bottom" secondItem="eXb-ne-DWH" secondAttribute="bottom" id="0rA-Jk-SzV"/>
+                <constraint firstItem="B7C-ax-1tK" firstAttribute="top" secondItem="i5M-Pr-FkT" secondAttribute="top" constant="100" id="2gX-nY-zCo"/>
+                <constraint firstItem="B7C-ax-1tK" firstAttribute="leading" secondItem="Q5M-cg-NOt" secondAttribute="leading" id="41O-j2-JWi"/>
+                <constraint firstItem="eXb-ne-DWH" firstAttribute="trailing" secondItem="Q5M-cg-NOt" secondAttribute="trailing" id="SYO-th-APa"/>
+                <constraint firstItem="eXb-ne-DWH" firstAttribute="top" secondItem="B7C-ax-1tK" secondAttribute="bottom" id="fCh-KE-PZb"/>
+                <constraint firstItem="eXb-ne-DWH" firstAttribute="leading" secondItem="Q5M-cg-NOt" secondAttribute="leading" id="mtj-e4-BkV"/>
+                <constraint firstItem="Q5M-cg-NOt" firstAttribute="trailing" secondItem="B7C-ax-1tK" secondAttribute="trailing" id="wt7-Ac-kup"/>
+            </constraints>
+            <point key="canvasLocation" x="138" y="-1"/>
+        </view>
+    </objects>
+    <designables>
+        <designable name="uMf-ef-8EA">
+            <size key="intrinsicContentSize" width="191" height="18.666666666666668"/>
+        </designable>
+    </designables>
+    <resources>
+        <image name="icon_search" width="24" height="24"/>
+        <systemColor name="systemBackgroundColor">
+            <color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+        </systemColor>
+    </resources>
+</document>

+ 2 - 0
SLAiELTS/SLAiELTS/ViewControllers/Moments/MomentsVc/SLMomentsCommentVc.m

@@ -11,6 +11,7 @@
 @interface SLMomentsCommentVc ()
 @property (weak, nonatomic) IBOutlet PlaceholderTextView *textView;
 @property (weak, nonatomic) IBOutlet UILabel *numbelLabel;
+@property (weak, nonatomic) IBOutlet NSLayoutConstraint *textViewTopConst;
 
 @end
 
@@ -19,6 +20,7 @@
 - (void)viewDidLoad {
     [super viewDidLoad];
     // Do any additional setup after loading the view from its nib.
+    self.textViewTopConst.constant = kNavBarHeight;
     self.title = @"评论";
     self.view.backgroundColor = [UIColor whiteColor];
     UIImage *backImage =[UIImage imageNamed:@"icon_nav_back"];

+ 1 - 0
SLAiELTS/SLAiELTS/ViewControllers/Moments/MomentsVc/SLMomentsCommentVc.xib

@@ -13,6 +13,7 @@
             <connections>
                 <outlet property="numbelLabel" destination="6o2-3n-j5s" id="p1N-43-7we"/>
                 <outlet property="textView" destination="TF7-ij-FCC" id="DHJ-dK-c9A"/>
+                <outlet property="textViewTopConst" destination="e35-Jz-FIx" id="8IY-ms-N9a"/>
                 <outlet property="view" destination="AOD-EN-2Gp" id="UCy-nY-guX"/>
             </connections>
         </placeholder>

+ 7 - 0
SLAiELTS/SLAiELTS/ViewControllers/Moments/Views/CommentView/SDTimeLineCellCommentView.m

@@ -296,6 +296,13 @@
 - (void)didClickLink:(MLLink *)link linkText:(NSString *)linkText linkLabel:(MLLinkLabel *)linkLabel
 {
     NSLog(@"%@--%@", link.linkValue,linkText);
+    if (link.linkValue.length) {
+//        [[SLHttpCenter SharedInstance] getWithUrl:@"/api/admin/User/GetUserDetail" parameter:@{@"id":link.linkValue} success:^(id responseObject) {
+//            
+//        } failure:^(SPRequestError *error) {
+//            
+//        }];
+    }
 }
 
 @end