Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
A
ALand
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张杰
ALand
Commits
fea1f537
Commit
fea1f537
authored
Mar 29, 2016
by
Sandy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
筛选列表回收逻辑修改
parent
ce7d5509
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
50 additions
and
16 deletions
+50
-16
SortView.h
ALand/CodeClass/Home/View/Commodity/SortView.h
+1
-1
SortView.m
ALand/CodeClass/Home/View/Commodity/SortView.m
+7
-2
CommodityManagementSortView.h
ALand/CodeClass/Home/View/CommodityManagementSortView.h
+1
-0
CommodityManagementSortView.m
ALand/CodeClass/Home/View/CommodityManagementSortView.m
+15
-8
CommodityManagementTopView.m
ALand/CodeClass/Home/View/CommodityManagementTopView.m
+8
-0
CommodityListViewController.m
...me/ViewController/Commodity/CommodityListViewController.m
+6
-0
CommodityManagementViewController.h
...s/Home/ViewController/CommodityManagementViewController.h
+2
-0
CommodityManagementViewController.m
...s/Home/ViewController/CommodityManagementViewController.m
+8
-2
ManagementViewController.h
.../CodeClass/Home/ViewController/ManagementViewController.h
+2
-1
ManagementViewController.m
.../CodeClass/Home/ViewController/ManagementViewController.m
+0
-2
No files found.
ALand/CodeClass/Home/View/Commodity/SortView.h
View file @
fea1f537
...
@@ -16,5 +16,5 @@ typedef void (^selectedRow)(NSInteger);
...
@@ -16,5 +16,5 @@ typedef void (^selectedRow)(NSInteger);
@property
(
nonatomic
,
copy
)
selectedRow
selecedBlock
;
@property
(
nonatomic
,
copy
)
selectedRow
selecedBlock
;
-
(
instancetype
)
customNew
;
-
(
instancetype
)
customNew
;
-
(
void
)
hide
;
@end
@end
ALand/CodeClass/Home/View/Commodity/SortView.m
View file @
fea1f537
...
@@ -111,7 +111,6 @@
...
@@ -111,7 +111,6 @@
-
(
void
)
showTableView
{
-
(
void
)
showTableView
{
[
self
.
coverView
show
];
[
self
.
coverView
show
];
//self.leftSortAction(YES);
//self.leftSortAction(YES);
[
self
viewController
].
navigationItem
.
leftBarButtonItem
.
enabled
=
NO
;
WS
(
weakSelf
)
WS
(
weakSelf
)
self
.
isTableOpen
=
YES
;
self
.
isTableOpen
=
YES
;
...
@@ -123,7 +122,6 @@
...
@@ -123,7 +122,6 @@
-
(
void
)
hideTableView
{
-
(
void
)
hideTableView
{
[
self
.
coverView
hide
];
[
self
.
coverView
hide
];
// self.leftSortAction(NO);
// self.leftSortAction(NO);
[
self
viewController
].
navigationItem
.
leftBarButtonItem
.
enabled
=
YES
;
self
.
isTableOpen
=
NO
;
self
.
isTableOpen
=
NO
;
WS
(
weakSelf
)
WS
(
weakSelf
)
[
UIView
animateWithDuration
:
0
.
3
animations
:
^
{
[
UIView
animateWithDuration
:
0
.
3
animations
:
^
{
...
@@ -224,6 +222,13 @@
...
@@ -224,6 +222,13 @@
return
nil
;
return
nil
;
}
}
-
(
void
)
hide
{
if
(
self
.
isTableOpen
==
YES
)
{
[
self
leftAction
:
nil
];
}
}
/*
/*
// Only override drawRect: if you perform custom drawing.
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
// An empty implementation adversely affects performance during animation.
...
...
ALand/CodeClass/Home/View/CommodityManagementSortView.h
View file @
fea1f537
...
@@ -17,4 +17,5 @@ typedef void (^selectedRow)(NSInteger);
...
@@ -17,4 +17,5 @@ typedef void (^selectedRow)(NSInteger);
-
(
instancetype
)
sortView
;
-
(
instancetype
)
sortView
;
-
(
void
)
hide
;;
@end
@end
ALand/CodeClass/Home/View/CommodityManagementSortView.m
View file @
fea1f537
...
@@ -72,11 +72,7 @@
...
@@ -72,11 +72,7 @@
[
self
.
window
addSubview
:
_coverView
];
[
self
.
window
addSubview
:
_coverView
];
WS
(
weakSelf
)
WS
(
weakSelf
)
_coverView
.
tapAction
=
^
{
_coverView
.
tapAction
=
^
{
if
(
weakSelf
.
arrTitles
==
weakSelf
.
arrLeft
)
{
[
weakSelf
hide
];
[
weakSelf
leftAction
:
nil
];
}
else
{
[
weakSelf
rightBtnAction
];
}
};
};
...
@@ -127,9 +123,9 @@
...
@@ -127,9 +123,9 @@
//设置界面上其它的按钮是否可以点击
//设置界面上其它的按钮是否可以点击
-
(
void
)
setOtherUserInteraction
:
(
BOOL
)
state
{
-
(
void
)
setOtherUserInteraction
:
(
BOOL
)
state
{
[
self
viewController
].
navigationItem
.
leftBarButtonItem
.
enabled
=
state
;
//
[self viewController].navigationItem.leftBarButtonItem.enabled = state;
[
self
viewController
].
navigationItem
.
rightBarButtonItem
.
enabled
=
state
;
//
[self viewController].navigationItem.rightBarButtonItem.enabled = state;
[
self
viewController
].
view
.
userInteractionEnabled
=
state
;
//
[self viewController].view.userInteractionEnabled = state;
}
}
...
@@ -269,6 +265,17 @@
...
@@ -269,6 +265,17 @@
return
nil
;
return
nil
;
}
}
-
(
void
)
hide
{
if
(
self
.
isTableOpen
==
YES
)
{
if
(
_arrTitles
==
_arrLeft
)
{
[
self
leftAction
:
nil
];
}
else
{
[
self
rightBtnAction
];
}
}
}
/*
/*
// Only override drawRect: if you perform custom drawing.
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
// An empty implementation adversely affects performance during animation.
...
...
ALand/CodeClass/Home/View/CommodityManagementTopView.m
View file @
fea1f537
...
@@ -9,6 +9,7 @@
...
@@ -9,6 +9,7 @@
#import "CommodityManagementTopView.h"
#import "CommodityManagementTopView.h"
#import "UIView+Category.h"
#import "UIView+Category.h"
#import "ManagementViewController.h"
#import "ManagementViewController.h"
#import "CommodityManagementViewController.h"
@interface
CommodityManagementTopView
()
@interface
CommodityManagementTopView
()
@property
(
weak
,
nonatomic
)
IBOutlet
UIButton
*
buttonAdd
;
@property
(
weak
,
nonatomic
)
IBOutlet
UIButton
*
buttonAdd
;
@property
(
weak
,
nonatomic
)
IBOutlet
UIButton
*
buttonManagement
;
@property
(
weak
,
nonatomic
)
IBOutlet
UIButton
*
buttonManagement
;
...
@@ -25,13 +26,20 @@
...
@@ -25,13 +26,20 @@
-
(
IBAction
)
managementAct
:
(
id
)
sender
{
-
(
IBAction
)
managementAct
:
(
id
)
sender
{
ManagementViewController
*
manageVC
=
[[
ManagementViewController
alloc
]
init
];
ManagementViewController
*
manageVC
=
[[
ManagementViewController
alloc
]
init
];
[
self
hideSortView
];
[[
self
viewController
]
PushViewController
:
manageVC
animated
:
YES
];
[[
self
viewController
]
PushViewController
:
manageVC
animated
:
YES
];
CLog
(
@"m"
);
CLog
(
@"m"
);
}
}
-
(
IBAction
)
addAct
:
(
id
)
sender
{
-
(
IBAction
)
addAct
:
(
id
)
sender
{
[
self
hideSortView
];
CLog
(
@"a"
);
CLog
(
@"a"
);
}
}
-
(
void
)
hideSortView
{
CommodityManagementViewController
*
commodityVC
=
(
CommodityManagementViewController
*
)[
self
viewController
];
[
commodityVC
.
sorView
hide
];
}
/*
/*
// Only override drawRect: if you perform custom drawing.
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
// An empty implementation adversely affects performance during animation.
...
...
ALand/CodeClass/Home/ViewController/Commodity/CommodityListViewController.m
View file @
fea1f537
...
@@ -47,6 +47,12 @@
...
@@ -47,6 +47,12 @@
}
}
-
(
void
)
viewWillDisappear
:
(
BOOL
)
animated
{
[
super
viewWillDisappear
:
animated
];
[
self
.
sortView
hide
];
}
-
(
void
)
setUpCollectionView
{
-
(
void
)
setUpCollectionView
{
UICollectionViewFlowLayout
*
layOut
=
[[
UICollectionViewFlowLayout
alloc
]
init
];
UICollectionViewFlowLayout
*
layOut
=
[[
UICollectionViewFlowLayout
alloc
]
init
];
layOut
.
minimumLineSpacing
=
10
;
layOut
.
minimumLineSpacing
=
10
;
...
...
ALand/CodeClass/Home/ViewController/CommodityManagementViewController.h
View file @
fea1f537
...
@@ -7,7 +7,9 @@
...
@@ -7,7 +7,9 @@
//
//
#import "IBTUIViewController.h"
#import "IBTUIViewController.h"
#import "CommodityManagementSortView.h"
@interface
CommodityManagementViewController
:
IBTUIViewController
@interface
CommodityManagementViewController
:
IBTUIViewController
@property
(
nonatomic
,
strong
)
CommodityManagementSortView
*
sorView
;
@end
@end
ALand/CodeClass/Home/ViewController/CommodityManagementViewController.m
View file @
fea1f537
...
@@ -8,14 +8,12 @@
...
@@ -8,14 +8,12 @@
#import "CommodityManagementViewController.h"
#import "CommodityManagementViewController.h"
#import "CommodityManagementTopView.h"
#import "CommodityManagementTopView.h"
#import "CommodityManagementSortView.h"
#import "UITableView+Category.h"
#import "UITableView+Category.h"
#import "CommodityTableViewCell.h"
#import "CommodityTableViewCell.h"
#define kCellId @"CommodityTableViewCell.h"
#define kCellId @"CommodityTableViewCell.h"
@interface
CommodityManagementViewController
()
<
UITableViewDelegate
,
UITableViewDataSource
>
@interface
CommodityManagementViewController
()
<
UITableViewDelegate
,
UITableViewDataSource
>
@property
(
nonatomic
,
strong
)
CommodityManagementTopView
*
topView
;
@property
(
nonatomic
,
strong
)
CommodityManagementTopView
*
topView
;
@property
(
nonatomic
,
strong
)
CommodityManagementSortView
*
sorView
;
@property
(
nonatomic
,
strong
)
UITableView
*
tableView
;
@property
(
nonatomic
,
strong
)
UITableView
*
tableView
;
@end
@end
...
@@ -47,12 +45,20 @@
...
@@ -47,12 +45,20 @@
// Do any additional setup after loading the view.
// Do any additional setup after loading the view.
}
}
#pragma mark =========== action ===========
#pragma mark =========== action ===========
-
(
void
)
searchAct
{
-
(
void
)
searchAct
{
[
self
.
sorView
hide
];
CLog
(
@"search"
);
CLog
(
@"search"
);
}
}
-
(
void
)
viewWillDisappear
:
(
BOOL
)
animated
{
[
super
viewWillDisappear
:
animated
];
[
self
.
sorView
hide
];
}
#pragma mark =========== tableview delegate ===========
#pragma mark =========== tableview delegate ===========
...
...
ALand/CodeClass/Home/ViewController/ManagementViewController.h
View file @
fea1f537
...
@@ -7,7 +7,8 @@
...
@@ -7,7 +7,8 @@
//
//
#import "IBTUIViewController.h"
#import "IBTUIViewController.h"
#import "CommodityManagementSortView.h"
@interface
ManagementViewController
:
IBTUIViewController
@interface
ManagementViewController
:
IBTUIViewController
@property
(
nonatomic
,
strong
)
CommodityManagementSortView
*
sorView
;
@end
@end
ALand/CodeClass/Home/ViewController/ManagementViewController.m
View file @
fea1f537
...
@@ -7,14 +7,12 @@
...
@@ -7,14 +7,12 @@
//
//
#import "ManagementViewController.h"
#import "ManagementViewController.h"
#import "CommodityManagementSortView.h"
#import "CommodityTableViewCell.h"
#import "CommodityTableViewCell.h"
#import "UITableView+Category.h"
#import "UITableView+Category.h"
#import "CommodityMutipleSelectBottomView.h"
#import "CommodityMutipleSelectBottomView.h"
#define kCellId @"CommodityTableViewCell.h"
#define kCellId @"CommodityTableViewCell.h"
@interface
ManagementViewController
()
<
UITableViewDelegate
,
UITableViewDataSource
>
@interface
ManagementViewController
()
<
UITableViewDelegate
,
UITableViewDataSource
>
@property
(
nonatomic
,
strong
)
CommodityManagementSortView
*
sorView
;
@property
(
nonatomic
,
strong
)
UITableView
*
tableView
;
@property
(
nonatomic
,
strong
)
UITableView
*
tableView
;
@property
(
nonatomic
,
strong
)
CommodityMutipleSelectBottomView
*
bottomView
;
@property
(
nonatomic
,
strong
)
CommodityMutipleSelectBottomView
*
bottomView
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment