Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
GeliBusinessPlatform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
CI / CD Analytics
Repository Analytics
Value Stream Analytics
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ljy
GeliBusinessPlatform
Commits
952b06f9
Commit
952b06f9
authored
Jul 07, 2020
by
lujunye
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
接入筛选接口
parent
d6b1f678
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
42 additions
and
19 deletions
+42
-19
GeliBusinessPlatform.xcworkspace/xcuserdata/junyelu.xcuserdatad/UserInterfaceState.xcuserstate
...erdata/junyelu.xcuserdatad/UserInterfaceState.xcuserstate
+0
-0
GeliBusinessPlatform/ViewController/应付账款/YingFuZKListViewController.swift
...form/ViewController/应付账款/YingFuZKListViewController.swift
+18
-13
GeliBusinessPlatform/ViewController/应付账款/YingFuZhangKuanXQViewController.swift
...ViewController/应付账款/YingFuZhangKuanXQViewController.swift
+24
-6
No files found.
GeliBusinessPlatform.xcworkspace/xcuserdata/junyelu.xcuserdatad/UserInterfaceState.xcuserstate
View file @
952b06f9
No preview for this file type
GeliBusinessPlatform/ViewController/应付账款/YingFuZKListViewController.swift
View file @
952b06f9
...
...
@@ -14,6 +14,10 @@ class YingFuZKListViewController: BaseViewController,UISearchBarDelegate,SearchB
}
@IBOutlet
weak
var
selectListH
:
NSLayoutConstraint
!
var
exist
=
0
var
amount_order
=
0
@IBAction
func
topBtnClick
(
_
sender
:
UIButton
)
{
switch
sender
.
tag
{
case
0
:
...
...
@@ -121,21 +125,20 @@ class YingFuZKListViewController: BaseViewController,UISearchBarDelegate,SearchB
}
var
leftSelectNum
:
Int
?
var
rightSelectNum
:
Int
?
//MARK: - CELL DELEGATE
func
tableView
(
_
tableView
:
UITableView
,
didSelectRowAt
indexPath
:
IndexPath
)
{
if
tableView
==
selectList
{
if
leftBtnTitle
.
textColor
==
UIColor
(
named
:
"蓝色字体颜色"
){
leftSelectNum
=
indexPath
.
row
leftBtnTitle
.
text
=
leftArr
2
[
leftSelectNum
!
]
exist
=
indexPath
.
row
leftBtnTitle
.
text
=
leftArr
1
[
exist
]
if
(
barTitle
?
.
contains
(
"应收"
))
!
{
leftBtnTitle
.
text
=
leftArr
1
[
leftSelectNum
!
]
leftBtnTitle
.
text
=
leftArr
2
[
exist
]
}
}
else
{
rightSelectNum
=
indexPath
.
row
rightBtnTitle
.
text
=
rightArr
[
rightSelectNum
!
]
amount_order
=
indexPath
.
row
rightBtnTitle
.
text
=
rightArr
[
amount_order
]
}
leftImg
.
image
=
UIImage
(
named
:
"xiala"
)
rightImg
.
image
=
UIImage
(
named
:
"xiala"
)
...
...
@@ -143,7 +146,7 @@ class YingFuZKListViewController: BaseViewController,UISearchBarDelegate,SearchB
leftBtnTitle
.
textColor
=
UIColor
(
named
:
"标题字颜色"
)
selectList
.
isHidden
=
true
closeBtn
.
isHidden
=
true
tableView
.
reloadData
()
listView
.
mj_header
?
.
beginRefreshing
()
return
}
let
vc
=
YingFuZhangKuanXQViewController
()
...
...
@@ -190,18 +193,18 @@ class YingFuZKListViewController: BaseViewController,UISearchBarDelegate,SearchB
if
leftBtnTitle
.
textColor
==
UIColor
(
named
:
"蓝色字体颜色"
){
if
(
barTitle
?
.
contains
(
"应收"
))
!
{
cell
?
.
textLabel
!.
text
=
leftArr2
[
indexPath
.
row
]
if
leftSelectNum
==
indexPath
.
row
{
if
exist
==
indexPath
.
row
{
cell
?
.
textLabel
?
.
textColor
=
UIColor
(
named
:
"蓝色字体颜色"
)
}
}
else
{
cell
?
.
textLabel
!.
text
=
leftArr1
[
indexPath
.
row
]
if
leftSelectNum
==
indexPath
.
row
{
if
exist
==
indexPath
.
row
{
cell
?
.
textLabel
?
.
textColor
=
UIColor
(
named
:
"蓝色字体颜色"
)
}
}
}
else
{
cell
?
.
textLabel
!.
text
=
rightArr
[
indexPath
.
row
]
if
rightSelectNum
==
indexPath
.
row
{
if
amount_order
==
indexPath
.
row
{
cell
?
.
textLabel
?
.
textColor
=
UIColor
(
named
:
"蓝色字体颜色"
)
}
}
...
...
@@ -274,7 +277,7 @@ class YingFuZKListViewController: BaseViewController,UISearchBarDelegate,SearchB
@objc
func
loadData
(){
print
(
"加载数据"
)
page
=
1
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
]
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
,
"exist"
:
exist
as
Any
,
"amount_order"
:
amount_order
+
1
as
Any
]
if
(
barTitle
?
.
contains
(
"应付"
))
!
{
accountsPayableList
(
dic
,
success
:
{
(
data
)
in
let
model
=
(
data
as!
accountsPayableListModel
)
...
...
@@ -288,7 +291,9 @@ class YingFuZKListViewController: BaseViewController,UISearchBarDelegate,SearchB
self
.
listView
.
mj_footer
=
self
.
footerMJ
}
if
model
.
data
?
.
total_payable_money
!=
nil
{
self
.
totalPriceLbl
.
text
=
"¥
\(
model
.
data
!.
total_payable_money
!
)
"
}
self
.
listView
.
reloadData
()
self
.
listView
.
mj_header
?
.
endRefreshing
()
self
.
page
=
2
...
...
@@ -330,7 +335,7 @@ class YingFuZKListViewController: BaseViewController,UISearchBarDelegate,SearchB
@objc
func
loadMoreData
(){
print
(
"加载更多数据"
)
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
]
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
,
"exist"
:
exist
as
Any
,
"amount_order"
:
amount_order
+
1
as
Any
]
if
(
barTitle
?
.
contains
(
"应付"
))
!
{
accountsPayableList
(
dic
,
success
:
{
(
data
)
in
let
dataM
=
data
as!
accountsPayableListModel
...
...
GeliBusinessPlatform/ViewController/应付账款/YingFuZhangKuanXQViewController.swift
View file @
952b06f9
...
...
@@ -16,6 +16,11 @@ protocol YingFuZhangKuanXQViewControllerDelegate {
class
YingFuZhangKuanXQViewController
:
BaseViewController
,
UISearchBarDelegate
,
SearchBarViewDelegate
,
UITableViewDelegate
,
UITableViewDataSource
,
YingFuZhangKuanXQCellDelegate
,
GLAlertSelectViewDelegate
,
GeliAlertViewDelegate
,
TimeSelectViewDelgate
{
var
delegate
:
YingFuZhangKuanXQViewControllerDelegate
?
var
time_type
=
0
var
start_time
=
0
var
end_time
=
0
@IBOutlet
weak
var
selectView
:
UIView
!
@IBOutlet
weak
var
selectimeBV
:
UIView
!
...
...
@@ -25,11 +30,13 @@ class YingFuZhangKuanXQViewController:BaseViewController,UISearchBarDelegate,Sea
rightBtn
.
backgroundColor
=
UIColor
(
named
:
"分类Cell背景色"
)
leftBtn
.
isSelected
=
true
rightBtn
.
isSelected
=
false
time_type
=
1
}
else
{
leftBtn
.
backgroundColor
=
UIColor
(
named
:
"分类Cell背景色"
)
rightBtn
.
backgroundColor
=
UIColor
(
named
:
"按钮背景颜色"
)
leftBtn
.
isSelected
=
false
rightBtn
.
isSelected
=
true
time_type
=
2
}
//10086
timeView
.
removeFromSuperview
()
...
...
@@ -49,11 +56,13 @@ class YingFuZhangKuanXQViewController:BaseViewController,UISearchBarDelegate,Sea
@IBAction
func
closeAction
(
_
sender
:
UIButton
)
{
selectView
.
isHidden
=
true
closeBtn
.
isHidden
=
true
}
@IBAction
func
showSelectAction
(
_
sender
:
UIButton
)
{
selectView
.
isHidden
=
!
selectView
.
isHidden
closeBtn
.
isHidden
=
selectView
.
isHidden
timeView
.
removeFromSuperview
()
selectimeBV
.
addSubview
(
timeView
)
timeView
.
snp
.
makeConstraints
{
(
make
)
in
...
...
@@ -430,11 +439,17 @@ class YingFuZhangKuanXQViewController:BaseViewController,UISearchBarDelegate,Sea
@objc
func
loadData
(){
print
(
"加载数据"
)
page
=
1
if
(
navTitle
.
contains
(
"应付"
)){
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
,
"ven_id"
:
ven_id
as
Any
]
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
,
"ven_id"
:
ven_id
as
Any
,
"time_type"
:
time_type
as
Any
,
"start_time"
:
start_time
as
Any
,
"end_time"
:
end_time
as
Any
]
accountsPayableDetail
(
dic
,
success
:
{
(
data
)
in
let
model
=
(
data
as!
accountsPayableDetailModel
)
self
.
dataArr
.
removeAll
()
if
model
.
code
==
2
{
self
.
listView
.
reloadData
()
self
.
listView
.
mj_header
?
.
endRefreshing
()
return
}
model
.
data
?
.
list
?
.
forEach
({
(
item
)
in
self
.
dataArr
.
append
(
item
)
})
...
...
@@ -469,17 +484,18 @@ class YingFuZhangKuanXQViewController:BaseViewController,UISearchBarDelegate,Sea
self
.
listView
.
mj_header
?
.
endRefreshing
()
}
}
else
{
//应收
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
,
"cus_id"
:
ven_id
as
Any
]
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
,
"cus_id"
:
ven_id
as
Any
,
"time_type"
:
time_type
as
Any
,
"start_time"
:
start_time
as
Any
,
"end_time"
:
end_time
as
Any
]
accountReceivableDetail
(
dic
,
success
:
{
(
data
)
in
self
.
first
=
"0"
self
.
second
=
"0"
self
.
third
=
"0"
let
model
=
data
as!
accountReceivableDetailModel
self
.
datas
.
removeAll
()
if
model
.
code
==
2
{
self
.
listView
.
reloadData
()
self
.
listView
.
mj_header
?
.
endRefreshing
()
return
}
self
.
datas
.
removeAll
()
model
.
data
?
.
list
?
.
forEach
({
(
item
)
in
self
.
datas
.
append
(
item
)
})
...
...
@@ -523,7 +539,7 @@ class YingFuZhangKuanXQViewController:BaseViewController,UISearchBarDelegate,Sea
@objc
func
loadMoreData
(){
print
(
"加载更多数据"
)
if
(
navTitle
.
contains
(
"应付"
)){
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
,
"ven_id"
:
ven_id
as
Any
]
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
,
"ven_id"
:
ven_id
as
Any
,
"time_type"
:
time_type
as
Any
,
"start_time"
:
start_time
as
Any
,
"end_time"
:
end_time
as
Any
]
accountsPayableDetail
(
dic
,
success
:
{
(
data
)
in
let
dataM
=
data
as!
accountsPayableDetailModel
if
dataM
.
data
?
.
list
==
nil
{
...
...
@@ -542,7 +558,7 @@ class YingFuZhangKuanXQViewController:BaseViewController,UISearchBarDelegate,Sea
}
}
else
{
//应收
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
,
"cus_id"
:
ven_id
as
Any
]
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
,
"cus_id"
:
ven_id
as
Any
,
"time_type"
:
time_type
as
Any
,
"start_time"
:
start_time
as
Any
,
"end_time"
:
end_time
as
Any
]
accountReceivableDetail
(
dic
,
success
:
{
(
data
)
in
let
model
=
data
as!
accountReceivableDetailModel
if
model
.
data
?
.
list
==
nil
{
...
...
@@ -652,6 +668,8 @@ class YingFuZhangKuanXQViewController:BaseViewController,UISearchBarDelegate,Sea
TimeLbl
!.
text
=
dayByDouble
(
sender
:
timeInterval
)
+
"-"
+
dayByDouble
(
sender
:
timeIntervalEnd
)
EndDate
=
endginDate
BeginDate
=
beginDate
start_time
=
Int
(
timeInterval
)
end_time
=
Int
(
timeIntervalEnd
)
}
@objc
func
clearBtnAction
(
sender
:
UIButton
){
print
(
"清除日期·····"
)
...
...
@@ -669,8 +687,8 @@ class YingFuZhangKuanXQViewController:BaseViewController,UISearchBarDelegate,Sea
return
}
print
(
"最后的时间"
,
BeginDate
,
EndDate
)
listView
.
mj_header
?
.
beginRefreshing
()
selectView
.
isHidden
=
true
closeBtn
.
isHidden
=
true
}
}
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