diff --git a/Doctor.xcodeproj/project.pbxproj b/Doctor.xcodeproj/project.pbxproj index 0bf2603..63666be 100644 --- a/Doctor.xcodeproj/project.pbxproj +++ b/Doctor.xcodeproj/project.pbxproj @@ -18,6 +18,14 @@ A900FD0D1C07FF88007B2E40 /* MyTopView.xib in Resources */ = {isa = PBXBuildFile; fileRef = A900FD0C1C07FF88007B2E40 /* MyTopView.xib */; }; A900FD0F1C080066007B2E40 /* avatar@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = A900FD0E1C080066007B2E40 /* avatar@2x.png */; }; A900FD111C080072007B2E40 /* avatar@3x.png in Resources */ = {isa = PBXBuildFile; fileRef = A900FD101C080072007B2E40 /* avatar@3x.png */; }; + A900FD141C080756007B2E40 /* naved@3x.png in Resources */ = {isa = PBXBuildFile; fileRef = A900FD121C080756007B2E40 /* naved@3x.png */; }; + A900FD151C080756007B2E40 /* navno@3x.png in Resources */ = {isa = PBXBuildFile; fileRef = A900FD131C080756007B2E40 /* navno@3x.png */; }; + A900FD181C0807B5007B2E40 /* naved@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = A900FD161C0807B5007B2E40 /* naved@2x.png */; }; + A900FD191C0807B5007B2E40 /* navno@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = A900FD171C0807B5007B2E40 /* navno@2x.png */; }; + A900FD1C1C0807BD007B2E40 /* serviced@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = A900FD1A1C0807BD007B2E40 /* serviced@2x.png */; }; + A900FD1D1C0807BD007B2E40 /* serviceno@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = A900FD1B1C0807BD007B2E40 /* serviceno@2x.png */; }; + A900FD201C0807D7007B2E40 /* serviced@3x.png in Resources */ = {isa = PBXBuildFile; fileRef = A900FD1E1C0807D7007B2E40 /* serviced@3x.png */; }; + A900FD211C0807D7007B2E40 /* serviceno@3x.png in Resources */ = {isa = PBXBuildFile; fileRef = A900FD1F1C0807D7007B2E40 /* serviceno@3x.png */; }; A9841F231C04357C00FB72AA /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = A9841F221C04357C00FB72AA /* main.m */; }; A9841F261C04357C00FB72AA /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = A9841F251C04357C00FB72AA /* AppDelegate.m */; }; A9841F291C04357C00FB72AA /* ViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = A9841F281C04357C00FB72AA /* ViewController.m */; }; @@ -78,6 +86,14 @@ A900FD0C1C07FF88007B2E40 /* MyTopView.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = MyTopView.xib; sourceTree = ""; }; A900FD0E1C080066007B2E40 /* avatar@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "avatar@2x.png"; sourceTree = ""; }; A900FD101C080072007B2E40 /* avatar@3x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "avatar@3x.png"; sourceTree = ""; }; + A900FD121C080756007B2E40 /* naved@3x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "naved@3x.png"; sourceTree = ""; }; + A900FD131C080756007B2E40 /* navno@3x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "navno@3x.png"; sourceTree = ""; }; + A900FD161C0807B5007B2E40 /* naved@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "naved@2x.png"; sourceTree = ""; }; + A900FD171C0807B5007B2E40 /* navno@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "navno@2x.png"; sourceTree = ""; }; + A900FD1A1C0807BD007B2E40 /* serviced@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "serviced@2x.png"; sourceTree = ""; }; + A900FD1B1C0807BD007B2E40 /* serviceno@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "serviceno@2x.png"; sourceTree = ""; }; + A900FD1E1C0807D7007B2E40 /* serviced@3x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "serviced@3x.png"; sourceTree = ""; }; + A900FD1F1C0807D7007B2E40 /* serviceno@3x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "serviceno@3x.png"; sourceTree = ""; }; A9841F1E1C04357C00FB72AA /* Doctor.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Doctor.app; sourceTree = BUILT_PRODUCTS_DIR; }; A9841F221C04357C00FB72AA /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; A9841F241C04357C00FB72AA /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; }; @@ -259,9 +275,17 @@ A900FD031C07F9EE007B2E40 /* yiliaoxuqiu@2x.png */, A900FD041C07F9EE007B2E40 /* yuyuezixun@2x.png */, A986A39A1C04CD9A00B55F38 /* myed@2x.png */, + A900FD121C080756007B2E40 /* naved@3x.png */, + A900FD131C080756007B2E40 /* navno@3x.png */, A986A39B1C04CD9A00B55F38 /* myno@2x.png */, + A900FD1E1C0807D7007B2E40 /* serviced@3x.png */, + A900FD1F1C0807D7007B2E40 /* serviceno@3x.png */, A986A3961C04CD7500B55F38 /* myno@3x.png */, A986A3971C04CD7500B55F38 /* myed@3x.png */, + A900FD1A1C0807BD007B2E40 /* serviced@2x.png */, + A900FD1B1C0807BD007B2E40 /* serviceno@2x.png */, + A900FD161C0807B5007B2E40 /* naved@2x.png */, + A900FD171C0807B5007B2E40 /* navno@2x.png */, A986A3901C04CC6700B55F38 /* seriviced@3x.png */, A986A3911C04CC6700B55F38 /* seriviceno@3x.png */, A986A38C1C04CC5D00B55F38 /* seriviced@2x.png */, @@ -454,8 +478,11 @@ A986A38B1C04CA4200B55F38 /* NavigateViewController.xib in Resources */, A9841F311C04357C00FB72AA /* LaunchScreen.storyboard in Resources */, A900FD0F1C080066007B2E40 /* avatar@2x.png in Resources */, + A900FD1C1C0807BD007B2E40 /* serviced@2x.png in Resources */, + A900FD201C0807D7007B2E40 /* serviced@3x.png in Resources */, A986A3921C04CC6700B55F38 /* seriviced@3x.png in Resources */, A9841F2E1C04357C00FB72AA /* Assets.xcassets in Resources */, + A900FD151C080756007B2E40 /* navno@3x.png in Resources */, A986A3951C04CCDC00B55F38 /* Default@3x.png in Resources */, A986A38F1C04CC5D00B55F38 /* serivicedno@2x.png in Resources */, A986A3751C04C59400B55F38 /* Default-568h@2x.png in Resources */, @@ -463,16 +490,21 @@ A986A3AD1C04D63600B55F38 /* bannerbg@2x.png in Resources */, A986A3AF1C04D64B00B55F38 /* bannerbg@3x.png in Resources */, A900FD111C080072007B2E40 /* avatar@3x.png in Resources */, + A900FD211C0807D7007B2E40 /* serviceno@3x.png in Resources */, A986A3771C04C59400B55F38 /* Default@2x.png in Resources */, A9841F2C1C04357C00FB72AA /* Main.storyboard in Resources */, A900FD051C07F9EE007B2E40 /* jiankantijian@2x.png in Resources */, + A900FD191C0807B5007B2E40 /* navno@2x.png in Resources */, A986A39C1C04CD9A00B55F38 /* myed@2x.png in Resources */, A900FD071C07F9EE007B2E40 /* yuyuezixun@2x.png in Resources */, A900FD0D1C07FF88007B2E40 /* MyTopView.xib in Resources */, A986A3981C04CD7500B55F38 /* myno@3x.png in Resources */, A986A39D1C04CD9A00B55F38 /* myno@2x.png in Resources */, + A900FD141C080756007B2E40 /* naved@3x.png in Resources */, + A900FD1D1C0807BD007B2E40 /* serviceno@2x.png in Resources */, A986A3861C04C9F400B55F38 /* MyViewController.xib in Resources */, A986A3931C04CC6700B55F38 /* seriviceno@3x.png in Resources */, + A900FD181C0807B5007B2E40 /* naved@2x.png in Resources */, A986A38E1C04CC5D00B55F38 /* seriviced@2x.png in Resources */, ); runOnlyForDeploymentPostprocessing = 0; @@ -667,9 +699,11 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; GCC_PREFIX_HEADER = Doctor/PrefixHeader.pch; INFOPLIST_FILE = Doctor/Info.plist; + IPHONEOS_DEPLOYMENT_TARGET = 7.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = ash.Doctor; PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE = "684854f2-c587-47b7-95f5-b53bb767678d"; }; name = Debug; }; @@ -680,9 +714,11 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; GCC_PREFIX_HEADER = Doctor/PrefixHeader.pch; INFOPLIST_FILE = Doctor/Info.plist; + IPHONEOS_DEPLOYMENT_TARGET = 7.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = ash.Doctor; PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE = "684854f2-c587-47b7-95f5-b53bb767678d"; }; name = Release; }; diff --git a/Doctor/Resource/naved@2x.png b/Doctor/Resource/naved@2x.png new file mode 100644 index 0000000..8a142c3 Binary files /dev/null and b/Doctor/Resource/naved@2x.png differ diff --git a/Doctor/Resource/naved@3x.png b/Doctor/Resource/naved@3x.png new file mode 100644 index 0000000..5b518b6 Binary files /dev/null and b/Doctor/Resource/naved@3x.png differ diff --git a/Doctor/Resource/navno@2x.png b/Doctor/Resource/navno@2x.png new file mode 100644 index 0000000..0ce05ae Binary files /dev/null and b/Doctor/Resource/navno@2x.png differ diff --git a/Doctor/Resource/navno@3x.png b/Doctor/Resource/navno@3x.png new file mode 100644 index 0000000..8c12c03 Binary files /dev/null and b/Doctor/Resource/navno@3x.png differ diff --git a/Doctor/Resource/serviced@2x.png b/Doctor/Resource/serviced@2x.png new file mode 100644 index 0000000..777f25d Binary files /dev/null and b/Doctor/Resource/serviced@2x.png differ diff --git a/Doctor/Resource/serviced@3x.png b/Doctor/Resource/serviced@3x.png new file mode 100644 index 0000000..b7cc065 Binary files /dev/null and b/Doctor/Resource/serviced@3x.png differ diff --git a/Doctor/Resource/serviceno@2x.png b/Doctor/Resource/serviceno@2x.png new file mode 100644 index 0000000..af89121 Binary files /dev/null and b/Doctor/Resource/serviceno@2x.png differ diff --git a/Doctor/Resource/serviceno@3x.png b/Doctor/Resource/serviceno@3x.png new file mode 100644 index 0000000..6d9b75c Binary files /dev/null and b/Doctor/Resource/serviceno@3x.png differ diff --git a/Doctor/View/MainTabBarViewController.m b/Doctor/View/MainTabBarViewController.m index 506cc6f..60f22c6 100644 --- a/Doctor/View/MainTabBarViewController.m +++ b/Doctor/View/MainTabBarViewController.m @@ -27,9 +27,9 @@ _serviceNav = [[UINavigationController alloc] initWithRootViewController:[[ServiceViewController alloc] init]]; _navigateNav = [[UINavigationController alloc] initWithRootViewController:[[NavigateViewController alloc] init]]; _myNav = [[UINavigationController alloc] initWithRootViewController:[[MyViewController alloc] init]]; - [_navigateNav setTabBarItem:[[UITabBarItem alloc] initWithTitle:@"职能导航" image:[UIImage imageNamed:@"seriviceno"] selectedImage:[UIImage imageNamed:@"seriviced"]]]; + [_navigateNav setTabBarItem:[[UITabBarItem alloc] initWithTitle:@"职能导航" image:[UIImage imageNamed:@"navno"] selectedImage:[UIImage imageNamed:@"naved"]]]; - [_serviceNav setTabBarItem:[[UITabBarItem alloc] initWithTitle:@"医疗服务" image:[UIImage imageNamed:@"seriviceno"] selectedImage:[UIImage imageNamed:@"seriviced"]]]; + [_serviceNav setTabBarItem:[[UITabBarItem alloc] initWithTitle:@"医疗服务" image:[UIImage imageNamed:@"serviceno"] selectedImage:[UIImage imageNamed:@"serviced"]]]; [_myNav setTabBarItem:[[UITabBarItem alloc] initWithTitle:@"个人中心" image:[UIImage imageNamed:@"myno"] selectedImage:[UIImage imageNamed:@"myed"]]]; self.viewControllers = @[_navigateNav,_serviceNav, _myNav]; diff --git a/Doctor/View/MyViewController.m b/Doctor/View/MyViewController.m index 3f0badb..acf146f 100644 --- a/Doctor/View/MyViewController.m +++ b/Doctor/View/MyViewController.m @@ -8,7 +8,7 @@ #import "MyViewController.h" #import "MyTopView.h" -@interface MyViewController () +@interface MyViewController () { MyTopView *_myTopView; } @@ -21,12 +21,68 @@ // Do any additional setup after loading the view from its nib. self.title = @"个人中心"; - _myTopView = [Ash_UIUtil instanceXibView:@"MyTopView"]; - - _myTopView.frame = CGRectMake(0, 0, kScreenWidth, 200); + } +-(void)viewDidAppear:(BOOL)animated +{ + [super viewDidAppear:animated]; + if (!_myTopView) + { + _myTopView = [Ash_UIUtil instanceXibView:@"MyTopView"]; + _myTopView.frame = CGRectMake(0, 0, kScreenWidth, 200); + _tableView.tableHeaderView = _myTopView; + } + +} +-(NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section +{ + int row = 0; + switch (section) { + case 0: + row = 3; + break; + case 1: + row = 1; + break; + case 2: + row = 2; + break; + case 3: + row = 2; + break; + + default: + break; + } + return row; +} +-(NSInteger)numberOfSectionsInTableView:(UITableView *)tableView +{ + return 4; +} +-(CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section +{ + if (section == 0) { + return 0.1; + } + return 5.0; +} +-(CGFloat)tableView:(UITableView *)tableView heightForFooterInSection:(NSInteger)section +{ + return 5.0; +} +-(UITableViewCell*)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath +{ + static NSString* cellIndentifier = @"cell"; + UITableViewCell* cell = [tableView dequeueReusableCellWithIdentifier:cellIndentifier]; + if(!cell){ + cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:cellIndentifier]; + } + cell.textLabel.text = @"测试"; + return cell; +} - (void)didReceiveMemoryWarning { [super didReceiveMemoryWarning]; // Dispose of any resources that can be recreated. diff --git a/Doctor/View/MyViewController.xib b/Doctor/View/MyViewController.xib index 4487c8d..e88331e 100644 --- a/Doctor/View/MyViewController.xib +++ b/Doctor/View/MyViewController.xib @@ -16,9 +16,9 @@ - + - +