xiongzhu 7 жил өмнө
parent
commit
97f34ec9bf
37 өөрчлөгдсөн 1093 нэмэгдсэн , 35 устгасан
  1. BIN
      .DS_Store
  2. 30 0
      model.xcodeproj/project.pbxproj
  3. 6 0
      model/Assets.xcassets/排名/Contents.json
  4. 23 0
      model/Assets.xcassets/排名/icon_paimingfen.imageset/Contents.json
  5. BIN
      model/Assets.xcassets/排名/icon_paimingfen.imageset/icon_paimingfen.png
  6. BIN
      model/Assets.xcassets/排名/icon_paimingfen.imageset/icon_paimingfen@2x.png
  7. BIN
      model/Assets.xcassets/排名/icon_paimingfen.imageset/icon_paimingfen@3x.png
  8. 23 0
      model/Assets.xcassets/排名/mask_no1.imageset/Contents.json
  9. BIN
      model/Assets.xcassets/排名/mask_no1.imageset/ph_yinpai_no1.png
  10. BIN
      model/Assets.xcassets/排名/mask_no1.imageset/ph_yinpai_no1@2x.png
  11. BIN
      model/Assets.xcassets/排名/mask_no1.imageset/ph_yinpai_no1@3x.png
  12. 23 0
      model/Assets.xcassets/排名/mask_no2.imageset/Contents.json
  13. BIN
      model/Assets.xcassets/排名/mask_no2.imageset/Group 3.png
  14. BIN
      model/Assets.xcassets/排名/mask_no2.imageset/Group 3@2x.png
  15. BIN
      model/Assets.xcassets/排名/mask_no2.imageset/Group 3@3x.png
  16. 23 0
      model/Assets.xcassets/排名/mask_no3.imageset/Contents.json
  17. BIN
      model/Assets.xcassets/排名/mask_no3.imageset/ph_yinpai_no3.png
  18. BIN
      model/Assets.xcassets/排名/mask_no3.imageset/ph_yinpai_no3@2x.png
  19. BIN
      model/Assets.xcassets/排名/mask_no3.imageset/ph_yinpai_no3@3x.png
  20. 62 12
      model/Classes/Controllers/Controller/MineVC/MineNewViewController.m
  21. 76 12
      model/Classes/Controllers/Controller/MineVC/MineNewViewController.xib
  22. 0 1
      model/Classes/Controllers/Controller/MyTeamVC/MyMemberController.m
  23. 2 0
      model/Classes/Controllers/Controller/MyTeamVC/TabControl.h
  24. 8 0
      model/Classes/Controllers/Controller/MyTeamVC/TabControl.m
  25. 17 0
      model/Classes/Controllers/Controller/RankVC/RankCell.h
  26. 40 0
      model/Classes/Controllers/Controller/RankVC/RankCell.m
  27. 91 0
      model/Classes/Controllers/Controller/RankVC/RankCell.xib
  28. 17 0
      model/Classes/Controllers/Controller/RankVC/RankChildController.h
  29. 127 0
      model/Classes/Controllers/Controller/RankVC/RankChildController.m
  30. 117 0
      model/Classes/Controllers/Controller/RankVC/RankChildController.xib
  31. 51 3
      model/Classes/Controllers/Controller/RankVC/RankController.m
  32. 30 1
      model/Classes/Controllers/Controller/RankVC/RankController.xib
  33. 17 0
      model/Classes/Controllers/Controller/RankVC/RankHeader.h
  34. 74 0
      model/Classes/Controllers/Controller/RankVC/RankHeader.m
  35. 224 0
      model/Classes/Controllers/Controller/RankVC/RankHeader.xib
  36. 1 0
      model/Classes/Controllers/Model/ModelUser.h
  37. 11 6
      model/ModelHeader.h

BIN
.DS_Store


+ 30 - 0
model.xcodeproj/project.pbxproj

@@ -369,6 +369,12 @@
 		3A5EC75B2186FBED00A9438E /* MyTeamHeader.m in Sources */ = {isa = PBXBuildFile; fileRef = 3A5EC75A2186FBED00A9438E /* MyTeamHeader.m */; };
 		3A5EC760218707E800A9438E /* PromoteController.m in Sources */ = {isa = PBXBuildFile; fileRef = 3A5EC75E218707E800A9438E /* PromoteController.m */; };
 		3A5EC761218707E800A9438E /* PromoteController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3A5EC75F218707E800A9438E /* PromoteController.xib */; };
+		3AC5C9FE218BD9A600D4ACAC /* RankChildController.m in Sources */ = {isa = PBXBuildFile; fileRef = 3AC5C9FC218BD9A600D4ACAC /* RankChildController.m */; };
+		3AC5C9FF218BD9A600D4ACAC /* RankChildController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3AC5C9FD218BD9A600D4ACAC /* RankChildController.xib */; };
+		3AC5CA03218BDDC700D4ACAC /* RankCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 3AC5CA01218BDDC700D4ACAC /* RankCell.m */; };
+		3AC5CA04218BDDC700D4ACAC /* RankCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3AC5CA02218BDDC700D4ACAC /* RankCell.xib */; };
+		3AC5CA07218BEB3E00D4ACAC /* RankHeader.m in Sources */ = {isa = PBXBuildFile; fileRef = 3AC5CA06218BEB3E00D4ACAC /* RankHeader.m */; };
+		3AC5CA09218BEB4B00D4ACAC /* RankHeader.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3AC5CA08218BEB4B00D4ACAC /* RankHeader.xib */; };
 		3AE8C7AA218B2E550069D147 /* ModelCardController.m in Sources */ = {isa = PBXBuildFile; fileRef = 3AE8C7A9218B2E550069D147 /* ModelCardController.m */; };
 		3AE8C7AD218B49890069D147 /* IntroView.m in Sources */ = {isa = PBXBuildFile; fileRef = 3AE8C7AC218B49890069D147 /* IntroView.m */; };
 		3AE8C7AF218B49EC0069D147 /* IntroView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3AE8C7AE218B49EC0069D147 /* IntroView.xib */; };
@@ -1144,6 +1150,15 @@
 		3A5EC75D218707E800A9438E /* PromoteController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PromoteController.h; sourceTree = "<group>"; };
 		3A5EC75E218707E800A9438E /* PromoteController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PromoteController.m; sourceTree = "<group>"; };
 		3A5EC75F218707E800A9438E /* PromoteController.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = PromoteController.xib; sourceTree = "<group>"; };
+		3AC5C9FB218BD9A600D4ACAC /* RankChildController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RankChildController.h; sourceTree = "<group>"; };
+		3AC5C9FC218BD9A600D4ACAC /* RankChildController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RankChildController.m; sourceTree = "<group>"; };
+		3AC5C9FD218BD9A600D4ACAC /* RankChildController.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = RankChildController.xib; sourceTree = "<group>"; };
+		3AC5CA00218BDDC700D4ACAC /* RankCell.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RankCell.h; sourceTree = "<group>"; };
+		3AC5CA01218BDDC700D4ACAC /* RankCell.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RankCell.m; sourceTree = "<group>"; };
+		3AC5CA02218BDDC700D4ACAC /* RankCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = RankCell.xib; sourceTree = "<group>"; };
+		3AC5CA05218BEB3E00D4ACAC /* RankHeader.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RankHeader.h; sourceTree = "<group>"; };
+		3AC5CA06218BEB3E00D4ACAC /* RankHeader.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RankHeader.m; sourceTree = "<group>"; };
+		3AC5CA08218BEB4B00D4ACAC /* RankHeader.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = RankHeader.xib; sourceTree = "<group>"; };
 		3AE8C7A8218B2E550069D147 /* ModelCardController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ModelCardController.h; sourceTree = "<group>"; };
 		3AE8C7A9218B2E550069D147 /* ModelCardController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ModelCardController.m; sourceTree = "<group>"; };
 		3AE8C7AB218B49890069D147 /* IntroView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = IntroView.h; sourceTree = "<group>"; };
@@ -2471,6 +2486,15 @@
 				3AE8C7B1218B65860069D147 /* RankController.h */,
 				3AE8C7B2218B65860069D147 /* RankController.m */,
 				3AE8C7B3218B65860069D147 /* RankController.xib */,
+				3AC5C9FB218BD9A600D4ACAC /* RankChildController.h */,
+				3AC5C9FC218BD9A600D4ACAC /* RankChildController.m */,
+				3AC5C9FD218BD9A600D4ACAC /* RankChildController.xib */,
+				3AC5CA00218BDDC700D4ACAC /* RankCell.h */,
+				3AC5CA01218BDDC700D4ACAC /* RankCell.m */,
+				3AC5CA02218BDDC700D4ACAC /* RankCell.xib */,
+				3AC5CA05218BEB3E00D4ACAC /* RankHeader.h */,
+				3AC5CA06218BEB3E00D4ACAC /* RankHeader.m */,
+				3AC5CA08218BEB4B00D4ACAC /* RankHeader.xib */,
 			);
 			path = RankVC;
 			sourceTree = "<group>";
@@ -2971,6 +2995,7 @@
 				8848C66B210813D300EDB121 /* PhotoCollectionViewCell.xib in Resources */,
 				2F4A8973211D9F04006D7DD3 /* SignInfoCell.xib in Resources */,
 				2F4A8949211ADB00006D7DD3 /* OneImageCell.xib in Resources */,
+				3AC5CA04218BDDC700D4ACAC /* RankCell.xib in Resources */,
 				2F8D26C321183D7300CD7347 /* README.md in Resources */,
 				2F8D27E921183E2B00CD7347 /* NTESVideoChatViewController.xib in Resources */,
 				2FA1AF8421280AE9005F12CA /* message.wav in Resources */,
@@ -2988,6 +3013,7 @@
 				2F4A8947211ADB00006D7DD3 /* PingLunCell.xib in Resources */,
 				3A5EC761218707E800A9438E /* PromoteController.xib in Resources */,
 				2F4A894E211ADB00006D7DD3 /* FourImageCell.xib in Resources */,
+				3AC5CA09218BEB4B00D4ACAC /* RankHeader.xib in Resources */,
 				2FA1AF5C2127F92A005F12CA /* ForgetViewController.xib in Resources */,
 				2F4A8972211D9F04006D7DD3 /* SignUpViewController.xib in Resources */,
 				3AF44FDB21856E1600ABEAEB /* MineNewViewController.xib in Resources */,
@@ -3005,6 +3031,7 @@
 				2F7FC05621242E4700492F0C /* NTESGalleryViewController.xib in Resources */,
 				2F8D26C421183D7300CD7347 /* NIMKitResource.bundle in Resources */,
 				3A44C12D218A0E7A0021DA3F /* MyMemberController.xib in Resources */,
+				3AC5C9FF218BD9A600D4ACAC /* RankChildController.xib in Resources */,
 				3AF44FF421858F3500ABEAEB /* ShareViewController.xib in Resources */,
 				2F168360210B098800941193 /* RegisterViewController.xib in Resources */,
 				2F4A8948211ADB00006D7DD3 /* DetailFourImageCell.xib in Resources */,
@@ -3095,6 +3122,7 @@
 				EF812F7120FF0E51004A6A35 /* ModelUser.m in Sources */,
 				2F8D27C121183DEF00CD7347 /* TZPhotoPreviewController.m in Sources */,
 				2F8D278621183D9000CD7347 /* renderer_yuv420sp.c in Sources */,
+				3AC5CA07218BEB3E00D4ACAC /* RankHeader.m in Sources */,
 				3AF44FE721856F0700ABEAEB /* MineItemView.m in Sources */,
 				2F8D27C921183DEF00CD7347 /* TZGifPhotoPreviewController.m in Sources */,
 				EF7B0C1A20FC69EF0078781D /* WithdrawalController.m in Sources */,
@@ -3287,6 +3315,7 @@
 				2F8D27C021183DEF00CD7347 /* UIView+Layout.m in Sources */,
 				2F8D24F521144AF400CD7347 /* MASLayoutConstraint.m in Sources */,
 				2F8D272A21183D7400CD7347 /* NIMSessionUnknowContentView.m in Sources */,
+				3AC5CA03218BDDC700D4ACAC /* RankCell.m in Sources */,
 				2F8D271921183D7400CD7347 /* NIMSessionLayoutImpl.m in Sources */,
 				8845F42E2109A334008E4EF6 /* PhotoModel.m in Sources */,
 				2F8D24F321144AF400CD7347 /* MASCompositeConstraint.m in Sources */,
@@ -3427,6 +3456,7 @@
 				2F8D270121183D7400CD7347 /* NIMTimestampModel.m in Sources */,
 				EF4A657A20FDC94D00FFCD3C /* MineController.m in Sources */,
 				2F8D26D421183D7300CD7347 /* NIMKitRobotTemplateLayout.m in Sources */,
+				3AC5C9FE218BD9A600D4ACAC /* RankChildController.m in Sources */,
 				2F8D273221183D7400CD7347 /* NSString+NIMKit.m in Sources */,
 				2F7FC09921242E6300492F0C /* UIImage+NTESColor.m in Sources */,
 				2F4A8956211ADB56006D7DD3 /* PingLunModel.m in Sources */,

+ 6 - 0
model/Assets.xcassets/排名/Contents.json

@@ -0,0 +1,6 @@
+{
+  "info" : {
+    "version" : 1,
+    "author" : "xcode"
+  }
+}

+ 23 - 0
model/Assets.xcassets/排名/icon_paimingfen.imageset/Contents.json

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

BIN
model/Assets.xcassets/排名/icon_paimingfen.imageset/icon_paimingfen.png


BIN
model/Assets.xcassets/排名/icon_paimingfen.imageset/icon_paimingfen@2x.png


BIN
model/Assets.xcassets/排名/icon_paimingfen.imageset/icon_paimingfen@3x.png


+ 23 - 0
model/Assets.xcassets/排名/mask_no1.imageset/Contents.json

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

BIN
model/Assets.xcassets/排名/mask_no1.imageset/ph_yinpai_no1.png


BIN
model/Assets.xcassets/排名/mask_no1.imageset/ph_yinpai_no1@2x.png


BIN
model/Assets.xcassets/排名/mask_no1.imageset/ph_yinpai_no1@3x.png


+ 23 - 0
model/Assets.xcassets/排名/mask_no2.imageset/Contents.json

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

BIN
model/Assets.xcassets/排名/mask_no2.imageset/Group 3.png


BIN
model/Assets.xcassets/排名/mask_no2.imageset/Group 3@2x.png


BIN
model/Assets.xcassets/排名/mask_no2.imageset/Group 3@3x.png


+ 23 - 0
model/Assets.xcassets/排名/mask_no3.imageset/Contents.json

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

BIN
model/Assets.xcassets/排名/mask_no3.imageset/ph_yinpai_no3.png


BIN
model/Assets.xcassets/排名/mask_no3.imageset/ph_yinpai_no3@2x.png


BIN
model/Assets.xcassets/排名/mask_no3.imageset/ph_yinpai_no3@3x.png


+ 62 - 12
model/Classes/Controllers/Controller/MineVC/MineNewViewController.m

@@ -21,7 +21,9 @@
 #import "ModelCardController.h"
 #import "RankController.h"
 
-@interface MineNewViewController ()
+@interface MineNewViewController (){
+    BOOL online;
+}
 @property(weak, nonatomic) IBOutlet UIView *headView;
 @property(weak, nonatomic) IBOutlet UIView *bgView;
 @property(weak, nonatomic) IBOutlet UILabel *nameLabel;
@@ -35,6 +37,9 @@
 @property (weak, nonatomic) IBOutlet UIView *modelCardView;
 @property (weak, nonatomic) IBOutlet UIView *skillView;
 
+@property (weak, nonatomic) IBOutlet UIView *switchView;
+@property (weak, nonatomic) IBOutlet UIView *switchIndicatorView;
+@property (weak, nonatomic) IBOutlet UIView *transformView;
 @end
 
 @implementation MineNewViewController
@@ -54,7 +59,7 @@
     self.avatarView.layer.masksToBounds = YES; 
     self.avatarView.userInteractionEnabled = YES;
     
-    self.onlineSwitch.onImage = [UIImage imageNamed:@"into_icon_shezhi_baise"];
+    online = YES;
 }
 
 - (void)viewWillAppear:(BOOL)animated {
@@ -129,8 +134,8 @@
 }
 
 - (void)getDataFromNetworking {
-    [MBProgressHUD showHUDAddedTo:self.view animated:YES];
-    NSDictionary *dic = [[NSDictionary alloc] initWithObjectsAndKeys:[ModelUser user].modelpk,@"modelpk", nil];
+//    [MBProgressHUD showHUDAddedTo:self.view animated:YES];
+    NSDictionary *dic = [[NSDictionary alloc] initWithObjectsAndKeys:[ModelUser user].modelpk, @"modelpk", nil];
     [YanCNetWorkManager requestPostWithURLStr:Url_refreshLogin(PublicUrl) parameters:dic finish:^(id dataDic) {
         [MBProgressHUD hideHUDForView:self.view animated:YES];
         
@@ -147,7 +152,9 @@
             
             self.nameLabel.text = [NSString stringWithFormat:@"%@", dataDic[@"data"][@"pet"]];
             [self.avatarView sd_setImageWithURL:[NSURL URLWithString:[NSString stringWithFormat:@"%@/%@", PublicUrl, dataDic[@"data"][@"hphoto"]]] placeholderImage:[UIImage imageNamed:@"morentouxiang"]];
-            
+            online = user.is_a;
+            [self setSwitchState:user.is_a];
+           
 //            if ([dataDic[@"data"][@"hasred"] isEqualToString:@"1"]) {
 //                self.notificationView.hidden = NO;
 //            }else{
@@ -245,15 +252,58 @@
     [self.navigationController pushViewController:settingsVC animated:YES];
 }
 
-- (IBAction)onlineChange:(id)sender {
-    UISwitch *switchButton = (UISwitch*)sender;
-    BOOL isButtonOn = [switchButton isOn];
-    if (isButtonOn) {
-        [MBProgressHUD showInfo:@"您已开启在线模式"];
-    }else {
-        [MBProgressHUD showInfo:@"您已开启离线模式,别人将无法呼叫您"];
+- (IBAction)tapSwitch:(id)sender {
+    [self updateOnline:!online];
+}
+
+- (void)updateOnline:(BOOL)state {
+    __weak MineNewViewController* this = self;
+    NSDictionary *dic = [[NSDictionary alloc] initWithObjectsAndKeys:[ModelUser modelUser].modelpk, @"modelpk", @(state), @"state", nil];
+    [YanCNetWorkManager requestPostWithURLStr:Url_setOnline(PublicUrl)
+                                   parameters:dic
+                                       finish:^(id res) {
+                                           BOOL success = [@"success" isEqualToString:res[@"msg"]];
+                                           if (success) {
+                                               online = state;
+                                               [this setSwitchState:state];
+                                               if (online) {
+                                                   [MBProgressHUD showInfo:@"您已开启在线模式"];
+                                               } else {
+                                                   [MBProgressHUD showInfo:@"您已开启离线模式,别人将无法呼叫您"];
+                                               }
+                                           } else {
+                                               [MBProgressHUD showInfo:@"请求失败!"];
+                                           }
+                                       }
+                                      enError:^(NSError *error) {
+                                          [MBProgressHUD hideHUDForView:self.view animated:YES];
+                                      }];
+}
+
+- (void)setSwitchState:(BOOL)state {
+    if (state) {
+        [UIView animateWithDuration:0.25
+                              delay:0
+                            options:UIViewAnimationOptionCurveEaseOut
+                         animations:^{
+                             self.switchView.backgroundColor = [UIColor whiteColor];
+                             self.switchIndicatorView.backgroundColor = [UIColor colorWithRed:255/255.0 green:64/255.0 blue:149/255.0 alpha:1];
+                             self.transformView.transform = CGAffineTransformMakeTranslation(0, 0);
+                         }
+                         completion:nil];
+    } else {
+        [UIView animateWithDuration:0.25
+                              delay:0
+                            options:UIViewAnimationOptionCurveEaseOut
+                         animations:^{
+                             self.switchView.backgroundColor = [UIColor colorWithRed:0/255.0 green:0/255.0 blue:0/255.0 alpha:0.3];
+                             self.switchIndicatorView.backgroundColor = [UIColor whiteColor];
+                             self.transformView.transform = CGAffineTransformMakeTranslation(-32, 0);
+                         }
+                         completion:nil];
     }
 }
+
 - (IBAction)tapRank:(id)sender {
     RankController* rankVC = [[RankController alloc] init];
     rankVC.hidesBottomBarWhenPushed = YES;

+ 76 - 12
model/Classes/Controllers/Controller/MineVC/MineNewViewController.xib

@@ -22,8 +22,10 @@
                 <outlet property="incomeView" destination="kaC-Mh-u3w" id="kyJ-iN-iF8"/>
                 <outlet property="modelCardView" destination="etX-QK-1nU" id="EVQ-7h-fu5"/>
                 <outlet property="nameLabel" destination="tnV-pA-N5a" id="4Yj-BS-G5M"/>
-                <outlet property="onlineSwitch" destination="TDa-kz-FG6" id="2qw-gq-AB5"/>
                 <outlet property="skillView" destination="Ac7-NR-8Xp" id="Ven-w6-xmx"/>
+                <outlet property="switchIndicatorView" destination="ETZ-yN-c0i" id="4v1-LO-MNx"/>
+                <outlet property="switchView" destination="wPM-QM-mXD" id="2Et-Fe-rBA"/>
+                <outlet property="transformView" destination="NYN-K0-kgh" id="koD-Ph-jwH"/>
                 <outlet property="view" destination="iN0-l3-epB" id="6qb-1w-qlZ"/>
             </connections>
         </placeholder>
@@ -212,7 +214,7 @@
                 <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="wTS-eH-R6J">
                     <rect key="frame" x="20" y="366" width="335" height="214"/>
                     <subviews>
-                        <view tag="6" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="NBl-XH-Hzs">
+                        <view tag="4" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="NBl-XH-Hzs">
                             <rect key="frame" x="0.0" y="0.0" width="111.66666666666667" height="107"/>
                             <subviews>
                                 <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="into_icon_yaoqing" translatesAutoresizingMaskIntoConstraints="NO" id="sya-g9-yRn">
@@ -433,14 +435,6 @@
                         </userDefinedRuntimeAttribute>
                     </userDefinedRuntimeAttributes>
                 </view>
-                <switch opaque="NO" contentMode="scaleToFill" horizontalHuggingPriority="750" verticalHuggingPriority="750" contentHorizontalAlignment="center" contentVerticalAlignment="center" on="YES" translatesAutoresizingMaskIntoConstraints="NO" id="TDa-kz-FG6">
-                    <rect key="frame" x="20" y="44.666666666666664" width="51" height="30.999999999999993"/>
-                    <color key="onTintColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
-                    <color key="thumbTintColor" red="1" green="0.25098039220000001" blue="0.58431372550000005" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
-                    <connections>
-                        <action selector="onlineChange:" destination="-1" eventType="valueChanged" id="11z-46-e9R"/>
-                    </connections>
-                </switch>
                 <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="3ng-uh-Rqk">
                     <rect key="frame" x="305" y="711" width="56" height="56"/>
                     <constraints>
@@ -452,14 +446,81 @@
                         <action selector="tapRank:" destination="-1" eventType="touchUpInside" id="iAj-Iy-Qqe"/>
                     </connections>
                 </button>
+                <view clipsSubviews="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="wPM-QM-mXD">
+                    <rect key="frame" x="20" y="46" width="60" height="28"/>
+                    <subviews>
+                        <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="NYN-K0-kgh">
+                            <rect key="frame" x="0.0" y="3" width="92" height="22"/>
+                            <subviews>
+                                <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="在线" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="xfg-UF-AYG">
+                                    <rect key="frame" x="3" y="0.0" width="32" height="22"/>
+                                    <fontDescription key="fontDescription" type="system" pointSize="10"/>
+                                    <color key="textColor" red="1" green="0.25098039220000001" blue="0.58431372550000005" alpha="1" colorSpace="calibratedRGB"/>
+                                    <nil key="highlightedColor"/>
+                                </label>
+                                <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="ETZ-yN-c0i">
+                                    <rect key="frame" x="35" y="0.0" width="22" height="22"/>
+                                    <color key="backgroundColor" red="1" green="0.25098039220000001" blue="0.58431372550000005" alpha="1" colorSpace="calibratedRGB"/>
+                                    <constraints>
+                                        <constraint firstAttribute="width" constant="22" id="JCW-gs-FZT"/>
+                                        <constraint firstAttribute="height" constant="22" id="xaH-kv-olQ"/>
+                                    </constraints>
+                                    <userDefinedRuntimeAttributes>
+                                        <userDefinedRuntimeAttribute type="number" keyPath="layer.cornerRadius">
+                                            <integer key="value" value="11"/>
+                                        </userDefinedRuntimeAttribute>
+                                    </userDefinedRuntimeAttributes>
+                                </view>
+                                <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="离线" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="86U-V6-0j6">
+                                    <rect key="frame" x="57" y="0.0" width="32" height="22"/>
+                                    <fontDescription key="fontDescription" type="system" pointSize="11"/>
+                                    <color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                    <nil key="highlightedColor"/>
+                                </label>
+                            </subviews>
+                            <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            <constraints>
+                                <constraint firstAttribute="bottom" secondItem="86U-V6-0j6" secondAttribute="bottom" id="2qB-8d-vlg"/>
+                                <constraint firstAttribute="trailing" secondItem="86U-V6-0j6" secondAttribute="trailing" constant="3" id="DVY-LX-AHb"/>
+                                <constraint firstItem="xfg-UF-AYG" firstAttribute="leading" secondItem="NYN-K0-kgh" secondAttribute="leading" constant="3" id="ECV-Sg-7E5"/>
+                                <constraint firstAttribute="bottom" secondItem="xfg-UF-AYG" secondAttribute="bottom" id="FCQ-rK-tOY"/>
+                                <constraint firstItem="ETZ-yN-c0i" firstAttribute="trailing" secondItem="86U-V6-0j6" secondAttribute="leading" id="LLu-kP-nYr"/>
+                                <constraint firstItem="ETZ-yN-c0i" firstAttribute="leading" secondItem="xfg-UF-AYG" secondAttribute="trailing" id="SHC-ub-2X6"/>
+                                <constraint firstItem="86U-V6-0j6" firstAttribute="width" secondItem="xfg-UF-AYG" secondAttribute="width" id="Zyp-TX-OOf"/>
+                                <constraint firstAttribute="width" constant="92" id="elN-8i-hdd"/>
+                                <constraint firstAttribute="height" constant="22" id="fuP-0f-YL2"/>
+                                <constraint firstItem="86U-V6-0j6" firstAttribute="top" secondItem="NYN-K0-kgh" secondAttribute="top" id="l1w-gr-Ott"/>
+                                <constraint firstItem="xfg-UF-AYG" firstAttribute="top" secondItem="NYN-K0-kgh" secondAttribute="top" id="nKZ-9W-TR1"/>
+                                <constraint firstItem="ETZ-yN-c0i" firstAttribute="centerY" secondItem="NYN-K0-kgh" secondAttribute="centerY" id="r2c-GS-So1"/>
+                            </constraints>
+                        </view>
+                    </subviews>
+                    <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                    <constraints>
+                        <constraint firstItem="NYN-K0-kgh" firstAttribute="centerY" secondItem="wPM-QM-mXD" secondAttribute="centerY" id="6vi-4s-Shy"/>
+                        <constraint firstAttribute="width" constant="60" id="S2h-qc-WzJ"/>
+                        <constraint firstItem="NYN-K0-kgh" firstAttribute="leading" secondItem="wPM-QM-mXD" secondAttribute="leading" id="ePT-q8-zTu"/>
+                        <constraint firstAttribute="height" constant="28" id="qXL-fq-DzY"/>
+                    </constraints>
+                    <userDefinedRuntimeAttributes>
+                        <userDefinedRuntimeAttribute type="number" keyPath="layer.cornerRadius">
+                            <integer key="value" value="14"/>
+                        </userDefinedRuntimeAttribute>
+                    </userDefinedRuntimeAttributes>
+                    <connections>
+                        <outletCollection property="gestureRecognizers" destination="Fn6-h7-Dk4" appends="YES" id="cCW-rL-ZU8"/>
+                    </connections>
+                </view>
             </subviews>
             <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
             <constraints>
                 <constraint firstItem="60z-Gq-b3E" firstAttribute="trailing" secondItem="IBe-5v-ajR" secondAttribute="trailing" constant="20" id="2Ub-cG-Dlo"/>
                 <constraint firstItem="r9j-ZU-SlD" firstAttribute="top" secondItem="JMR-FE-a0P" secondAttribute="bottom" constant="-30" id="4E2-i3-WaW"/>
+                <constraint firstItem="wPM-QM-mXD" firstAttribute="centerY" secondItem="TVo-sg-JF7" secondAttribute="centerY" id="8JB-aY-axc"/>
                 <constraint firstItem="kaC-Mh-u3w" firstAttribute="centerX" secondItem="tnV-pA-N5a" secondAttribute="centerX" id="97e-WL-o8e"/>
                 <constraint firstItem="60z-Gq-b3E" firstAttribute="bottom" secondItem="r9j-ZU-SlD" secondAttribute="bottom" id="Czt-28-MCp"/>
                 <constraint firstItem="l52-m1-42R" firstAttribute="centerY" secondItem="SCh-5U-jcN" secondAttribute="centerY" id="Fp7-RO-Wpm"/>
+                <constraint firstItem="wPM-QM-mXD" firstAttribute="leading" secondItem="60z-Gq-b3E" secondAttribute="leading" constant="20" id="GbG-dM-HV1"/>
                 <constraint firstItem="SCh-5U-jcN" firstAttribute="centerX" secondItem="60z-Gq-b3E" secondAttribute="centerX" id="IaQ-4Q-m6C"/>
                 <constraint firstItem="60z-Gq-b3E" firstAttribute="trailing" secondItem="TVo-sg-JF7" secondAttribute="trailing" constant="10" id="LTz-qN-mYk"/>
                 <constraint firstItem="l52-m1-42R" firstAttribute="centerX" secondItem="SCh-5U-jcN" secondAttribute="centerX" id="N3l-It-k1P"/>
@@ -475,10 +536,8 @@
                 <constraint firstItem="60z-Gq-b3E" firstAttribute="bottom" secondItem="3ng-uh-Rqk" secondAttribute="bottom" constant="11" id="V0n-hY-CKz"/>
                 <constraint firstItem="60z-Gq-b3E" firstAttribute="trailing" secondItem="3ng-uh-Rqk" secondAttribute="trailing" constant="14" id="X57-ym-6ea"/>
                 <constraint firstAttribute="top" secondItem="JMR-FE-a0P" secondAttribute="top" id="YjH-SZ-13n"/>
-                <constraint firstItem="TDa-kz-FG6" firstAttribute="leading" secondItem="60z-Gq-b3E" secondAttribute="leading" constant="20" id="auZ-6d-A0b"/>
                 <constraint firstItem="IBe-5v-ajR" firstAttribute="top" secondItem="kaC-Mh-u3w" secondAttribute="bottom" constant="20" id="b6C-88-L6p"/>
                 <constraint firstItem="SCh-5U-jcN" firstAttribute="top" secondItem="r9j-ZU-SlD" secondAttribute="top" constant="-43" id="cF4-gj-bF6"/>
-                <constraint firstItem="TDa-kz-FG6" firstAttribute="centerY" secondItem="TVo-sg-JF7" secondAttribute="centerY" id="dQI-Wn-0Kw"/>
                 <constraint firstItem="wTS-eH-R6J" firstAttribute="leading" secondItem="60z-Gq-b3E" secondAttribute="leading" constant="20" id="dYP-NI-agD"/>
                 <constraint firstItem="JMR-FE-a0P" firstAttribute="leading" secondItem="60z-Gq-b3E" secondAttribute="leading" id="gJf-xQ-FmV"/>
                 <constraint firstItem="60z-Gq-b3E" firstAttribute="trailing" secondItem="JMR-FE-a0P" secondAttribute="trailing" id="mSO-Nx-Kfp"/>
@@ -543,6 +602,11 @@
                 <action selector="handelTap:" destination="-1" id="ofp-TT-ghk"/>
             </connections>
         </tapGestureRecognizer>
+        <tapGestureRecognizer id="Fn6-h7-Dk4">
+            <connections>
+                <action selector="tapSwitch:" destination="-1" id="6y1-yx-fDx"/>
+            </connections>
+        </tapGestureRecognizer>
     </objects>
     <resources>
         <image name="default_avatar" width="36" height="36"/>

+ 0 - 1
model/Classes/Controllers/Controller/MyTeamVC/MyMemberController.m

@@ -27,7 +27,6 @@ static NSString *cellId = @"MyTeamCell";
     self.tableView.dataSource = self;
     self.tableView.separatorStyle = UITableViewCellSeparatorStyleNone;
     self.tableView.tableHeaderView = self.tableHeader;
-    
     [self getData];
 }
 

+ 2 - 0
model/Classes/Controllers/Controller/MyTeamVC/TabControl.h

@@ -26,6 +26,8 @@ typedef NS_ENUM(NSInteger, TabControlState) {
 @property (nonatomic, strong) IBInspectable UIColor* indicatorColor;
 @property (nonatomic, strong) IBInspectable UIColor* normalColor;
 @property (nonatomic, strong) IBInspectable UIColor* activeColor;
+@property (nonatomic, strong) IBInspectable NSString* tab1;
+@property (nonatomic, strong) IBInspectable NSString* tab2;
 - (void)setColor:(UIColor*) color forState:(TabControlState) state;
 @end
 

+ 8 - 0
model/Classes/Controllers/Controller/MyTeamVC/TabControl.m

@@ -121,4 +121,12 @@
         self.label1.textColor = self.activeColor;
     }
 }
+
+- (void)setTab1:(NSString *)tab1 {
+    self.label0.text = tab1;
+}
+
+- (void)setTab2:(NSString *)tab2 {
+    self.label1.text = tab2;
+}
 @end

+ 17 - 0
model/Classes/Controllers/Controller/RankVC/RankCell.h

@@ -0,0 +1,17 @@
+//
+//  RankCell.h
+//  model
+//
+//  Created by Drew on 2018/11/2.
+//  Copyright © 2018 Mine. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+NS_ASSUME_NONNULL_BEGIN
+
+@interface RankCell : UITableViewCell
+@property(nonatomic, strong) NSDictionary* data;
+@end
+
+NS_ASSUME_NONNULL_END

+ 40 - 0
model/Classes/Controllers/Controller/RankVC/RankCell.m

@@ -0,0 +1,40 @@
+//
+//  RankCell.m
+//  model
+//
+//  Created by Drew on 2018/11/2.
+//  Copyright © 2018 Mine. All rights reserved.
+//
+
+#import "RankCell.h"
+
+@interface RankCell()
+@property (weak, nonatomic) IBOutlet UILabel *labelRank;
+@property (weak, nonatomic) IBOutlet UIImageView *avatar;
+@property (weak, nonatomic) IBOutlet UILabel *labelName;
+@property (weak, nonatomic) IBOutlet UILabel *labelCoin;
+@end
+
+@implementation RankCell
+
+- (void)awakeFromNib {
+    [super awakeFromNib];
+    // Initialization code
+    self.avatar.layer.masksToBounds = YES;
+    self.avatar.layer.cornerRadius = 22;
+}
+
+- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
+    [super setSelected:selected animated:animated];
+
+    // Configure the view for the selected state
+}
+
+- (void)setData:(NSDictionary *)data {
+    [self.avatar sd_setImageWithURL:[NSURL URLWithString:[NSString stringWithFormat:@"%@%@", imageURl, data[@"avatar"]]]];
+    self.labelRank.text = [data[@"rank"] stringValue];
+    self.labelName.text = data[@"name"];
+    self.labelCoin.text = [data[@"coin"] stringValue];
+}
+
+@end

+ 91 - 0
model/Classes/Controllers/Controller/RankVC/RankCell.xib

@@ -0,0 +1,91 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="14313.18" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+    <device id="retina4_7" orientation="portrait">
+        <adaptation id="fullscreen"/>
+    </device>
+    <dependencies>
+        <deployment identifier="iOS"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14283.14"/>
+        <capability name="Safe area layout guides" minToolsVersion="9.0"/>
+        <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 contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" rowHeight="64" id="KGk-i7-Jjw" customClass="RankCell">
+            <rect key="frame" x="0.0" y="0.0" width="339" height="64"/>
+            <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="339" height="63.5"/>
+                <autoresizingMask key="autoresizingMask"/>
+                <subviews>
+                    <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="1PP-Ol-2YZ">
+                        <rect key="frame" x="15" y="0.0" width="309" height="1"/>
+                        <color key="backgroundColor" red="0.94901960784313721" green="0.95686274509803915" blue="0.96078431372549022" alpha="1" colorSpace="calibratedRGB"/>
+                        <constraints>
+                            <constraint firstAttribute="height" constant="1" id="Q3J-8T-9Fi"/>
+                        </constraints>
+                    </view>
+                    <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="1" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="FVl-Vw-j6N">
+                        <rect key="frame" x="15" y="23.5" width="6.5" height="17"/>
+                        <fontDescription key="fontDescription" type="system" pointSize="14"/>
+                        <nil key="highlightedColor"/>
+                    </label>
+                    <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="morentouxiang" translatesAutoresizingMaskIntoConstraints="NO" id="qXx-VB-JIQ">
+                        <rect key="frame" x="44" y="10" width="44" height="44"/>
+                        <constraints>
+                            <constraint firstAttribute="width" constant="44" id="6OF-x4-Or4"/>
+                            <constraint firstAttribute="height" constant="44" id="gtn-Ts-Z0l"/>
+                        </constraints>
+                    </imageView>
+                    <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="夏秋雨" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="8i9-Ia-utw">
+                        <rect key="frame" x="102" y="23" width="46" height="18"/>
+                        <fontDescription key="fontDescription" type="system" weight="medium" pointSize="15"/>
+                        <nil key="highlightedColor"/>
+                    </label>
+                    <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="icon_paimingfen" translatesAutoresizingMaskIntoConstraints="NO" id="qW5-pf-OEG">
+                        <rect key="frame" x="268" y="22" width="20" height="20"/>
+                        <constraints>
+                            <constraint firstAttribute="height" constant="20" id="5yj-dS-wFK"/>
+                            <constraint firstAttribute="width" constant="20" id="o1J-RU-CYq"/>
+                        </constraints>
+                    </imageView>
+                    <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="123" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="0zM-XU-sxf">
+                        <rect key="frame" x="290" y="23.5" width="24.5" height="17"/>
+                        <fontDescription key="fontDescription" type="system" weight="semibold" pointSize="14"/>
+                        <color key="textColor" red="1" green="0.25098039215686274" blue="0.58431372549019611" alpha="1" colorSpace="calibratedRGB"/>
+                        <nil key="highlightedColor"/>
+                    </label>
+                </subviews>
+                <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                <constraints>
+                    <constraint firstItem="qW5-pf-OEG" firstAttribute="centerY" secondItem="H2p-sc-9uM" secondAttribute="centerY" id="6vg-vG-Jyz"/>
+                    <constraint firstItem="FVl-Vw-j6N" firstAttribute="centerY" secondItem="H2p-sc-9uM" secondAttribute="centerY" id="Kjr-n1-Oxt"/>
+                    <constraint firstAttribute="trailing" secondItem="qW5-pf-OEG" secondAttribute="trailing" constant="51" id="Kpd-zK-Yv9"/>
+                    <constraint firstItem="1PP-Ol-2YZ" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="N6t-X6-FOL"/>
+                    <constraint firstItem="8i9-Ia-utw" firstAttribute="leading" secondItem="qXx-VB-JIQ" secondAttribute="trailing" constant="14" id="Zgd-LP-k5Z"/>
+                    <constraint firstItem="0zM-XU-sxf" firstAttribute="centerY" secondItem="H2p-sc-9uM" secondAttribute="centerY" id="bxh-v5-59a"/>
+                    <constraint firstItem="qXx-VB-JIQ" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="44" id="cRn-ug-4v8"/>
+                    <constraint firstItem="1PP-Ol-2YZ" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" id="dRT-Wl-zo2"/>
+                    <constraint firstItem="FVl-Vw-j6N" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="dzF-YZ-ROj"/>
+                    <constraint firstItem="qXx-VB-JIQ" firstAttribute="centerY" secondItem="H2p-sc-9uM" secondAttribute="centerY" id="iCW-Ae-lRb"/>
+                    <constraint firstItem="0zM-XU-sxf" firstAttribute="leading" secondItem="qW5-pf-OEG" secondAttribute="trailing" constant="2" id="j36-En-pOw"/>
+                    <constraint firstItem="8i9-Ia-utw" firstAttribute="centerY" secondItem="H2p-sc-9uM" secondAttribute="centerY" id="seP-7l-KBV"/>
+                    <constraint firstAttribute="trailing" secondItem="1PP-Ol-2YZ" secondAttribute="trailing" constant="15" id="ts0-Yg-gU1"/>
+                </constraints>
+            </tableViewCellContentView>
+            <viewLayoutGuide key="safeArea" id="aW0-zy-SZf"/>
+            <connections>
+                <outlet property="avatar" destination="qXx-VB-JIQ" id="SOe-Yd-Dw6"/>
+                <outlet property="labelCoin" destination="0zM-XU-sxf" id="UcS-PH-Bj4"/>
+                <outlet property="labelName" destination="8i9-Ia-utw" id="sSv-7E-Tp6"/>
+                <outlet property="labelRank" destination="FVl-Vw-j6N" id="m33-v2-Bhk"/>
+            </connections>
+            <point key="canvasLocation" x="148" y="161.91904047976013"/>
+        </tableViewCell>
+    </objects>
+    <resources>
+        <image name="icon_paimingfen" width="20" height="20"/>
+        <image name="morentouxiang" width="45" height="45"/>
+    </resources>
+</document>

+ 17 - 0
model/Classes/Controllers/Controller/RankVC/RankChildController.h

@@ -0,0 +1,17 @@
+//
+//  RankChildController.h
+//  model
+//
+//  Created by Drew on 2018/11/2.
+//  Copyright © 2018 Mine. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+NS_ASSUME_NONNULL_BEGIN
+
+@interface RankChildController : UIViewController
+@property (nonatomic, strong) NSString* type;
+@end
+
+NS_ASSUME_NONNULL_END

+ 127 - 0
model/Classes/Controllers/Controller/RankVC/RankChildController.m

@@ -0,0 +1,127 @@
+//
+//  RankChildController.m
+//  model
+//
+//  Created by Drew on 2018/11/2.
+//  Copyright © 2018 Mine. All rights reserved.
+//
+
+#import "RankChildController.h"
+#import "RankCell.h"
+#import "RankHeader.h"
+
+static NSString *cellId = @"RankCell";
+
+@interface RankChildController () <UITableViewDelegate, UITableViewDataSource>
+@property (weak, nonatomic) IBOutlet UITableView *tableView;
+@property (weak, nonatomic) IBOutlet UILabel *myRank;
+@property (weak, nonatomic) IBOutlet UILabel *myName;
+@property (weak, nonatomic) IBOutlet UIImageView *myAvatar;
+@property (weak, nonatomic) IBOutlet UILabel *myMoney;
+@property (weak, nonatomic) IBOutlet UIView *myView;
+
+@property (nonatomic, strong) NSMutableArray* tableData;
+@property (nonatomic, strong) RankHeader* headerView;
+@end
+
+@implementation RankChildController
+
+- (void)viewDidLoad {
+    [super viewDidLoad];
+    self.myView.layer.cornerRadius = 8;
+    self.myView.layer.shadowColor = [UIColor colorWithRed:0/255.0 green:0/255.0 blue:0/255.0 alpha:0.1].CGColor;
+    self.myView.layer.shadowOffset = CGSizeMake(0,-4);
+    self.myView.layer.shadowOpacity = 1;
+    self.myView.layer.shadowRadius = 4;
+    self.tableView.dataSource = self;
+    self.tableView.delegate = self;
+    self.tableView.separatorStyle = UITableViewCellSeparatorStyleNone;
+    self.tableView.contentInset = UIEdgeInsetsMake(15, 0, 48, 0);
+    self.tableView.tableHeaderView = self.headerView;
+    [self getData];
+}
+
+- (NSMutableArray*)tableData {
+    if (!_tableData) {
+        _tableData = [NSMutableArray arrayWithCapacity:0];
+    }
+    return _tableData;
+}
+
+- (RankHeader*)headerView {
+    if (!_headerView) {
+        _headerView = [[RankHeader alloc] init];
+        _headerView.frame = CGRectMake(0, 0, [UIScreen mainScreen].bounds.size.width - 30, 240);
+    }
+    return _headerView;
+}
+
+- (void)getData {
+    NSString* day;
+    if ([@"week" isEqualToString:self.type]) {
+        day = @"7";
+    } else {
+        day = @"30";
+    }
+    NSDictionary *dic = [[NSDictionary alloc] initWithObjectsAndKeys:[ModelUser modelUser].pk, @"memberpk", day, @"day", nil];
+    [YanCNetWorkManager requestPostWithURLStr:Url_rank(PublicUrl)
+                                   parameters:dic
+                                       finish:^(id res) {
+                                           BOOL success = [res[@"success"] intValue];
+                                           if (success) {
+                                               [self.tableData addObjectsFromArray:res[@"data"][@"list"]];
+                                               [self.tableView reloadData];
+                                               self.headerView.data = res[@"data"][@"list"];
+                                               if (res[@"data"][@"myRank"]) {
+                                                   self.myView.hidden = NO;
+                                                   self.myName.text = res[@"data"][@"myRank"][@"name"];
+                                                   [self.myAvatar sd_setImageWithURL:[NSURL URLWithString:[NSString stringWithFormat:@"%@%@", imageURl, res[@"data"][@"myRank"][@"avatar"]]]
+                                                                    placeholderImage:[UIImage imageNamed:@"morentouxinag"]];
+                                                   self.myMoney.text = [[NSDecimalNumber numberWithDouble:[res[@"data"][@"myRank"][@"coin"] doubleValue]] stringValue];
+                                                   if (res[@"data"][@"myRank"][@"rank"] > 0) {
+                                                       self.myRank.text = [NSString stringWithFormat:@"第%@名", res[@"data"][@"myRank"][@"rank"]];
+                                                   } else {
+                                                       self.myRank.text = @"未上榜";
+                                                   }
+                                               } else {
+                                                   self.myView.hidden = YES;
+                                               }
+                                           } else {
+                                               [MBProgressHUD showInfo:@"请求失败!"];
+                                           }
+                                       }
+                                      enError:^(NSError *error) {
+                                          [MBProgressHUD hideHUDForView:self.view animated:YES];
+                                      }];
+}
+
+#pragma mark - UITableView Delegate
+- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView {
+    return 1;
+}
+
+- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
+    if (self.tableData.count > 3) {
+        return self.tableData.count - 3;
+    }
+    return 0;
+}
+
+- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath {
+    return 64;
+}
+
+- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
+    RankCell *cell = [self.tableView dequeueReusableCellWithIdentifier:cellId];
+    if (!cell) {
+        NSArray *nib = [[NSBundle mainBundle] loadNibNamed:cellId owner:self options:nil];
+        cell = [nib objectAtIndex:0];
+        cell.selectionStyle = UITableViewCellSelectionStyleNone;
+        cell.data = [self.tableData objectAtIndex:indexPath.row + 3];
+    }
+    return cell;
+}
+#pragma mark -
+
+
+@end

+ 117 - 0
model/Classes/Controllers/Controller/RankVC/RankChildController.xib

@@ -0,0 +1,117 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="14313.18" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+    <device id="retina4_7" orientation="portrait">
+        <adaptation id="fullscreen"/>
+    </device>
+    <dependencies>
+        <deployment identifier="iOS"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14283.14"/>
+        <capability name="Safe area layout guides" minToolsVersion="9.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="RankChildController">
+            <connections>
+                <outlet property="myAvatar" destination="ssw-La-OHf" id="c3k-Cj-5oV"/>
+                <outlet property="myMoney" destination="aKl-qc-E7e" id="cNH-My-MsH"/>
+                <outlet property="myName" destination="opd-TN-cYo" id="mgO-xw-wsZ"/>
+                <outlet property="myRank" destination="uik-hU-GcV" id="7UT-3M-ta6"/>
+                <outlet property="myView" destination="taZ-se-tGv" id="eWS-zh-2iJ"/>
+                <outlet property="tableView" destination="978-fQ-MSf" id="emC-yj-C9a"/>
+                <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="375" height="667"/>
+            <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
+            <subviews>
+                <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="L1h-XD-lku">
+                    <rect key="frame" x="15" y="220" width="345" height="447"/>
+                    <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                </view>
+                <tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" showsHorizontalScrollIndicator="NO" showsVerticalScrollIndicator="NO" style="plain" separatorStyle="default" rowHeight="-1" estimatedRowHeight="-1" sectionHeaderHeight="28" sectionFooterHeight="28" translatesAutoresizingMaskIntoConstraints="NO" id="978-fQ-MSf">
+                    <rect key="frame" x="15" y="20" width="345" height="647"/>
+                    <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                </tableView>
+                <view hidden="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="taZ-se-tGv">
+                    <rect key="frame" x="15" y="619" width="345" height="48"/>
+                    <subviews>
+                        <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="morentouxiang" translatesAutoresizingMaskIntoConstraints="NO" id="ssw-La-OHf">
+                            <rect key="frame" x="49" y="6" width="36" height="36"/>
+                            <constraints>
+                                <constraint firstAttribute="width" constant="36" id="1Op-ec-kx1"/>
+                                <constraint firstAttribute="height" constant="36" id="sxc-Nw-DOH"/>
+                            </constraints>
+                            <userDefinedRuntimeAttributes>
+                                <userDefinedRuntimeAttribute type="boolean" keyPath="layer.masksToBounds" value="YES"/>
+                                <userDefinedRuntimeAttribute type="number" keyPath="layer.cornerRadius">
+                                    <integer key="value" value="18"/>
+                                </userDefinedRuntimeAttribute>
+                            </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="uik-hU-GcV">
+                            <rect key="frame" x="5" y="17.5" width="34" height="13.5"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="11"/>
+                            <nil key="textColor"/>
+                            <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="opd-TN-cYo">
+                            <rect key="frame" x="105" y="24" width="0.0" height="0.0"/>
+                            <fontDescription key="fontDescription" type="system" weight="medium" pointSize="14"/>
+                            <nil key="textColor"/>
+                            <nil key="highlightedColor"/>
+                        </label>
+                        <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="icon_paimingfen" translatesAutoresizingMaskIntoConstraints="NO" id="noq-PK-3HY">
+                            <rect key="frame" x="274" y="14" width="20" height="20"/>
+                            <constraints>
+                                <constraint firstAttribute="height" constant="20" id="Xvw-1V-BiH"/>
+                                <constraint firstAttribute="width" constant="20" id="Ze8-Hm-ebI"/>
+                            </constraints>
+                        </imageView>
+                        <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="0" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="aKl-qc-E7e">
+                            <rect key="frame" x="296" y="15.5" width="9.5" height="17"/>
+                            <fontDescription key="fontDescription" type="system" weight="semibold" pointSize="14"/>
+                            <color key="textColor" red="1" green="0.25098039220000001" blue="0.58431372550000005" alpha="1" colorSpace="calibratedRGB"/>
+                            <nil key="highlightedColor"/>
+                        </label>
+                    </subviews>
+                    <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                    <constraints>
+                        <constraint firstItem="uik-hU-GcV" firstAttribute="centerX" secondItem="taZ-se-tGv" secondAttribute="leading" constant="22" id="6ZX-GB-oJH"/>
+                        <constraint firstItem="aKl-qc-E7e" firstAttribute="centerY" secondItem="taZ-se-tGv" secondAttribute="centerY" id="AhO-m8-ePe"/>
+                        <constraint firstItem="aKl-qc-E7e" firstAttribute="leading" secondItem="noq-PK-3HY" secondAttribute="trailing" constant="2" id="JcZ-mW-A4j"/>
+                        <constraint firstItem="ssw-La-OHf" firstAttribute="leading" secondItem="taZ-se-tGv" secondAttribute="leading" constant="49" id="LgN-N7-1yN"/>
+                        <constraint firstItem="opd-TN-cYo" firstAttribute="leading" secondItem="ssw-La-OHf" secondAttribute="trailing" constant="20" id="Ohz-dr-y2N"/>
+                        <constraint firstItem="noq-PK-3HY" firstAttribute="centerY" secondItem="taZ-se-tGv" secondAttribute="centerY" id="T3O-Gk-ewh"/>
+                        <constraint firstItem="opd-TN-cYo" firstAttribute="centerY" secondItem="taZ-se-tGv" secondAttribute="centerY" id="Ta9-Av-Jbb"/>
+                        <constraint firstAttribute="trailing" secondItem="noq-PK-3HY" secondAttribute="trailing" constant="51" id="UzT-eX-h35"/>
+                        <constraint firstAttribute="height" constant="48" id="ZuY-dm-KQA"/>
+                        <constraint firstItem="ssw-La-OHf" firstAttribute="centerY" secondItem="taZ-se-tGv" secondAttribute="centerY" id="cy6-9R-k8z"/>
+                        <constraint firstItem="uik-hU-GcV" firstAttribute="centerY" secondItem="taZ-se-tGv" secondAttribute="centerY" id="uwT-vA-BEj"/>
+                    </constraints>
+                </view>
+            </subviews>
+            <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+            <constraints>
+                <constraint firstItem="978-fQ-MSf" firstAttribute="top" secondItem="Q5M-cg-NOt" secondAttribute="top" id="267-t8-OxX"/>
+                <constraint firstItem="taZ-se-tGv" firstAttribute="bottom" secondItem="Q5M-cg-NOt" secondAttribute="bottom" id="55b-in-oJ9"/>
+                <constraint firstItem="Q5M-cg-NOt" firstAttribute="bottom" secondItem="L1h-XD-lku" secondAttribute="bottom" id="7hV-LJ-ipN"/>
+                <constraint firstItem="L1h-XD-lku" firstAttribute="leading" secondItem="Q5M-cg-NOt" secondAttribute="leading" constant="15" id="Dvw-xx-xnp"/>
+                <constraint firstItem="Q5M-cg-NOt" firstAttribute="trailing" secondItem="978-fQ-MSf" secondAttribute="trailing" constant="15" id="Il0-Yn-C5I"/>
+                <constraint firstItem="Q5M-cg-NOt" firstAttribute="trailing" secondItem="L1h-XD-lku" secondAttribute="trailing" constant="15" id="PNu-8M-2Z6"/>
+                <constraint firstItem="978-fQ-MSf" firstAttribute="leading" secondItem="Q5M-cg-NOt" secondAttribute="leading" constant="15" id="QeW-CZ-QTj"/>
+                <constraint firstItem="L1h-XD-lku" firstAttribute="top" secondItem="Q5M-cg-NOt" secondAttribute="top" constant="200" id="WfC-pr-zq1"/>
+                <constraint firstItem="Q5M-cg-NOt" firstAttribute="trailing" secondItem="taZ-se-tGv" secondAttribute="trailing" constant="15" id="Y9R-g2-K0y"/>
+                <constraint firstItem="taZ-se-tGv" firstAttribute="leading" secondItem="Q5M-cg-NOt" secondAttribute="leading" constant="15" id="q1y-Er-rpB"/>
+                <constraint firstItem="978-fQ-MSf" firstAttribute="bottom" secondItem="Q5M-cg-NOt" secondAttribute="bottom" id="tHC-5l-Njf"/>
+            </constraints>
+            <viewLayoutGuide key="safeArea" id="Q5M-cg-NOt"/>
+            <point key="canvasLocation" x="132" y="139.880059970015"/>
+        </view>
+    </objects>
+    <resources>
+        <image name="icon_paimingfen" width="20" height="20"/>
+        <image name="morentouxiang" width="45" height="45"/>
+    </resources>
+</document>

+ 51 - 3
model/Classes/Controllers/Controller/RankVC/RankController.m

@@ -7,16 +7,41 @@
 //
 
 #import "RankController.h"
+#import "RankChildController.h"
+#import "TabControl.h"
 
-@interface RankController ()
-
+@interface RankController () <UIScrollViewDelegate, TabControlDelegate>
+@property (weak, nonatomic) IBOutlet UIScrollView *scrollView;
+@property (nonatomic, strong) RankChildController* weekVC;
+@property (nonatomic, strong) RankChildController* monthVC;
+@property (weak, nonatomic) IBOutlet TabControl *tabControl;
 @end
 
 @implementation RankController
 
 - (void)viewDidLoad {
     [super viewDidLoad];
-    // Do any additional setup after loading the view from its nib.
+    self.scrollView.delegate = self;
+    self.tabControl.delegate = self;
+    self.weekVC = [[RankChildController alloc] init];
+    self.weekVC.type = @"week";
+    self.monthVC = [[RankChildController alloc] init];
+    self.monthVC.type = @"month";
+    [self addChildViewController:self.weekVC];
+    [self addChildViewController:self.monthVC];
+    self.weekVC.view.frame = CGRectMake(0, 0, self.scrollView.bounds.size.width, self.scrollView.bounds.size.height);
+    self.monthVC.view.frame = CGRectMake(self.scrollView.bounds.size.width, 0, self.scrollView.bounds.size.width, self.scrollView.bounds.size.height);
+    [self.scrollView addSubview:self.weekVC.view];
+    [self.scrollView addSubview:self.monthVC.view];
+}
+
+
+- (void)viewWillAppear:(BOOL)animated {
+    [self.navigationController setNavigationBarHidden:YES animated:NO];
+}
+
+- (void)viewWillDisappear:(BOOL)animated {
+    [self.navigationController setNavigationBarHidden:NO animated:YES];
 }
 
 - (void)viewDidLayoutSubviews {
@@ -28,6 +53,29 @@
     gl.colors = @[(__bridge id)[UIColor colorWithRed:251/255.0 green:92/255.0 blue:163/255.0 alpha:1].CGColor, (__bridge id)[UIColor colorWithRed:253/255.0 green:127/255.0 blue:141/255.0 alpha:1].CGColor];
     gl.locations = @[@(0), @(1.0f)];
     [self.view.layer insertSublayer:gl atIndex:0];
+    self.scrollView.contentSize = CGSizeMake(2 *  [UIScreen mainScreen].bounds.size.width, 0);
+    [self.weekVC.view layoutIfNeeded];
+    [self.monthVC.view layoutIfNeeded];
 }
 
+- (IBAction)backClick:(id)sender {
+    [self.navigationController popViewControllerAnimated:YES];
+}
+
+- (UIStatusBarStyle)preferredStatusBarStyle {
+    return UIStatusBarStyleLightContent;
+}
+
+#pragma mark - UIScrollView Delegate
+- (void)scrollViewDidEndDecelerating:(UIScrollView *)scrollView {
+    int index = scrollView.contentOffset.x / scrollView.frame.size.width;
+    self.tabControl.index = index;
+}
+#pragma mark -
+
+#pragma mark - TabControl Delegate
+- (void)tabChange:(NSInteger)index {
+    [self.scrollView setContentOffset:CGPointMake(self.scrollView.frame.size.width * index, 0) animated:YES];
+}
+#pragma mark -
 @end

+ 30 - 1
model/Classes/Controllers/Controller/RankVC/RankController.xib

@@ -12,6 +12,8 @@
     <objects>
         <placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="RankController">
             <connections>
+                <outlet property="scrollView" destination="6hS-jd-bqx" id="SA5-ev-x4i"/>
+                <outlet property="tabControl" destination="ko1-yQ-XVA" id="jDA-WM-way"/>
                 <outlet property="view" destination="i5M-Pr-FkT" id="sfx-zR-JGt"/>
             </connections>
         </placeholder>
@@ -28,16 +30,35 @@
                             <subviews>
                                 <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="ko1-yQ-XVA" customClass="TabControl">
                                     <rect key="frame" x="97.5" y="5" width="180" height="34"/>
-                                    <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                    <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
                                     <constraints>
                                         <constraint firstAttribute="height" constant="34" id="IWo-st-isA"/>
                                         <constraint firstAttribute="width" constant="180" id="sfK-gE-naS"/>
                                     </constraints>
+                                    <userDefinedRuntimeAttributes>
+                                        <userDefinedRuntimeAttribute type="color" keyPath="activeColor">
+                                            <color key="value" red="1" green="0.25098039215686274" blue="0.58431372549019611" alpha="1" colorSpace="calibratedRGB"/>
+                                        </userDefinedRuntimeAttribute>
+                                        <userDefinedRuntimeAttribute type="color" keyPath="normalColor">
+                                            <color key="value" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                        </userDefinedRuntimeAttribute>
+                                        <userDefinedRuntimeAttribute type="color" keyPath="indicatorColor">
+                                            <color key="value" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                        </userDefinedRuntimeAttribute>
+                                        <userDefinedRuntimeAttribute type="color" keyPath="backgroungColor">
+                                            <color key="value" red="0.0" green="0.0" blue="0.0" alpha="0.26000000000000001" colorSpace="calibratedRGB"/>
+                                        </userDefinedRuntimeAttribute>
+                                        <userDefinedRuntimeAttribute type="string" keyPath="tab1" value="周榜"/>
+                                        <userDefinedRuntimeAttribute type="string" keyPath="tab2" value="月榜"/>
+                                    </userDefinedRuntimeAttributes>
                                 </view>
                                 <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="g9p-6J-Zsw">
                                     <rect key="frame" x="0.0" y="1" width="39" height="42"/>
                                     <inset key="contentEdgeInsets" minX="20" minY="10" maxX="10" maxY="10"/>
                                     <state key="normal" image="fanhui1"/>
+                                    <connections>
+                                        <action selector="backClick:" destination="-1" eventType="touchUpInside" id="F87-cg-lWq"/>
+                                    </connections>
                                 </button>
                             </subviews>
                             <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
@@ -57,15 +78,23 @@
                         <constraint firstAttribute="bottom" secondItem="kNP-sh-is1" secondAttribute="bottom" id="pOS-7e-jYR"/>
                     </constraints>
                 </view>
+                <scrollView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" pagingEnabled="YES" showsHorizontalScrollIndicator="NO" showsVerticalScrollIndicator="NO" translatesAutoresizingMaskIntoConstraints="NO" id="6hS-jd-bqx">
+                    <rect key="frame" x="0.0" y="64" width="375" height="603"/>
+                </scrollView>
             </subviews>
             <color key="backgroundColor" red="1" green="0.25098039220000001" blue="0.58431372550000005" alpha="1" colorSpace="calibratedRGB"/>
             <constraints>
                 <constraint firstItem="Q5M-cg-NOt" firstAttribute="top" secondItem="hxE-cK-4e8" secondAttribute="bottom" constant="-44" id="0JZ-db-58O"/>
+                <constraint firstItem="6hS-jd-bqx" firstAttribute="leading" secondItem="Q5M-cg-NOt" secondAttribute="leading" id="3fk-nN-SsQ"/>
                 <constraint firstItem="Q5M-cg-NOt" firstAttribute="trailing" secondItem="hxE-cK-4e8" secondAttribute="trailing" id="E36-7X-daW"/>
                 <constraint firstItem="hxE-cK-4e8" firstAttribute="top" secondItem="i5M-Pr-FkT" secondAttribute="top" id="NNZ-H4-qNs"/>
                 <constraint firstItem="hxE-cK-4e8" firstAttribute="leading" secondItem="Q5M-cg-NOt" secondAttribute="leading" id="Nc3-Hy-SGg"/>
+                <constraint firstItem="6hS-jd-bqx" firstAttribute="top" secondItem="hxE-cK-4e8" secondAttribute="bottom" id="Wct-uh-g4H"/>
+                <constraint firstItem="6hS-jd-bqx" firstAttribute="trailing" secondItem="Q5M-cg-NOt" secondAttribute="trailing" id="aSj-NG-iZQ"/>
+                <constraint firstItem="6hS-jd-bqx" firstAttribute="bottom" secondItem="Q5M-cg-NOt" secondAttribute="bottom" id="k5k-vr-a2Q"/>
             </constraints>
             <viewLayoutGuide key="safeArea" id="Q5M-cg-NOt"/>
+            <point key="canvasLocation" x="40.799999999999997" y="46.326836581709152"/>
         </view>
     </objects>
     <resources>

+ 17 - 0
model/Classes/Controllers/Controller/RankVC/RankHeader.h

@@ -0,0 +1,17 @@
+//
+//  RankHeader.h
+//  model
+//
+//  Created by Drew on 2018/11/2.
+//  Copyright © 2018 Mine. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+NS_ASSUME_NONNULL_BEGIN
+
+@interface RankHeader : UIView
+@property(nonatomic, strong) NSArray* data;
+@end
+
+NS_ASSUME_NONNULL_END

+ 74 - 0
model/Classes/Controllers/Controller/RankVC/RankHeader.m

@@ -0,0 +1,74 @@
+//
+//  RankHeader.m
+//  model
+//
+//  Created by Drew on 2018/11/2.
+//  Copyright © 2018 Mine. All rights reserved.
+//
+
+#import "RankHeader.h"
+@interface RankHeader()
+@property (weak, nonatomic) IBOutlet UIView *bgView;
+@property (weak, nonatomic) IBOutlet UIImageView *avatar1;
+@property (weak, nonatomic) IBOutlet UIImageView *avatar2;
+@property (weak, nonatomic) IBOutlet UIImageView *avatar3;
+@property (weak, nonatomic) IBOutlet UILabel *name1;
+@property (weak, nonatomic) IBOutlet UILabel *num1;
+@property (weak, nonatomic) IBOutlet UILabel *name2;
+@property (weak, nonatomic) IBOutlet UILabel *num2;
+@property (weak, nonatomic) IBOutlet UILabel *name3;
+@property (weak, nonatomic) IBOutlet UILabel *num3;
+@end
+@implementation RankHeader
+
+- (instancetype)initWithFrame:(CGRect)frame {
+    if (self = [super initWithFrame:frame]) {
+        [self initView];
+    }
+    return self;
+}
+
+- (instancetype)initWithCoder:(NSCoder *)aDecoder {
+    if (self = [super initWithCoder:aDecoder]) {
+        [self initView];
+    }
+    return self;
+}
+
+- (void) initView {
+    NSBundle *bundle = [NSBundle bundleForClass:[self class]];
+    NSString *className = NSStringFromClass([self class]);
+    UIView *view = [[bundle loadNibNamed:className owner:self options:nil] firstObject];
+    view.frame = self.bounds;
+    view.backgroundColor = [UIColor clearColor];
+    [self addSubview:view];
+    
+    UIBezierPath *maskPath = [UIBezierPath bezierPathWithRoundedRect:self.bgView.bounds byRoundingCorners:UIRectCornerTopLeft | UIRectCornerTopRight cornerRadii:CGSizeMake(22, 22)];
+    CAShapeLayer *maskLayer = [[CAShapeLayer alloc] init];
+    maskLayer.frame = self.bgView.bounds;
+    maskLayer.path = maskPath.CGPath;
+    self.bgView.layer.mask = maskLayer;
+}
+
+- (void)setData:(NSArray *)data {
+    if (data.count >= 1) {
+        [self.avatar1 sd_setImageWithURL:[NSURL URLWithString:[NSString stringWithFormat:@"%@%@", imageURl, data[0][@"avatar"]]]
+                        placeholderImage:[UIImage imageNamed:@"morentouxinag"]];
+        self.name1.text = data[0][@"name"];
+        self.num1.text = [[NSDecimalNumber numberWithDouble:[data[0][@"coin"] doubleValue]] stringValue];
+    }
+    if (data.count >= 2) {
+        [self.avatar2 sd_setImageWithURL:[NSURL URLWithString:[NSString stringWithFormat:@"%@%@", imageURl, data[1][@"avatar"]]]
+                        placeholderImage:[UIImage imageNamed:@"morentouxinag"]];
+        self.name2.text = data[1][@"name"];
+        self.num2.text = [[NSDecimalNumber numberWithDouble:[data[1][@"coin"] doubleValue]] stringValue];
+    }
+    if (data.count >= 3) {
+        [self.avatar3 sd_setImageWithURL:[NSURL URLWithString:[NSString stringWithFormat:@"%@%@", imageURl, data[2][@"avatar"]]]
+                        placeholderImage:[UIImage imageNamed:@"morentouxinag"]];
+        self.name3.text = data[2][@"name"];
+        self.num3.text = [[NSDecimalNumber numberWithDouble:[data[2][@"coin"] doubleValue]] stringValue];
+    }
+}
+
+@end

+ 224 - 0
model/Classes/Controllers/Controller/RankVC/RankHeader.xib

@@ -0,0 +1,224 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="14313.18" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
+    <device id="retina5_9" orientation="portrait">
+        <adaptation id="fullscreen"/>
+    </device>
+    <dependencies>
+        <deployment identifier="iOS"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14283.14"/>
+        <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
+    </dependencies>
+    <objects>
+        <placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="RankHeader">
+            <connections>
+                <outlet property="avatar1" destination="C1d-3i-71o" id="V1M-rE-Edx"/>
+                <outlet property="avatar2" destination="GEg-PB-sZk" id="hEs-MC-yaY"/>
+                <outlet property="avatar3" destination="TBW-WJ-2Uv" id="EQb-oc-Zji"/>
+                <outlet property="bgView" destination="YsW-sY-12H" id="5jD-YA-NtG"/>
+                <outlet property="name1" destination="ZxW-Sx-ibw" id="igw-tb-fWN"/>
+                <outlet property="name2" destination="HfO-Ex-Tte" id="vti-Bm-lTv"/>
+                <outlet property="name3" destination="GOG-oU-O1z" id="r4k-j1-22G"/>
+                <outlet property="num1" destination="35Q-IP-9mM" id="u7c-hX-zLo"/>
+                <outlet property="num2" destination="Ded-8Y-ZYx" id="7f6-CK-n0h"/>
+                <outlet property="num3" destination="Hzc-BQ-v4Z" id="rE7-5V-YW7"/>
+            </connections>
+        </placeholder>
+        <placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
+        <view contentMode="scaleToFill" id="iN0-l3-epB">
+            <rect key="frame" x="0.0" y="0.0" width="345" height="240"/>
+            <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
+            <subviews>
+                <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="xTf-ch-rh2">
+                    <rect key="frame" x="101.66666666666669" y="0.0" width="142" height="142"/>
+                    <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                    <constraints>
+                        <constraint firstAttribute="width" constant="142" id="3G4-SD-zoB"/>
+                        <constraint firstAttribute="height" constant="142" id="PUv-Wq-cMw"/>
+                    </constraints>
+                    <userDefinedRuntimeAttributes>
+                        <userDefinedRuntimeAttribute type="number" keyPath="layer.cornerRadius">
+                            <integer key="value" value="71"/>
+                        </userDefinedRuntimeAttribute>
+                    </userDefinedRuntimeAttributes>
+                </view>
+                <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="YsW-sY-12H">
+                    <rect key="frame" x="0.0" y="47" width="345" height="193"/>
+                    <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                </view>
+                <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="morentouxiang" translatesAutoresizingMaskIntoConstraints="NO" id="C1d-3i-71o" userLabel="avatar1">
+                    <rect key="frame" x="142" y="45" width="64" height="64"/>
+                    <constraints>
+                        <constraint firstAttribute="width" constant="64" id="2k0-os-ehc"/>
+                        <constraint firstAttribute="height" constant="64" id="x6c-B6-Fhv"/>
+                    </constraints>
+                    <userDefinedRuntimeAttributes>
+                        <userDefinedRuntimeAttribute type="boolean" keyPath="layer.masksToBounds" value="YES"/>
+                        <userDefinedRuntimeAttribute type="number" keyPath="layer.cornerRadius">
+                            <integer key="value" value="32"/>
+                        </userDefinedRuntimeAttribute>
+                    </userDefinedRuntimeAttributes>
+                </imageView>
+                <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="morentouxiang" translatesAutoresizingMaskIntoConstraints="NO" id="GEg-PB-sZk" userLabel="avatar2">
+                    <rect key="frame" x="30.666666666666671" y="110" width="54" height="54"/>
+                    <constraints>
+                        <constraint firstAttribute="height" constant="54" id="4Cs-WB-oLf"/>
+                        <constraint firstAttribute="width" constant="54" id="7d4-3k-kTa"/>
+                    </constraints>
+                    <userDefinedRuntimeAttributes>
+                        <userDefinedRuntimeAttribute type="boolean" keyPath="layer.masksToBounds" value="YES"/>
+                        <userDefinedRuntimeAttribute type="number" keyPath="layer.cornerRadius">
+                            <integer key="value" value="27"/>
+                        </userDefinedRuntimeAttribute>
+                    </userDefinedRuntimeAttributes>
+                </imageView>
+                <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="morentouxiang" translatesAutoresizingMaskIntoConstraints="NO" id="TBW-WJ-2Uv" userLabel="avatar3">
+                    <rect key="frame" x="257" y="110" width="54" height="54"/>
+                    <constraints>
+                        <constraint firstAttribute="width" constant="54" id="ctZ-dM-bXf"/>
+                        <constraint firstAttribute="height" constant="54" id="kqA-xg-cLr"/>
+                    </constraints>
+                    <userDefinedRuntimeAttributes>
+                        <userDefinedRuntimeAttribute type="boolean" keyPath="layer.masksToBounds" value="YES"/>
+                        <userDefinedRuntimeAttribute type="number" keyPath="layer.cornerRadius">
+                            <integer key="value" value="27"/>
+                        </userDefinedRuntimeAttribute>
+                    </userDefinedRuntimeAttributes>
+                </imageView>
+                <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="mask_no1" translatesAutoresizingMaskIntoConstraints="NO" id="Jr1-L6-Nvn">
+                    <rect key="frame" x="119" y="23" width="107" height="95"/>
+                    <constraints>
+                        <constraint firstAttribute="width" constant="107" id="CMw-lK-WuC"/>
+                        <constraint firstAttribute="height" constant="95" id="Woo-so-mcU"/>
+                    </constraints>
+                </imageView>
+                <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="mask_no2" translatesAutoresizingMaskIntoConstraints="NO" id="aZM-6f-Yf9">
+                    <rect key="frame" x="20" y="90" width="80" height="85"/>
+                    <constraints>
+                        <constraint firstAttribute="height" constant="85" id="Rql-02-KIb"/>
+                        <constraint firstAttribute="width" constant="80" id="U4T-zn-jt0"/>
+                    </constraints>
+                </imageView>
+                <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="mask_no3" translatesAutoresizingMaskIntoConstraints="NO" id="LbT-ZC-tHQ">
+                    <rect key="frame" x="245" y="90" width="80" height="85"/>
+                    <constraints>
+                        <constraint firstAttribute="height" constant="85" id="1B7-uS-wem"/>
+                        <constraint firstAttribute="width" constant="80" id="Dfl-ie-eZ3"/>
+                    </constraints>
+                </imageView>
+                <stackView opaque="NO" contentMode="scaleToFill" axis="vertical" alignment="center" spacing="2" translatesAutoresizingMaskIntoConstraints="NO" id="dTW-UP-oKe">
+                    <rect key="frame" x="158.33333333333334" y="122" width="31.333333333333343" height="40"/>
+                    <subviews>
+                        <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text=" " textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="ZxW-Sx-ibw">
+                            <rect key="frame" x="13.666666666666657" y="0.0" width="4" height="18"/>
+                            <fontDescription key="fontDescription" type="system" weight="medium" pointSize="15"/>
+                            <nil key="textColor"/>
+                            <nil key="highlightedColor"/>
+                        </label>
+                        <stackView opaque="NO" contentMode="scaleToFill" alignment="center" spacing="2" translatesAutoresizingMaskIntoConstraints="NO" id="zQz-H3-nYQ">
+                            <rect key="frame" x="0.0" y="20" width="31.333333333333332" height="20"/>
+                            <subviews>
+                                <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="icon_paimingfen" translatesAutoresizingMaskIntoConstraints="NO" id="a0c-RE-yw1">
+                                    <rect key="frame" x="0.0" y="0.0" width="20" height="20"/>
+                                </imageView>
+                                <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="0" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="35Q-IP-9mM">
+                                    <rect key="frame" x="22" y="1.6666666666666572" width="9.3333333333333357" height="17"/>
+                                    <fontDescription key="fontDescription" type="system" weight="semibold" pointSize="14"/>
+                                    <color key="textColor" red="1" green="0.25098039220000001" blue="0.58431372550000005" alpha="1" colorSpace="calibratedRGB"/>
+                                    <nil key="highlightedColor"/>
+                                </label>
+                            </subviews>
+                        </stackView>
+                    </subviews>
+                </stackView>
+                <stackView opaque="NO" contentMode="scaleToFill" axis="vertical" alignment="center" spacing="2" translatesAutoresizingMaskIntoConstraints="NO" id="IdT-ML-t70">
+                    <rect key="frame" x="42" y="179" width="31.333333333333329" height="40"/>
+                    <subviews>
+                        <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text=" " textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="HfO-Ex-Tte">
+                            <rect key="frame" x="13.666666666666664" y="0.0" width="4" height="18"/>
+                            <fontDescription key="fontDescription" type="system" weight="medium" pointSize="15"/>
+                            <nil key="textColor"/>
+                            <nil key="highlightedColor"/>
+                        </label>
+                        <stackView opaque="NO" contentMode="scaleToFill" alignment="center" spacing="2" translatesAutoresizingMaskIntoConstraints="NO" id="tNs-cZ-2wX">
+                            <rect key="frame" x="0.0" y="20" width="31.333333333333332" height="20"/>
+                            <subviews>
+                                <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="icon_paimingfen" translatesAutoresizingMaskIntoConstraints="NO" id="OKm-Lw-fP7">
+                                    <rect key="frame" x="0.0" y="0.0" width="20" height="20"/>
+                                </imageView>
+                                <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="0" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Ded-8Y-ZYx">
+                                    <rect key="frame" x="22" y="1.6666666666666572" width="9.3333333333333357" height="17"/>
+                                    <fontDescription key="fontDescription" type="system" weight="semibold" pointSize="14"/>
+                                    <color key="textColor" red="1" green="0.25098039220000001" blue="0.58431372550000005" alpha="1" colorSpace="calibratedRGB"/>
+                                    <nil key="highlightedColor"/>
+                                </label>
+                            </subviews>
+                        </stackView>
+                    </subviews>
+                </stackView>
+                <stackView opaque="NO" contentMode="scaleToFill" axis="vertical" alignment="center" spacing="2" translatesAutoresizingMaskIntoConstraints="NO" id="NPQ-qD-PF1">
+                    <rect key="frame" x="268.33333333333331" y="179" width="31.333333333333314" height="40"/>
+                    <subviews>
+                        <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text=" " textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="GOG-oU-O1z">
+                            <rect key="frame" x="13.666666666666686" y="0.0" width="4" height="18"/>
+                            <fontDescription key="fontDescription" type="system" weight="medium" pointSize="15"/>
+                            <nil key="textColor"/>
+                            <nil key="highlightedColor"/>
+                        </label>
+                        <stackView opaque="NO" contentMode="scaleToFill" alignment="center" spacing="2" translatesAutoresizingMaskIntoConstraints="NO" id="esa-eL-dnc">
+                            <rect key="frame" x="0.0" y="20" width="31.333333333333332" height="20"/>
+                            <subviews>
+                                <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="icon_paimingfen" translatesAutoresizingMaskIntoConstraints="NO" id="Y63-zx-WVD">
+                                    <rect key="frame" x="0.0" y="0.0" width="20" height="20"/>
+                                </imageView>
+                                <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="0" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Hzc-BQ-v4Z">
+                                    <rect key="frame" x="22" y="1.6666666666666572" width="9.3333333333333357" height="17"/>
+                                    <fontDescription key="fontDescription" type="system" weight="semibold" pointSize="14"/>
+                                    <color key="textColor" red="1" green="0.25098039220000001" blue="0.58431372550000005" alpha="1" colorSpace="calibratedRGB"/>
+                                    <nil key="highlightedColor"/>
+                                </label>
+                            </subviews>
+                        </stackView>
+                    </subviews>
+                </stackView>
+            </subviews>
+            <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+            <constraints>
+                <constraint firstItem="TBW-WJ-2Uv" firstAttribute="top" secondItem="iN0-l3-epB" secondAttribute="top" constant="110" id="0HB-YI-wJE"/>
+                <constraint firstItem="NPQ-qD-PF1" firstAttribute="centerX" secondItem="TBW-WJ-2Uv" secondAttribute="centerX" id="1UW-0i-5Mw"/>
+                <constraint firstItem="xTf-ch-rh2" firstAttribute="top" secondItem="iN0-l3-epB" secondAttribute="top" id="6MO-Ez-sg2"/>
+                <constraint firstAttribute="trailing" secondItem="LbT-ZC-tHQ" secondAttribute="trailing" constant="20" id="9M9-6c-qZk"/>
+                <constraint firstItem="NPQ-qD-PF1" firstAttribute="top" secondItem="LbT-ZC-tHQ" secondAttribute="bottom" constant="4" id="Au8-6i-Mg5"/>
+                <constraint firstItem="C1d-3i-71o" firstAttribute="centerX" secondItem="iN0-l3-epB" secondAttribute="centerX" constant="1.5" id="DWg-N9-ro7"/>
+                <constraint firstAttribute="trailing" secondItem="TBW-WJ-2Uv" secondAttribute="trailing" constant="34" id="FZ3-eX-nOx"/>
+                <constraint firstItem="Jr1-L6-Nvn" firstAttribute="top" secondItem="iN0-l3-epB" secondAttribute="top" constant="23" id="GpG-8I-Qgv"/>
+                <constraint firstItem="IdT-ML-t70" firstAttribute="centerX" secondItem="GEg-PB-sZk" secondAttribute="centerX" id="HJp-xU-NWB"/>
+                <constraint firstItem="YsW-sY-12H" firstAttribute="leading" secondItem="iN0-l3-epB" secondAttribute="leading" id="Nno-P8-3LV"/>
+                <constraint firstItem="YsW-sY-12H" firstAttribute="top" secondItem="iN0-l3-epB" secondAttribute="top" constant="47" id="OEJ-33-dwd"/>
+                <constraint firstItem="Jr1-L6-Nvn" firstAttribute="centerX" secondItem="iN0-l3-epB" secondAttribute="centerX" id="SI3-O7-2IT"/>
+                <constraint firstItem="IdT-ML-t70" firstAttribute="top" secondItem="aZM-6f-Yf9" secondAttribute="bottom" constant="4" id="T5B-GL-OSN"/>
+                <constraint firstItem="GEg-PB-sZk" firstAttribute="top" secondItem="iN0-l3-epB" secondAttribute="top" constant="110" id="TMr-42-Pmm"/>
+                <constraint firstAttribute="trailing" secondItem="YsW-sY-12H" secondAttribute="trailing" id="VrV-24-akd"/>
+                <constraint firstItem="C1d-3i-71o" firstAttribute="top" secondItem="iN0-l3-epB" secondAttribute="top" constant="45" id="bBn-MZ-8Sd"/>
+                <constraint firstItem="dTW-UP-oKe" firstAttribute="centerX" secondItem="C1d-3i-71o" secondAttribute="centerX" id="dfq-vR-lvv"/>
+                <constraint firstItem="LbT-ZC-tHQ" firstAttribute="top" secondItem="iN0-l3-epB" secondAttribute="top" constant="90" id="i6f-NP-Zxq"/>
+                <constraint firstItem="xTf-ch-rh2" firstAttribute="centerX" secondItem="iN0-l3-epB" secondAttribute="centerX" id="jXJ-6f-a6f"/>
+                <constraint firstItem="aZM-6f-Yf9" firstAttribute="top" secondItem="iN0-l3-epB" secondAttribute="top" constant="90" id="pE3-gd-waJ"/>
+                <constraint firstAttribute="bottom" secondItem="YsW-sY-12H" secondAttribute="bottom" id="qGR-wl-hmL"/>
+                <constraint firstItem="dTW-UP-oKe" firstAttribute="top" secondItem="Jr1-L6-Nvn" secondAttribute="bottom" constant="4" id="qe1-iM-XnY"/>
+                <constraint firstItem="aZM-6f-Yf9" firstAttribute="leading" secondItem="iN0-l3-epB" secondAttribute="leading" constant="20" id="vPf-Jh-oRa"/>
+                <constraint firstItem="GEg-PB-sZk" firstAttribute="leading" secondItem="iN0-l3-epB" secondAttribute="leading" constant="30.5" id="vVr-s2-RMF"/>
+            </constraints>
+            <nil key="simulatedTopBarMetrics"/>
+            <nil key="simulatedBottomBarMetrics"/>
+            <freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
+            <point key="canvasLocation" x="92" y="234.97536945812809"/>
+        </view>
+    </objects>
+    <resources>
+        <image name="icon_paimingfen" width="20" height="20"/>
+        <image name="mask_no1" width="105" height="95"/>
+        <image name="mask_no2" width="81" height="85"/>
+        <image name="mask_no3" width="81" height="85"/>
+        <image name="morentouxiang" width="45" height="45"/>
+    </resources>
+</document>

+ 1 - 0
model/Classes/Controllers/Model/ModelUser.h

@@ -56,6 +56,7 @@
 //学校
 @property (nonatomic ,copy) NSString *college;
 
+@property (nonatomic, assign) BOOL is_a;
 
 @property (nonatomic ,copy) NSString *token;
 /**

+ 11 - 6
model/ModelHeader.h

@@ -19,14 +19,14 @@
 //#define imageURl @"http://118.190.49.85:8080/thmodeltest/"
 //#define apnsCernameStr @"chmoModelTest"
 
-//#define PublicUrl @"http://192.168.50.132:8081"
-//#define imageURl @"http://192.168.50.132:8081/"
-//#define apnsCernameStr @"chmoMemberTest"
-
-#define PublicUrl @"http://192.168.123.90:8080"
-#define imageURl @"http://192.168.123.90:8080/"
+#define PublicUrl @"http://192.168.50.132:8081"
+#define imageURl @"http://192.168.50.132:8081/"
 #define apnsCernameStr @"chmoMemberTest"
 
+//#define PublicUrl @"http://192.168.123.90:8080"
+//#define imageURl @"http://192.168.123.90:8080/"
+//#define apnsCernameStr @"chmoMemberTest"
+
 #define shareUrl(type,code) [NSString stringWithFormat:@"%@/share.jsp?type=%@&code=%@", PublicUrl, type, code]
 
 //应用下载地址 https://itunes.apple.com/cn/app/id1434011196?mt=8
@@ -137,6 +137,11 @@
 #define Url_getCurrentShareCoin(x) [NSString stringWithFormat:@"%@/memberInfo?action=getCurrentShareCoin", x]
 
 #define Url_transferCoin(x) [NSString stringWithFormat:@"%@/memberInfo?action=transferShareCoin", x]
+
+#define Url_rank(x)  [NSString stringWithFormat:@"%@/modelInfo?action=rank", x]
+
+#define Url_setOnline(x)  [NSString stringWithFormat:@"%@/model?action=setOnline", x]
+
 #endif /* ModelHeader_h */