Commit 2664fe89 by houweibin

1,分类图标

2,查看更多
3,其他
parent ce33fcfb
...@@ -82,6 +82,8 @@ ...@@ -82,6 +82,8 @@
C0028EC51F0DD19C00744C14 /* KWMAdditionalResult.m in Sources */ = {isa = PBXBuildFile; fileRef = C0028EC41F0DD19C00744C14 /* KWMAdditionalResult.m */; }; C0028EC51F0DD19C00744C14 /* KWMAdditionalResult.m in Sources */ = {isa = PBXBuildFile; fileRef = C0028EC41F0DD19C00744C14 /* KWMAdditionalResult.m */; };
C0028EC81F0DE80500744C14 /* KWMWish.m in Sources */ = {isa = PBXBuildFile; fileRef = C0028EC71F0DE80500744C14 /* KWMWish.m */; }; C0028EC81F0DE80500744C14 /* KWMWish.m in Sources */ = {isa = PBXBuildFile; fileRef = C0028EC71F0DE80500744C14 /* KWMWish.m */; };
C0028ECB1F0E2B3500744C14 /* KWMAdditionalListResult.m in Sources */ = {isa = PBXBuildFile; fileRef = C0028ECA1F0E2B3500744C14 /* KWMAdditionalListResult.m */; }; C0028ECB1F0E2B3500744C14 /* KWMAdditionalListResult.m in Sources */ = {isa = PBXBuildFile; fileRef = C0028ECA1F0E2B3500744C14 /* KWMAdditionalListResult.m */; };
C00D40941F187C9500DEA685 /* KWMCategoryTitleView.xib in Resources */ = {isa = PBXBuildFile; fileRef = C00D40931F187C9500DEA685 /* KWMCategoryTitleView.xib */; };
C00D40971F187CAB00DEA685 /* KWMCategoryTitleView.m in Sources */ = {isa = PBXBuildFile; fileRef = C00D40961F187CAB00DEA685 /* KWMCategoryTitleView.m */; };
C0219A951DF53EB200711099 /* KWMExchangeRateResult.m in Sources */ = {isa = PBXBuildFile; fileRef = C0219A941DF53EB200711099 /* KWMExchangeRateResult.m */; }; C0219A951DF53EB200711099 /* KWMExchangeRateResult.m in Sources */ = {isa = PBXBuildFile; fileRef = C0219A941DF53EB200711099 /* KWMExchangeRateResult.m */; };
C0243BBD1EFBD5A10013CFA7 /* Category.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = C0243BAF1EFBD5A10013CFA7 /* Category.storyboard */; }; C0243BBD1EFBD5A10013CFA7 /* Category.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = C0243BAF1EFBD5A10013CFA7 /* Category.storyboard */; };
C0243BBE1EFBD5A10013CFA7 /* KWMLeftCategoryCell.m in Sources */ = {isa = PBXBuildFile; fileRef = C0243BB21EFBD5A10013CFA7 /* KWMLeftCategoryCell.m */; }; C0243BBE1EFBD5A10013CFA7 /* KWMLeftCategoryCell.m in Sources */ = {isa = PBXBuildFile; fileRef = C0243BB21EFBD5A10013CFA7 /* KWMLeftCategoryCell.m */; };
...@@ -506,6 +508,9 @@ ...@@ -506,6 +508,9 @@
C0028EC71F0DE80500744C14 /* KWMWish.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = KWMWish.m; sourceTree = "<group>"; }; C0028EC71F0DE80500744C14 /* KWMWish.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = KWMWish.m; sourceTree = "<group>"; };
C0028EC91F0E2B3500744C14 /* KWMAdditionalListResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KWMAdditionalListResult.h; sourceTree = "<group>"; }; C0028EC91F0E2B3500744C14 /* KWMAdditionalListResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KWMAdditionalListResult.h; sourceTree = "<group>"; };
C0028ECA1F0E2B3500744C14 /* KWMAdditionalListResult.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = KWMAdditionalListResult.m; sourceTree = "<group>"; }; C0028ECA1F0E2B3500744C14 /* KWMAdditionalListResult.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = KWMAdditionalListResult.m; sourceTree = "<group>"; };
C00D40931F187C9500DEA685 /* KWMCategoryTitleView.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = KWMCategoryTitleView.xib; sourceTree = "<group>"; };
C00D40951F187CAB00DEA685 /* KWMCategoryTitleView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KWMCategoryTitleView.h; sourceTree = "<group>"; };
C00D40961F187CAB00DEA685 /* KWMCategoryTitleView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = KWMCategoryTitleView.m; sourceTree = "<group>"; };
C0219A931DF53EB200711099 /* KWMExchangeRateResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KWMExchangeRateResult.h; sourceTree = "<group>"; }; C0219A931DF53EB200711099 /* KWMExchangeRateResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KWMExchangeRateResult.h; sourceTree = "<group>"; };
C0219A941DF53EB200711099 /* KWMExchangeRateResult.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = KWMExchangeRateResult.m; sourceTree = "<group>"; }; C0219A941DF53EB200711099 /* KWMExchangeRateResult.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = KWMExchangeRateResult.m; sourceTree = "<group>"; };
C0243BAF1EFBD5A10013CFA7 /* Category.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = Category.storyboard; sourceTree = "<group>"; }; C0243BAF1EFBD5A10013CFA7 /* Category.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = Category.storyboard; sourceTree = "<group>"; };
...@@ -1201,6 +1206,9 @@ ...@@ -1201,6 +1206,9 @@
C0243BB41EFBD5A10013CFA7 /* KWMRightProductCell.h */, C0243BB41EFBD5A10013CFA7 /* KWMRightProductCell.h */,
C0243BB51EFBD5A10013CFA7 /* KWMRightProductCell.m */, C0243BB51EFBD5A10013CFA7 /* KWMRightProductCell.m */,
C0243BB61EFBD5A10013CFA7 /* KWMRightProductCell.xib */, C0243BB61EFBD5A10013CFA7 /* KWMRightProductCell.xib */,
C00D40951F187CAB00DEA685 /* KWMCategoryTitleView.h */,
C00D40961F187CAB00DEA685 /* KWMCategoryTitleView.m */,
C00D40931F187C9500DEA685 /* KWMCategoryTitleView.xib */,
); );
path = Cell; path = Cell;
sourceTree = "<group>"; sourceTree = "<group>";
...@@ -2382,6 +2390,7 @@ ...@@ -2382,6 +2390,7 @@
C0F5869D1E25D3B6001248E2 /* KWMProductDetailView.xib in Resources */, C0F5869D1E25D3B6001248E2 /* KWMProductDetailView.xib in Resources */,
C034E69D1D6AEB12006EE129 /* LaunchScreen.storyboard in Resources */, C034E69D1D6AEB12006EE129 /* LaunchScreen.storyboard in Resources */,
C0A6B3C11F01FC5300D85673 /* KWMProductColorCell.xib in Resources */, C0A6B3C11F01FC5300D85673 /* KWMProductColorCell.xib in Resources */,
C00D40941F187C9500DEA685 /* KWMCategoryTitleView.xib in Resources */,
C048344C1F13393D00A5BFB4 /* KWMHotSalesHeader.xib in Resources */, C048344C1F13393D00A5BFB4 /* KWMHotSalesHeader.xib in Resources */,
80E844291D7FB1130042AED2 /* KWMRuleView.xib in Resources */, 80E844291D7FB1130042AED2 /* KWMRuleView.xib in Resources */,
C034E6F61D6AF197006EE129 /* KWMPickView.xib in Resources */, C034E6F61D6AF197006EE129 /* KWMPickView.xib in Resources */,
...@@ -2552,6 +2561,7 @@ ...@@ -2552,6 +2561,7 @@
C0028EC51F0DD19C00744C14 /* KWMAdditionalResult.m in Sources */, C0028EC51F0DD19C00744C14 /* KWMAdditionalResult.m in Sources */,
C03943C01DD1FCE900141475 /* KWMProductType.m in Sources */, C03943C01DD1FCE900141475 /* KWMProductType.m in Sources */,
C0CC140C1D7829FC007B5986 /* KWMSelectSizeVC.m in Sources */, C0CC140C1D7829FC007B5986 /* KWMSelectSizeVC.m in Sources */,
C00D40971F187CAB00DEA685 /* KWMCategoryTitleView.m in Sources */,
C034E7B31D6AFC3B006EE129 /* KWMMainVC.m in Sources */, C034E7B31D6AFC3B006EE129 /* KWMMainVC.m in Sources */,
C08FDA2A1D9B583400EBDB0D /* KWMGiftCardVC.m in Sources */, C08FDA2A1D9B583400EBDB0D /* KWMGiftCardVC.m in Sources */,
804771801D6D326D0086B4DC /* KWMLoginVC.m in Sources */, 804771801D6D326D0086B4DC /* KWMLoginVC.m in Sources */,
......
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_Acc_nor@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_Acc_nor@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_Acc_pre@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_Acc_pre@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_coat_nor@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_coat_nor@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_coat_pre@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_coat_pre@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_jumpsuits_nor@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_jumpsuits_nor@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_jumpsuits_pre@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_jumpsuits_pre@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_kilt_nor@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_kilt_nor@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_kilt_pre@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_kilt_pre@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_leggings_nor@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_leggings_nor@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_leggings_pre@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_leggings_pre@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_pantyhose_nor@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_pantyhose_nor@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_pantyhose_pre@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_pantyhose_pre@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_raincoat_nor@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_raincoat_nor@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_raincoat_pre@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_raincoat_pre@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_shoe_nor@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_shoe_nor@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_shoe_pre@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_shoe_pre@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_skirt_nor@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_skirt_nor@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_skirt_pre@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_skirt_pre@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_suit_nor@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_suit_nor@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_suit_pre@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_suit_pre@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_swimsuit_nor@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_swimsuit_nor@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_swimsuit_pre@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_swimsuit_pre@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_tops_nor@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_tops_nor@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_tops_pre@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_tops_pre@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_toy_nor@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_toy_nor@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_toy_pre@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_toy_pre@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_trousers_nor@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_trousers_nor@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_trousers_pre@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_trousers_pre@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_underwear_nor@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_underwear_nor@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "ic_type_underwear_pre@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "ic_type_underwear_pre@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
...@@ -15,6 +15,7 @@ ...@@ -15,6 +15,7 @@
@property (nonatomic) NSString* title; @property (nonatomic) NSString* title;
@property (nonatomic) NSNumber* collection_id; @property (nonatomic) NSNumber* collection_id;
@property (nonatomic) NSString* image; @property (nonatomic) NSString* image;
@property (nonatomic) NSString* focusImage;
@property (nonatomic) NSInteger page; @property (nonatomic) NSInteger page;
@property (nonatomic) NSMutableArray *products; @property (nonatomic) NSMutableArray *products;
@property (nonatomic) BUYCollectionSort sort; @property (nonatomic) BUYCollectionSort sort;
......
//
// KWMCategoryTitleView.h
// iCemarose
//
// Created by HouWeiBin on 2017/7/14.
// Copyright © 2017年 kollway. All rights reserved.
//
#import <UIKit/UIKit.h>
@protocol KWMCategoryTitleDelegate <NSObject>
- (void)kwm_onClickSearch;
- (void)kwm_onClickShopCart;
@end
@interface KWMCategoryTitleView : UIView
@property(nonatomic,weak) id<KWMCategoryTitleDelegate> delegate;
@property(nonatomic) NSNumber *count;
@end
//
// KWMCategoryTitleView.m
// iCemarose
//
// Created by HouWeiBin on 2017/7/14.
// Copyright © 2017年 kollway. All rights reserved.
//
#import "KWMCategoryTitleView.h"
@interface KWMCategoryTitleView()
@property(nonatomic,weak) IBOutlet UIView *vView;
@property(nonatomic,weak) IBOutlet UISearchBar *searchBar;
@property(nonatomic,weak) IBOutlet UILabel *lbCount;
@end
@implementation KWMCategoryTitleView
- (id)init{
if (self=[super init]){
[self addView];
}
return self;
}
- (id)initWithCoder:(NSCoder *)aDecoder {
self = [super initWithCoder:aDecoder];
if (self) {
[self addView];
}
return self;
}
-(instancetype)initWithFrame:(CGRect)frame{
if (self =[super initWithFrame:frame]) {
[self addView];
}
return self;
}
-(void)awakeFromNib{
[super awakeFromNib];
[self addView];
}
-(void) addView{
[[NSBundle mainBundle] loadNibNamed:NSStringFromClass([self class])
owner:self
options:nil];
self.vView.frame = CGRectMake(0, 0, self.frame.size.width, self.frame.size.height);
[self addSubview:self.vView];
[self initView];
}
-(void)initView{
}
-(void)setCount:(NSNumber *)count{
_count = count;
self.lbCount.text = count.stringValue;
}
-(IBAction)onClickSearchBar:(id)sender{
if(self.delegate){
[self.delegate kwm_onClickSearch];
}
}
-(IBAction)onClickShopCart:(id)sender{
if(self.delegate){
[self.delegate kwm_onClickShopCart];
}
}
@end
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="12121" systemVersion="16F73" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
<device id="retina4_7" orientation="portrait">
<adaptation id="fullscreen"/>
</device>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="12089"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="KWMCategoryTitleView">
<connections>
<outlet property="lbCount" destination="y0m-sW-G7x" id="svw-DK-ZPg"/>
<outlet property="searchBar" destination="mzZ-Oc-Ztf" id="Kdx-g8-ibf"/>
<outlet property="vView" destination="iN0-l3-epB" id="ndu-9n-FK3"/>
</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="375" height="64"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="hKF-vD-6Tp">
<rect key="frame" x="0.0" y="0.0" width="375" height="20"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<constraints>
<constraint firstAttribute="height" constant="20" id="fZ2-lU-6fn"/>
</constraints>
</view>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="fl4-ro-VaX" userLabel="vContent">
<rect key="frame" x="0.0" y="20" width="375" height="44"/>
<subviews>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="7Cc-is-gm9" userLabel="btn_shop_cart">
<rect key="frame" x="321" y="0.0" width="44" height="44"/>
<constraints>
<constraint firstAttribute="width" constant="44" id="AJf-LC-RBn"/>
<constraint firstAttribute="height" constant="44" id="L6M-UC-Sgm"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="12"/>
<state key="normal" image="btn_ nav_shop cart"/>
<connections>
<action selector="onClickShopCart:" destination="-1" eventType="touchUpInside" id="yWa-X1-P3K"/>
</connections>
</button>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="cX3-qt-ofW" userLabel="vCount">
<rect key="frame" x="340" y="17" width="14" height="14"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="y0m-sW-G7x">
<rect key="frame" x="7" y="7" width="0.0" height="0.0"/>
<accessibility key="accessibilityConfiguration">
<accessibilityTraits key="traits" staticText="YES" notEnabled="YES"/>
</accessibility>
<fontDescription key="fontDescription" type="system" pointSize="12"/>
<color key="textColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
</subviews>
<color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
<accessibility key="accessibilityConfiguration">
<accessibilityTraits key="traits" notEnabled="YES"/>
</accessibility>
<constraints>
<constraint firstAttribute="height" constant="14" id="2uu-6U-qdc"/>
<constraint firstAttribute="width" constant="14" id="gK4-eL-g4z"/>
<constraint firstItem="y0m-sW-G7x" firstAttribute="centerX" secondItem="cX3-qt-ofW" secondAttribute="centerX" id="gqE-UJ-NLd"/>
<constraint firstItem="y0m-sW-G7x" firstAttribute="centerY" secondItem="cX3-qt-ofW" secondAttribute="centerY" id="wzb-Ju-Mir"/>
</constraints>
</view>
<searchBar contentMode="redraw" searchBarStyle="minimal" placeholder="搜索" translatesAutoresizingMaskIntoConstraints="NO" id="mzZ-Oc-Ztf">
<rect key="frame" x="0.0" y="0.0" width="321" height="44"/>
<textInputTraits key="textInputTraits"/>
</searchBar>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Iiv-qH-KSw">
<rect key="frame" x="0.0" y="0.0" width="321" height="44"/>
<connections>
<action selector="onClickSearchBar:" destination="-1" eventType="touchUpInside" id="WTJ-bE-BuQ"/>
</connections>
</button>
</subviews>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="bottom" secondItem="mzZ-Oc-Ztf" secondAttribute="bottom" id="CWv-py-5v4"/>
<constraint firstItem="7Cc-is-gm9" firstAttribute="centerY" secondItem="fl4-ro-VaX" secondAttribute="centerY" id="HRV-Pg-tR7"/>
<constraint firstItem="mzZ-Oc-Ztf" firstAttribute="leading" secondItem="fl4-ro-VaX" secondAttribute="leading" id="N7h-jj-ByO"/>
<constraint firstItem="7Cc-is-gm9" firstAttribute="leading" secondItem="mzZ-Oc-Ztf" secondAttribute="trailing" id="XUo-Xu-TIQ"/>
<constraint firstItem="Iiv-qH-KSw" firstAttribute="top" secondItem="fl4-ro-VaX" secondAttribute="top" id="YRc-Wl-O6W"/>
<constraint firstAttribute="trailing" secondItem="7Cc-is-gm9" secondAttribute="trailing" constant="10" id="ZoT-Bp-EIt"/>
<constraint firstItem="mzZ-Oc-Ztf" firstAttribute="top" secondItem="fl4-ro-VaX" secondAttribute="top" id="bEP-gT-X0I"/>
<constraint firstItem="Iiv-qH-KSw" firstAttribute="leading" secondItem="fl4-ro-VaX" secondAttribute="leading" id="cBr-bG-P6n"/>
<constraint firstAttribute="bottom" secondItem="Iiv-qH-KSw" secondAttribute="bottom" id="hfA-3K-TyT"/>
<constraint firstItem="7Cc-is-gm9" firstAttribute="leading" secondItem="Iiv-qH-KSw" secondAttribute="trailing" id="kLf-i6-xsT"/>
<constraint firstItem="cX3-qt-ofW" firstAttribute="trailing" secondItem="7Cc-is-gm9" secondAttribute="trailing" constant="-11" id="ml8-u3-zgZ"/>
<constraint firstItem="cX3-qt-ofW" firstAttribute="bottom" secondItem="7Cc-is-gm9" secondAttribute="bottom" constant="-13" id="xom-ON-VI4"/>
</constraints>
</view>
</subviews>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="bottom" secondItem="fl4-ro-VaX" secondAttribute="bottom" id="GSh-cL-fgg"/>
<constraint firstItem="hKF-vD-6Tp" firstAttribute="top" secondItem="iN0-l3-epB" secondAttribute="top" id="N7h-nQ-HhT"/>
<constraint firstAttribute="trailing" secondItem="fl4-ro-VaX" secondAttribute="trailing" id="cdF-k1-fAh"/>
<constraint firstItem="fl4-ro-VaX" firstAttribute="leading" secondItem="iN0-l3-epB" secondAttribute="leading" id="dpf-n6-oZa"/>
<constraint firstItem="hKF-vD-6Tp" firstAttribute="leading" secondItem="iN0-l3-epB" secondAttribute="leading" id="idR-Oz-uaR"/>
<constraint firstItem="fl4-ro-VaX" firstAttribute="top" secondItem="hKF-vD-6Tp" secondAttribute="bottom" id="piK-Od-hX4"/>
<constraint firstAttribute="trailing" secondItem="hKF-vD-6Tp" secondAttribute="trailing" id="qxW-H4-P9d"/>
</constraints>
<freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
<point key="canvasLocation" x="33.5" y="96"/>
</view>
</objects>
<resources>
<image name="btn_ nav_shop cart" width="21" height="22"/>
</resources>
</document>
...@@ -15,6 +15,8 @@ ...@@ -15,6 +15,8 @@
@property (nonatomic,weak) IBOutlet UILabel *lbTitle; @property (nonatomic,weak) IBOutlet UILabel *lbTitle;
@property (nonatomic) KWMCategoryModel *category;
@end @end
@implementation KWMLeftCategoryCell @implementation KWMLeftCategoryCell
...@@ -26,6 +28,7 @@ ...@@ -26,6 +28,7 @@
} }
- (void)fillData:(KWMCategoryModel *)model { - (void)fillData:(KWMCategoryModel *)model {
_category = model;
_lbTitle.text = model.title; _lbTitle.text = model.title;
_ivCategory.image = [UIImage imageNamed:model.image]; _ivCategory.image = [UIImage imageNamed:model.image];
} }
...@@ -33,8 +36,10 @@ ...@@ -33,8 +36,10 @@
- (void)setSelected:(BOOL)selected animated:(BOOL)animated { - (void)setSelected:(BOOL)selected animated:(BOOL)animated {
[super setSelected:selected animated:animated]; [super setSelected:selected animated:animated];
UIColor *textColor = selected?[UIColor sam_colorWithHex:@"#F1929A"]:[UIColor sam_colorWithHex:@"#545454"]; UIColor *textColor = selected?[UIColor sam_colorWithHex:@"#F1929A"]:[UIColor sam_colorWithHex:@"#545454"];
UIImage *image = selected?[UIImage imageNamed:@"test_category_s"]:[UIImage imageNamed:@"test_category"]; if(self.category){
self.ivCategory.image = image; UIImage *image = selected?[UIImage imageNamed:self.category.focusImage]:[UIImage imageNamed:self.category.image];
self.ivCategory.image = image;
}
self.lbTitle.textColor = textColor; self.lbTitle.textColor = textColor;
} }
......
...@@ -51,6 +51,8 @@ ...@@ -51,6 +51,8 @@
}]; }];
} }
-(IBAction)onClickBlank:(id)sender{ -(IBAction)onClickBlank:(id)sender{
if(self.delegate){ if(self.delegate){
[self.delegate kwm_onCancelBrandFilter]; [self.delegate kwm_onCancelBrandFilter];
......
...@@ -11,7 +11,9 @@ ...@@ -11,7 +11,9 @@
#import "KWMCategoryFilterTab.h" #import "KWMCategoryFilterTab.h"
#import "KWMProductFilterVC.h" #import "KWMProductFilterVC.h"
#import "KWMBrandFilterVC.h" #import "KWMBrandFilterVC.h"
#import "KWMCategoryTitleView.h"
@interface KWMCategoryVC : KWMBaseVC<UICollectionViewDataSource,UICollectionViewDelegate,UITableViewDataSource,UITableViewDelegate,KWMCollectionRefreshDelegate,CategoryFilterTabDelegate,KWMProductFilterDelegate,KWMBrandFilterDelegate>
@interface KWMCategoryVC : KWMBaseVC<UICollectionViewDataSource,UICollectionViewDelegate,UITableViewDataSource,UITableViewDelegate,KWMCollectionRefreshDelegate,CategoryFilterTabDelegate,KWMProductFilterDelegate,KWMBrandFilterDelegate,KWMCategoryTitleDelegate>
@end @end
...@@ -8,14 +8,16 @@ ...@@ -8,14 +8,16 @@
#import "KWMCategoryVC.h" #import "KWMCategoryVC.h"
#import "KWMProductDetailVC.h" #import "KWMProductDetailVC.h"
#import "KWMShopCartVC.h"
#import "KWMNewProductVC.h" #import "KWMNewProductVC.h"
#import "KWMSearchFeedbackVC.h"
#import "KWMLeftCategoryCell.h" #import "KWMLeftCategoryCell.h"
#import "KWMRightProductCell.h" #import "KWMRightProductCell.h"
#import "KWMBrandsTypeModel.h" #import "KWMBrandsTypeModel.h"
#import "KWMSearchBar.h"
#import "KWMStringUtil.h" #import "KWMStringUtil.h"
#import "KWMFilterUtil.h" #import "KWMFilterUtil.h"
#import "MJRefresh.h" #import "MJRefresh.h"
#import "KWMShoppingCart.h"
...@@ -31,7 +33,7 @@ ...@@ -31,7 +33,7 @@
@property(nonatomic) KWMCollectionRefreshUtil *refreshUtil; @property(nonatomic) KWMCollectionRefreshUtil *refreshUtil;
@property (nonatomic) KWMSearchBar *searchBar; @property (nonatomic) KWMCategoryTitleView *titleView;
@property (nonatomic) NSArray *allBrands; @property (nonatomic) NSArray *allBrands;
...@@ -63,6 +65,20 @@ ...@@ -63,6 +65,20 @@
// [self.cvRightProduct.mj_header beginRefreshing]; // [self.cvRightProduct.mj_header beginRefreshing];
} }
- (void)viewWillAppear:(BOOL)animated{
[super viewWillAppear:animated];
[self.navigationController setNavigationBarHidden:YES];
if(self.titleView){
NSNumber *count = [[KWMShoppingCart sharedInstance] count];
self.titleView.count = count;
}
}
- (void)viewWillDisappear:(BOOL)animated{
[super viewWillDisappear:animated];
[self.navigationController setNavigationBarHidden:NO];
}
-(KWMCollectionRefreshUtil *)refreshUtil{ -(KWMCollectionRefreshUtil *)refreshUtil{
if(!_refreshUtil){ if(!_refreshUtil){
_refreshUtil = [KWMCollectionRefreshUtil new]; _refreshUtil = [KWMCollectionRefreshUtil new];
...@@ -75,32 +91,37 @@ ...@@ -75,32 +91,37 @@
-(void) initData { -(void) initData {
self.categories = [@[ self.categories = [@[
@{@"title":@"上装",@"collection_id":@"192437702",@"image":@""}, @{@"title":@"上装",@"collection_id":@"192437702",@"image":@"ic_type_tops"},
@{@"title":@"连体衣",@"collection_id":@"192438342",@"image":@""}, @{@"title":@"连体衣",@"collection_id":@"192438342",@"image":@"ic_type_jumpsuits"},
@{@"title":@"外套",@"collection_id":@"192438790",@"image":@""}, @{@"title":@"外套",@"collection_id":@"192438790",@"image":@"ic_type_coat"},
@{@"title":@"裙子",@"collection_id":@"191377286",@"image":@""}, @{@"title":@"裙子",@"collection_id":@"191377286",@"image":@"ic_type_skirt"},
@{@"title":@"裤子",@"collection_id":@"333026630",@"image":@""}, @{@"title":@"裤子",@"collection_id":@"333026630",@"image":@"ic_type_trousers"},
@{@"title":@"短裙",@"collection_id":@"192434950",@"image":@""}, @{@"title":@"短裙",@"collection_id":@"192434950",@"image":@"ic_type_kilt"},
@{@"title":@"套装",@"collection_id":@"192438150",@"image":@""}, @{@"title":@"套装",@"collection_id":@"192438150",@"image":@"ic_type_suit"},
@{@"title":@"泳衣",@"collection_id":@"333026438",@"image":@""}, @{@"title":@"泳衣",@"collection_id":@"333026438",@"image":@"ic_type_swimsuit"},
@{@"title":@"连裤袜",@"collection_id":@"192437830",@"image":@""}, @{@"title":@"连裤袜",@"collection_id":@"192437830",@"image":@"ic_type_pantyhose"},
@{@"title":@"打底裤",@"collection_id":@"192435334",@"image":@""}, @{@"title":@"打底裤",@"collection_id":@"192435334",@"image":@"ic_type_leggings"},
@{@"title":@"内衣",@"collection_id":@"333026694",@"image":@""}, @{@"title":@"内衣",@"collection_id":@"333026694",@"image":@"ic_type_underwear"},
@{@"title":@"雨衣",@"collection_id":@"423509068",@"image":@""}, @{@"title":@"雨衣",@"collection_id":@"423509068",@"image":@"ic_type_raincoat"},
@{@"title":@"鞋子",@"collection_id":@"171856134",@"image":@""}, @{@"title":@"鞋子",@"collection_id":@"171856134",@"image":@"ic_type_shoe"},
@{@"title":@"玩具",@"collection_id":@"332990918",@"image":@""}, @{@"title":@"玩具",@"collection_id":@"332990918",@"image":@"ic_type_toy"},
@{@"title":@"饰品",@"collection_id":@"191376966",@"image":@""}, @{@"title":@"饰品",@"collection_id":@"191376966",@"image":@"ic_type_Acc"},
] rx_mapWithBlock:^id(id each) { ] rx_mapWithBlock:^id(id each) {
NSString *image = each[@"image"];
KWMCategoryModel *m = [KWMCategoryModel new]; KWMCategoryModel *m = [KWMCategoryModel new];
m.title = each[@"title"]; m.title = each[@"title"];
m.collection_id = @([each[@"collection_id"] integerValue]); m.collection_id = @([each[@"collection_id"] integerValue]);
m.image = each[@"image"]; m.image = [NSString stringWithFormat:@"%@_nor",image];
m.focusImage = [NSString stringWithFormat:@"%@_pre",image];
m.page = 1; m.page = 1;
m.products = [NSMutableArray new]; m.products = [NSMutableArray new];
m.sort = BUYCollectionSortCollectionDefault; m.sort = BUYCollectionSortCollectionDefault;
return m; return m;
}]; }];
self.selectedCategory = self.categories.firstObject; self.selectedCategory = self.categories.firstObject;
NSIndexPath * path = [NSIndexPath indexPathForItem:1 inSection:0];
[self.tbvLeftCategory selectRowAtIndexPath:path animated:YES scrollPosition:UITableViewScrollPositionTop];
} }
-(void)initView{ -(void)initView{
...@@ -124,10 +145,23 @@ ...@@ -124,10 +145,23 @@
- (void)initTitleView{ - (void)initTitleView{
[self.navigationController setNavigationBarHidden:YES]; [self.navigationController setNavigationBarHidden:YES];
//添加頭部header NSNumber *count = [[KWMShoppingCart sharedInstance] count];
self.searchBar = [[KWMSearchBar alloc] initWithFrame:CGRectMake(0, 0, self.view.frame.size.width, 64)];
// self.searchBar.delegate = self; self.titleView = [[KWMCategoryTitleView alloc] initWithFrame:CGRectMake(0, 0, self.view.frame.size.width, 64)];
[self.view addSubview:_searchBar]; self.titleView.delegate = self;
self.titleView.count = count;
[self.view addSubview:self.titleView];
}
#pragma mark -- KWMCategoryTitleDelegate
-(void)kwm_onClickShopCart{
KWMShopCartVC * shopCartVC = (KWMShopCartVC*)[KWMBaseVC findControllerBy:[KWMShopCartVC kwmTag] fromStoryboard:@"ShopCart"];
[self.navigationController pushViewController:shopCartVC animated:YES];
}
-(void)kwm_onClickSearch{
KWMSearchFeedbackVC *vc = (KWMSearchFeedbackVC *)[KWMBaseVC findControllerBy:[KWMSearchFeedbackVC kwmTag] fromStoryboard:@"New"];
[self.navigationController pushViewController:vc animated:YES];
} }
#pragma mark - UITableViewDataSource #pragma mark - UITableViewDataSource
......
...@@ -13,6 +13,8 @@ ...@@ -13,6 +13,8 @@
- (void)kwm_onClickProduct:(BUYProduct *)product; - (void)kwm_onClickProduct:(BUYProduct *)product;
- (void)kwm_gotoRecommendPage;
@end @end
@interface KWMRecommendHeader : UIView<UICollectionViewDataSource,UICollectionViewDelegate> @interface KWMRecommendHeader : UIView<UICollectionViewDataSource,UICollectionViewDelegate>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment