Skip to content

Commit

Permalink
新增cell,资源图片
Browse files Browse the repository at this point in the history
  • Loading branch information
lookingstars committed Sep 24, 2015
1 parent ac394b6 commit ca9271b
Show file tree
Hide file tree
Showing 197 changed files with 1,473 additions and 30 deletions.
780 changes: 780 additions & 0 deletions nuomi.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

Binary file not shown.
278 changes: 248 additions & 30 deletions nuomi/Base.lproj/Main.storyboard

Large diffs are not rendered by default.

13 changes: 13 additions & 0 deletions nuomi/Controller/首页/JZHomeViewController.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
//
// JZHomeViewController.h
// nuomi
//
// Created by jinzelu on 15/9/24.
// Copyright (c) 2015年 jinzelu. All rights reserved.
//

#import <UIKit/UIKit.h>

@interface JZHomeViewController : UIViewController

@end
109 changes: 109 additions & 0 deletions nuomi/Controller/首页/JZHomeViewController.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
//
// JZHomeViewController.m
// nuomi
//
// Created by jinzelu on 15/9/24.
// Copyright (c) 2015年 jinzelu. All rights reserved.
//

#import "JZHomeViewController.h"
#import "JZHomeShopCell.h"
#import "JZHomeNewCell.h"

@interface JZHomeViewController ()<UITableViewDataSource, UITableViewDelegate>

@property (weak, nonatomic) IBOutlet UILabel *cityNameLabel;

@property (weak, nonatomic) IBOutlet UITextField *searchTextField;

@property (weak, nonatomic) IBOutlet UITableView *tableView;






@end

@implementation JZHomeViewController

- (void)viewDidLoad {
[super viewDidLoad];
// Do any additional setup after loading the view.


self.tableView.tableFooterView = [[UIView alloc] initWithFrame:CGRectZero];
}

- (void)didReceiveMemoryWarning {
[super didReceiveMemoryWarning];
// Dispose of any resources that can be recreated.
}

- (IBAction)OnSaoyisaoBtn:(UIButton *)sender {
NSLog(@"扫一扫");
}

- (IBAction)OnGouwucheBtn:(UIButton *)sender {
NSLog(@"购物车");
}

- (IBAction)OnMoreCityBtn:(id)sender {
NSLog(@"选择城市");
}

#pragma mark - **************** UITableViewDataSource
-(NSInteger)numberOfSectionsInTableView:(UITableView *)tableView {
return 1;
}
-(NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
return 2;
}

-(CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath{
if (indexPath.row == 0) {
return 80;
}else{
return 96;
}
}

-(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
if (indexPath.row == 0) {
static NSString *cellIndentifier = @"JZHomeNewCell";
JZHomeNewCell *cell = [tableView dequeueReusableCellWithIdentifier:cellIndentifier];

//赋值
return cell;
}else{
static NSString *cellIndentifier = @"JZHomeShopCell";
JZHomeShopCell *cell = [tableView dequeueReusableCellWithIdentifier:cellIndentifier];

//赋值
return cell;
}
}




#pragma mark - **************** UITableViewDelegate
-(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{

}





/*
#pragma mark - Navigation
// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
// Get the new view controller using [segue destinationViewController].
// Pass the selected object to the new view controller.
}
*/

@end
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x",
"filename" : "account_place_holder@2x.png"
},
{
"idiom" : "universal",
"scale" : "3x",
"filename" : "account_place_holder@3x.png"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x",
"filename" : "com_imageloading_l@2x.png"
},
{
"idiom" : "universal",
"scale" : "3x",
"filename" : "com_imageloading_l@3x.png"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x",
"filename" : "com_imageloading_m@2x.png"
},
{
"idiom" : "universal",
"scale" : "3x",
"filename" : "com_imageloading_m@3x.png"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x",
"filename" : "com_imageloading_s@2x.png"
},
{
"idiom" : "universal",
"scale" : "3x",
"filename" : "com_imageloading_s@3x.png"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x",
"filename" : "detailViewDefaultGaussImage@2x.png"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x",
"filename" : "detailViewDefaultMidImage@2x.png"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
22 changes: 22 additions & 0 deletions nuomi/Images.xcassets/placeholder/touxiang.imageset/Contents.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x",
"filename" : "touxiang@2x.png"
},
{
"idiom" : "universal",
"scale" : "3x",
"filename" : "touxiang@3x.png"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
22 changes: 22 additions & 0 deletions nuomi/Images.xcassets/placeholder/ugc_image.imageset/Contents.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x",
"filename" : "ugc_image@2x.png"
},
{
"idiom" : "universal",
"scale" : "3x",
"filename" : "ugc_image@3x.png"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
22 changes: 22 additions & 0 deletions nuomi/Images.xcassets/placeholder/ugc_photo.imageset/Contents.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x",
"filename" : "ugc_photo@2x.png"
},
{
"idiom" : "universal",
"scale" : "3x",
"filename" : "ugc_photo@3x.png"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added nuomi/Resource/动画/icon_error_coupon@2x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added nuomi/Resource/动画/icon_error_coupon@3x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added nuomi/Resource/动画/icon_error_network@2x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added nuomi/Resource/动画/icon_error_network@3x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added nuomi/Resource/动画/icon_error_unkown@2x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added nuomi/Resource/动画/icon_error_unkown@3x.png
Binary file added nuomi/Resource/动画/icon_hud_1@2x.png
Binary file added nuomi/Resource/动画/icon_hud_1@3x.png
Binary file added nuomi/Resource/动画/icon_hud_2@2x.png
Binary file added nuomi/Resource/动画/icon_hud_2@3x.png
Binary file added nuomi/Resource/动画/icon_hud_3@2x.png
Binary file added nuomi/Resource/动画/icon_hud_3@3x.png
Binary file added nuomi/Resource/动画/icon_hud_4@2x.png
Binary file added nuomi/Resource/动画/icon_hud_4@3x.png
Binary file added nuomi/Resource/动画/icon_hud_5@2x.png
Binary file added nuomi/Resource/动画/icon_hud_5@3x.png
Binary file added nuomi/Resource/动画/icon_hud_6@2x.png
Binary file added nuomi/Resource/动画/icon_hud_6@3x.png
Binary file added nuomi/Resource/动画/icon_hud_7@2x.png
Binary file added nuomi/Resource/动画/icon_hud_7@3x.png
Binary file added nuomi/Resource/动画/icon_hud_8@2x.png
Binary file added nuomi/Resource/动画/icon_hud_8@3x.png
Binary file added nuomi/Resource/动画/icon_hud_9@2x.png
Binary file added nuomi/Resource/动画/icon_hud_9@3x.png
Binary file added nuomi/Resource/动画/icon_refresh_1@2x.png
Binary file added nuomi/Resource/动画/icon_refresh_1@3x.png
Binary file added nuomi/Resource/动画/icon_refresh_2@2x.png
Binary file added nuomi/Resource/动画/icon_refresh_2@3x.png
Binary file added nuomi/Resource/动画/icon_refresh_3@2x.png
Binary file added nuomi/Resource/动画/icon_refresh_3@3x.png
Binary file added nuomi/Resource/动画/icon_refresh_4@2x.png
Binary file added nuomi/Resource/动画/icon_refresh_4@3x.png
Binary file added nuomi/Resource/动画/icon_refresh_5@2x.png
Binary file added nuomi/Resource/动画/icon_refresh_5@3x.png
Binary file added nuomi/Resource/动画/icon_refresh_6@2x.png
Binary file added nuomi/Resource/动画/icon_refresh_6@3x.png
Binary file added nuomi/Resource/动画/icon_refresh_7@2x.png
Binary file added nuomi/Resource/动画/icon_refresh_7@3x.png
Binary file added nuomi/Resource/动画/wanzi.png
Binary file added nuomi/Resource/动画/wanzi@2x.png
Binary file added nuomi/Resource/动画/wanzi@3x.png
Binary file added nuomi/Resource/箭头/brower_next_0@2x.png
Binary file added nuomi/Resource/箭头/brower_next_1@2x.png
Binary file added nuomi/Resource/箭头/brower_pre_0@2x.png
Binary file added nuomi/Resource/箭头/brower_pre_1@2x.png
Binary file added nuomi/Resource/箭头/citySelectArrow@2x.png
Binary file added nuomi/Resource/箭头/citySelectArrow@3x.png
Binary file added nuomi/Resource/箭头/close_poi_scene@2x.png
Binary file added nuomi/Resource/箭头/close_poi_scene@3x.png
Binary file added nuomi/Resource/箭头/detailViewBackRed@2x.png
Binary file added nuomi/Resource/箭头/detailViewBackRed@3x.png
Binary file added nuomi/Resource/箭头/detailViewBackWhite@2x.png
Binary file added nuomi/Resource/箭头/detailViewBackWhite@3x.png
Binary file added nuomi/Resource/箭头/dianyingxuanzuo_18@2x.png
Binary file added nuomi/Resource/箭头/dianyingxuanzuo_21@2x.png
Binary file added nuomi/Resource/箭头/dianyingxuanzuo_37@2x.png
Binary file added nuomi/Resource/箭头/dianyingxuanzuo_40@2x.png
Binary file added nuomi/Resource/箭头/dianyingxuanzuo_55@2x.png
Binary file added nuomi/Resource/箭头/dianyingxuanzuo_56@2x.png
Binary file added nuomi/Resource/箭头/float_close@2x.png
Binary file added nuomi/Resource/箭头/float_close@3x.png
Binary file added nuomi/Resource/箭头/float_close_down@2x.png
Binary file added nuomi/Resource/箭头/float_close_down@3x.png
Binary file added nuomi/Resource/箭头/greturn@2x.png
Binary file added nuomi/Resource/箭头/greturn@3x.png
Binary file added nuomi/Resource/箭头/gsafe@2x.png
Binary file added nuomi/Resource/箭头/gsafe@3x.png
Binary file added nuomi/Resource/箭头/gshare@2x.png
Binary file added nuomi/Resource/箭头/gshare@3x.png
Binary file added nuomi/Resource/箭头/guanbi@2x.png
Binary file added nuomi/Resource/箭头/guanbi_normal@2x.png
Binary file added nuomi/Resource/箭头/guanbi_normal@3x.png
Binary file added nuomi/Resource/箭头/guanbi_pressed@2x.png
Binary file added nuomi/Resource/箭头/guanbi_pressed@3x.png
Binary file added nuomi/Resource/箭头/home_arrow_down_red@2x.png
Binary file added nuomi/Resource/箭头/home_arrow_down_red@3x.png
Binary file added nuomi/Resource/箭头/home_banner_close@2x.png
Binary file added nuomi/Resource/箭头/home_banner_close@3x.png
Binary file added nuomi/Resource/箭头/ic_order_insurance@2x.png
Binary file added nuomi/Resource/箭头/ic_order_insurance@3x.png
Binary file added nuomi/Resource/箭头/ic_submit@2x.png
Binary file added nuomi/Resource/箭头/ic_submit@3x.png
Binary file added nuomi/Resource/箭头/icon_arrows_gray_down@2x.png
Binary file added nuomi/Resource/箭头/icon_arrows_gray_right@2x.png
Binary file added nuomi/Resource/箭头/icon_arrows_gray_up@2x.png
Binary file added nuomi/Resource/箭头/icon_arrows_gray_up@3x.png
Binary file added nuomi/Resource/箭头/icon_arrows_red_up@2x.png
Binary file added nuomi/Resource/箭头/icon_arrows_red_up@3x.png
Binary file added nuomi/Resource/箭头/icon_arrows_white_right@2x.png
Binary file added nuomi/Resource/箭头/icon_check_01@2x.png
Binary file added nuomi/Resource/箭头/icon_check_01@3x.png
Binary file added nuomi/Resource/箭头/icon_check_02@2x.png
Binary file added nuomi/Resource/箭头/icon_check_02@3x.png
Binary file added nuomi/Resource/箭头/icon_check_03@2x.png
Binary file added nuomi/Resource/箭头/icon_check_03@3x.png
Binary file added nuomi/Resource/箭头/icon_sms_close@2x.png
Binary file added nuomi/Resource/箭头/icon_sms_close@3x.png
Binary file added nuomi/Resource/箭头/icon_sms_open@2x.png
Binary file added nuomi/Resource/箭头/icon_sms_open@3x.png
Binary file added nuomi/Resource/箭头/icon_web_goback_dis@2x.png
Binary file added nuomi/Resource/箭头/icon_web_goback_dis@3x.png
Binary file added nuomi/Resource/箭头/icon_web_goback_hig@2x.png
Binary file added nuomi/Resource/箭头/icon_web_goback_hig@3x.png
Binary file added nuomi/Resource/箭头/pay_result_success@2x.png
Binary file added nuomi/Resource/箭头/pay_result_success@3x.png
Binary file added nuomi/Resource/箭头/recharge_pay_success@3x.png
Binary file added nuomi/Resource/箭头/recommend_cha@2x.png
Binary file added nuomi/Resource/箭头/recommend_cha@3x.png
Binary file added nuomi/Resource/箭头/s@2x.png
Binary file added nuomi/Resource/箭头/s@3x.png
Binary file added nuomi/Resource/箭头/sapi-nav-back-btn-bg.png
Binary file added nuomi/Resource/箭头/textfieldDelete@2x.png
Binary file added nuomi/Resource/箭头/textfieldDelete@3x.png
Binary file added nuomi/Resource/箭头/voice_guanbi_normal@2x.png
Binary file added nuomi/Resource/箭头/voice_guanbi_normal@3x.png
Binary file added nuomi/Resource/箭头/voice_guanbi_pressed@2x.png
Binary file added nuomi/Resource/箭头/voice_guanbi_pressed@3x.png
Binary file added nuomi/Resource/首页/icon_nav_cart_normal@2x.png
Binary file added nuomi/Resource/首页/icon_nav_cart_pressed@2x.png
13 changes: 13 additions & 0 deletions nuomi/Utility/MenuButton/JZMenuButton.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
//
// JZMenuButton.h
// nuomi
//
// Created by jinzelu on 15/9/24.
// Copyright (c) 2015年 jinzelu. All rights reserved.
//

#import <UIKit/UIKit.h>

@interface JZMenuButton : UIButton

@end
42 changes: 42 additions & 0 deletions nuomi/Utility/MenuButton/JZMenuButton.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
//
// JZMenuButton.m
// nuomi
//
// Created by jinzelu on 15/9/24.
// Copyright (c) 2015年 jinzelu. All rights reserved.
//

#import "JZMenuButton.h"

@implementation JZMenuButton


- (id)initWithFrame:(CGRect)frame {
self = [super initWithFrame:frame];
if (self) {
self.imageView.contentMode = UIViewContentModeScaleAspectFit;
self.titleLabel.textAlignment = NSTextAlignmentCenter;
self.titleLabel.font = [UIFont systemFontOfSize:12];
self.titleLabel.textColor = [UIColor blackColor];
}
return self;
}

-(void)layoutSubviews {
[super layoutSubviews];
CGFloat imageW = self.bounds.size.width;
CGFloat imageH = self.bounds.size.height * 0.8;
self.imageView.frame = CGRectMake(0, 0, imageW, imageH);

CGFloat labelH = self.bounds.size.height - imageH;
self.titleLabel.frame = CGRectMake(0, imageH, imageW, labelH);
}
/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
// Drawing code
}
*/

@end
Loading

0 comments on commit ca9271b

Please sign in to comment.