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
8da510de
Commit
8da510de
authored
5 years ago
by
lujunye
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
应付账款
parent
8eb63132
Changes
14
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
582 additions
and
78 deletions
+582
-78
GeliBusinessPlatform.xcodeproj/project.pbxproj
GeliBusinessPlatform.xcodeproj/project.pbxproj
+16
-0
GeliBusinessPlatform.xcworkspace/xcuserdata/junyelu.xcuserdatad/UserInterfaceState.xcuserstate
...erdata/junyelu.xcuserdatad/UserInterfaceState.xcuserstate
+0
-0
GeliBusinessPlatform/Interface/Interface_Z.plist
GeliBusinessPlatform/Interface/Interface_Z.plist
+4
-0
GeliBusinessPlatform/Model/accountsPayableInterface.swift
GeliBusinessPlatform/Model/accountsPayableInterface.swift
+44
-0
GeliBusinessPlatform/Model/yfzkModel/accountsPayableListModel.swift
...ssPlatform/Model/yfzkModel/accountsPayableListModel.swift
+115
-0
GeliBusinessPlatform/View/AlertView/GLAlertSelectView.swift
GeliBusinessPlatform/View/AlertView/GLAlertSelectView.swift
+21
-4
GeliBusinessPlatform/ViewController/应付账款/YingFuZKListViewController.swift
...form/ViewController/应付账款/YingFuZKListViewController.swift
+141
-17
GeliBusinessPlatform/ViewController/应付账款/YingFuZKListViewController.xib
...atform/ViewController/应付账款/YingFuZKListViewController.xib
+4
-3
GeliBusinessPlatform/ViewController/应付账款/YingFuZhangKuanCell.swift
...essPlatform/ViewController/应付账款/YingFuZhangKuanCell.swift
+2
-0
GeliBusinessPlatform/ViewController/应付账款/YingFuZhangKuanCell.xib
...inessPlatform/ViewController/应付账款/YingFuZhangKuanCell.xib
+4
-0
GeliBusinessPlatform/ViewController/应付账款/YingFuZhangKuanXQCell.swift
...sPlatform/ViewController/应付账款/YingFuZhangKuanXQCell.swift
+21
-6
GeliBusinessPlatform/ViewController/应付账款/YingFuZhangKuanXQCell.xib
...essPlatform/ViewController/应付账款/YingFuZhangKuanXQCell.xib
+1
-3
GeliBusinessPlatform/ViewController/应付账款/YingFuZhangKuanXQViewController.swift
...ViewController/应付账款/YingFuZhangKuanXQViewController.swift
+205
-42
GeliBusinessPlatform/ViewController/应付账款/YingFuZhangKuanXQViewController.xib
...m/ViewController/应付账款/YingFuZhangKuanXQViewController.xib
+4
-3
No files found.
GeliBusinessPlatform.xcodeproj/project.pbxproj
View file @
8da510de
...
...
@@ -142,6 +142,8 @@
E0516F832448086700E373CE
/* MsgCenterCell.xib in Resources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
E0516F812448086700E373CE
/* MsgCenterCell.xib */
;
};
E0571C6C248DC60000E85711
/* AddressListModel.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
E0571C6B248DC60000E85711
/* AddressListModel.swift */
;
};
E0571C6E248DD4DE00E85711
/* AdressInterface.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
E0571C6D248DD4DE00E85711
/* AdressInterface.swift */
;
};
E05FAD272498A5E500D8C90D
/* accountsPayableInterface.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
E05FAD262498A5E500D8C90D
/* accountsPayableInterface.swift */
;
};
E05FAD2A2498A5F200D8C90D
/* accountsPayableListModel.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
E05FAD292498A5F200D8C90D
/* accountsPayableListModel.swift */
;
};
E06524ED2458008900CA22E2
/* RuKuViewController.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
E06524EB2458008900CA22E2
/* RuKuViewController.swift */
;
};
E06524EE2458008900CA22E2
/* RuKuViewController.xib in Resources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
E06524EC2458008900CA22E2
/* RuKuViewController.xib */
;
};
E06524F124580AAC00CA22E2
/* RuKuJiaGeCell.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
E06524EF24580AAC00CA22E2
/* RuKuJiaGeCell.swift */
;
};
...
...
@@ -688,6 +690,8 @@
E0516F812448086700E373CE
/* MsgCenterCell.xib */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
file.xib
;
path
=
MsgCenterCell.xib
;
sourceTree
=
"<group>"
;
};
E0571C6B248DC60000E85711
/* AddressListModel.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
AddressListModel.swift
;
sourceTree
=
"<group>"
;
};
E0571C6D248DD4DE00E85711
/* AdressInterface.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
AdressInterface.swift
;
sourceTree
=
"<group>"
;
};
E05FAD262498A5E500D8C90D
/* accountsPayableInterface.swift */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.swift
;
path
=
accountsPayableInterface.swift
;
sourceTree
=
"<group>"
;
};
E05FAD292498A5F200D8C90D
/* accountsPayableListModel.swift */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.swift
;
path
=
accountsPayableListModel.swift
;
sourceTree
=
"<group>"
;
};
E06524EB2458008900CA22E2
/* RuKuViewController.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
RuKuViewController.swift
;
sourceTree
=
"<group>"
;
};
E06524EC2458008900CA22E2
/* RuKuViewController.xib */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
file.xib
;
path
=
RuKuViewController.xib
;
sourceTree
=
"<group>"
;
};
E06524EF24580AAC00CA22E2
/* RuKuJiaGeCell.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
RuKuJiaGeCell.swift
;
sourceTree
=
"<group>"
;
};
...
...
@@ -1552,6 +1556,14 @@
path
=
AdrModel
;
sourceTree
=
"<group>"
;
};
E05FAD282498A5E800D8C90D
/* yfzkModel */
=
{
isa
=
PBXGroup
;
children
=
(
E05FAD292498A5F200D8C90D
/* accountsPayableListModel.swift */
,
);
path
=
yfzkModel
;
sourceTree
=
"<group>"
;
};
E06524EA2458006600CA22E2
/* 入库 */
=
{
isa
=
PBXGroup
;
children
=
(
...
...
@@ -1689,6 +1701,7 @@
E09B03A92445B09200211A51
/* Model */
=
{
isa
=
PBXGroup
;
children
=
(
E05FAD282498A5E800D8C90D
/* yfzkModel */
,
F924B38E24971BB600A913CD
/* CustomerModel */
,
E0EFB9CC24931877005FB0CD
/* PurchaseModel */
,
F9697240248F6F550010D39B
/* VendorModel */
,
...
...
@@ -1701,6 +1714,7 @@
F956D5BD246A3629003FF510
/* PersonCenterModel */
,
F956D5BC246A35DB003FF510
/* GoodsManageMoel */
,
F9171EFB245128B200359C2B
/* Interface.swift */
,
E05FAD262498A5E500D8C90D
/* accountsPayableInterface.swift */
,
E007B1DA248F8F57004D14CC
/* PurchaseInterface.swift */
,
F9697243248F70C00010D39B
/* VendorInterface.swift */
,
E0AA3A88248F3E1400CBFC27
/* StatisticsInterface.swift */
,
...
...
@@ -3072,6 +3086,7 @@
E02D586D2477A2D90065A9EB
/* EditFtNumberModel.swift in Sources */
,
F95A9EE924558B8800867849
/* ShowAlGoodsViewController.swift in Sources */
,
E0190A2D2487696F00B1E067
/* NewSelectItemVc.swift in Sources */
,
E05FAD2A2498A5F200D8C90D
/* accountsPayableListModel.swift in Sources */
,
E09B03C32445BD9500211A51
/* NavViewController.swift in Sources */
,
F950FDD924518B9500C40530
/* FSCalendarDelegationFactory.m in Sources */
,
E0571C6C248DC60000E85711
/* AddressListModel.swift in Sources */
,
...
...
@@ -3281,6 +3296,7 @@
E042F730245272FF00CDFA12
/* XiaYunDanViewController.swift in Sources */
,
E09B03A72445B04E00211A51
/* BaseViewController.swift in Sources */
,
E02DDD9924501A5B00ABB707
/* DelGuiGeCell.swift in Sources */
,
E05FAD272498A5E500D8C90D
/* accountsPayableInterface.swift in Sources */
,
E0CC847E24823602009B1FE9
/* WarehouseIoListModel.swift in Sources */
,
E088CC932447124D000DAA8A
/* BindViewController.swift in Sources */
,
E0EFB9CA24930DD5005FB0CD
/* CGDListVC.swift in Sources */
,
...
...
This diff is collapsed.
Click to expand it.
GeliBusinessPlatform.xcworkspace/xcuserdata/junyelu.xcuserdatad/UserInterfaceState.xcuserstate
View file @
8da510de
No preview for this file type
This diff is collapsed.
Click to expand it.
GeliBusinessPlatform/Interface/Interface_Z.plist
View file @
8da510de
...
...
@@ -170,5 +170,9 @@
<string>
Customer/cusEdit
</string>
<key>
获取绑定用户的用户信息
</key>
<string>
Customer/getBindUser
</string>
<key>
应付账款列表
</key>
<string>
Finance/accountsPayableList
</string>
<key>
应付账款详情
</key>
<string>
Finance/accountsPayableDetail
</string>
</dict>
</plist>
This diff is collapsed.
Click to expand it.
GeliBusinessPlatform/Model/accountsPayableInterface.swift
0 → 100644
View file @
8da510de
//
// accountsPayableInterface.swift
// GeliBusinessPlatform
//
// Created by junye lu on 2020/6/16.
// Copyright © 2020 junye lu. All rights reserved.
//
import
Foundation
import
Alamofire
import
SwiftyJSON
import
ObjectMapper
//MARK:--应付账款列表
/* 说明:供应商信息在列表中已经全部列出,详情功能拿列表数据即可
//params-key(
//user_token(验证token)
page 页数
keyword 搜索关键词
*/
func
accountsPayableList
(
_
params
:[
String
:
Any
],
success
:
@escaping
(
_
res
:
Any
)
->
(),
failture
:
@escaping
(
_
error
:
Error
)
->
())
{
NetworkRequest
.
sharedInstance
.
postRequest
(
"应付账款列表"
,
params
,
{
(
rep
:
DataResponse
<
accountsPayableListModel
>
)
in
},
success
:
{
(
data
)
in
success
(
data
)
})
{
(
error
)
in
failture
(
error
)
}
}
//MARK:--应付账款详情
/* 说明:供应商信息在列表中已经全部列出,详情功能拿列表数据即可
//params-key(
//user_token(验证token)
page 页数
keyword 搜索关键词
*/
func
accountsPayableDetail
(
_
params
:[
String
:
Any
],
success
:
@escaping
(
_
res
:
Any
)
->
(),
failture
:
@escaping
(
_
error
:
Error
)
->
())
{
NetworkRequest
.
sharedInstance
.
postRequest
(
"应付账款详情"
,
params
,
{
(
rep
:
DataResponse
<
accountsPayableDetailModel
>
)
in
},
success
:
{
(
data
)
in
success
(
data
)
})
{
(
error
)
in
failture
(
error
)
}
}
This diff is collapsed.
Click to expand it.
GeliBusinessPlatform/Model/yfzkModel/accountsPayableListModel.swift
0 → 100644
View file @
8da510de
//
// accountsPayableListModel.swift
// GeliBusinessPlatform
//
// Created by junye lu on 2020/6/16.
// Copyright © 2020 junye lu. All rights reserved.
//
import
Foundation
import
ObjectMapper
//MARK: - 应付账款列表
class
accountsPayableListModel
:
Mappable
{
var
code
:
Int
?
var
message
:
String
?
var
data
:
accountsPayableDataModel
?
required
init
?(
map
:
Map
)
{
}
func
mapping
(
map
:
Map
)
{
code
<-
map
[
"code"
]
message
<-
map
[
"message"
]
data
<-
map
[
"data"
]
}
}
class
accountsPayableDataModel
:
Mappable
{
var
vendor_res
:
Array
<
accountsPayableListDataModel
>
?
var
total_payable_money
:
Float
?
required
init
?(
map
:
Map
)
{
}
func
mapping
(
map
:
Map
)
{
vendor_res
<-
map
[
"vendor_res"
]
total_payable_money
<-
map
[
"total_payable_money"
]
}
}
class
accountsPayableListDataModel
:
Mappable
{
var
ven_id
:
Int
?
var
ven_name
:
String
?
var
payable_money
:
String
?
required
init
?(
map
:
Map
)
{
}
func
mapping
(
map
:
Map
)
{
ven_id
<-
map
[
"ven_id"
]
ven_name
<-
map
[
"ven_name"
]
payable_money
<-
map
[
"payable_money"
]
}
}
//MARK: - 应付账款详情
class
accountsPayableDetailModel
:
Mappable
{
var
code
:
Int
?
var
message
:
String
?
var
data
:
accountsPayableDetailDataModel
?
required
init
?(
map
:
Map
)
{
}
func
mapping
(
map
:
Map
)
{
code
<-
map
[
"code"
]
message
<-
map
[
"message"
]
data
<-
map
[
"data"
]
}
}
class
accountsPayableDetailDataModel
:
Mappable
{
var
list
:
Array
<
accountsPayableDetailDataListModel
>
?
var
payable
:
String
?
var
already
:
Float
?
required
init
?(
map
:
Map
)
{
}
func
mapping
(
map
:
Map
)
{
list
<-
map
[
"list"
]
payable
<-
map
[
"payable"
]
already
<-
map
[
"already"
]
}
}
class
accountsPayableDetailDataListModel
:
Mappable
{
var
ven_id_log
:
Int
?
var
ven_id
:
Int
?
var
po_id
:
Int
?
var
money
:
String
?
var
type
:
Int
?
var
create_time
:
Double
?
var
payable_money
:
String
?
var
status
:
Int
?
var
po_no
:
String
?
required
init
?(
map
:
Map
)
{
}
func
mapping
(
map
:
Map
)
{
ven_id_log
<-
map
[
"ven_id_log"
]
ven_id
<-
map
[
"ven_id"
]
po_id
<-
map
[
"po_id"
]
money
<-
map
[
"money"
]
type
<-
map
[
"type"
]
create_time
<-
map
[
"create_time"
]
payable_money
<-
map
[
"payable_money"
]
status
<-
map
[
"status"
]
po_no
<-
map
[
"po_no"
]
}
}
This diff is collapsed.
Click to expand it.
GeliBusinessPlatform/View/AlertView/GLAlertSelectView.swift
View file @
8da510de
...
...
@@ -10,6 +10,7 @@ import UIKit
import
IQKeyboardManagerSwift
@objc
protocol
GLAlertSelectViewDelegate
{
@objc
optional
func
GLAlertSelectViewFinish
(
sender
:
UIButton
,
title
:
String
,
cellTag
:
Int
)
//普通状态(单多选)
@objc
optional
func
GLAlertSelectViewClick
(
selectNum
:
Int
,
view
:
GLAlertSelectView
)
//单选
@objc
optional
func
GLAlertMoreSelectViewClick
(
sender
:
Array
<
Int
>
,
view
:
UIView
)
//多选
...
...
@@ -24,7 +25,14 @@ import IQKeyboardManagerSwift
@objc
optional
func
KuWeiDataArr
(
sender
:
Array
<
Any
>
)
}
class
GLAlertSelectView
:
UIView
,
UITableViewDelegate
,
UITableViewDataSource
,
TitleAndSelectCellDelegate
,
KuWeiCellCellDelegate
,
UITextFieldDelegate
{
class
GLAlertSelectView
:
UIView
,
UITableViewDelegate
,
UITableViewDataSource
,
TitleAndSelectCellDelegate
,
KuWeiCellCellDelegate
,
UITextFieldDelegate
,
GeliAlertViewDelegate
{
func
sureGeliAlertViewAction
(
sender
:
UIButton
)
{
delegate
?
.
GLAlertSelectViewFinish
?(
sender
:
sender
,
title
:
ysyfTitle
,
cellTag
:
cellTag
!
)
}
var
cellTag
:
Int
?
var
isYsYf
=
false
var
ysyfTitle
=
""
var
deSelectArr
:
Array
<
Int
>
=
[]
var
isOnlySelectKuWei
=
false
...
...
@@ -141,7 +149,7 @@ class GLAlertSelectView: UIView,UITableViewDelegate,UITableViewDataSource,TitleA
selectTbv
.
isScrollEnabled
=
false
ipdVHeight
.
constant
=
0.001
}
func
setKuWeiView
(){
IQKeyboardManager
.
shared
.
resignFirstResponder
()
...
...
@@ -264,8 +272,17 @@ class GLAlertSelectView: UIView,UITableViewDelegate,UITableViewDataSource,TitleA
HUD
.
flash
(
.
label
(
"
\(
titleLbl
.
text
!
)
"
),
delay
:
1.2
)
return
}
delegate
?
.
GLAlertSelectViewClick
?(
selectNum
:
selectNum
!
,
view
:
self
)
if
isYsYf
{
let
alertView
=
GeliAlertView
(
frame
:
self
.
window
!.
bounds
)
alertView
.
delegate
=
self
;
alertView
.
tishiLbl
.
text
=
""
alertView
.
titileLbl
.
text
=
"确定设为
\(
dataArr
[
selectNum
!
]
)
?"
alertView
.
rightBtn
.
setAttributedTitle
(
NSAttributedString
(
string
:
"确定"
),
for
:
.
normal
)
alertView
.
rightBtn
.
tag
=
selectNum
!
self
.
window
?
.
addSubview
(
alertView
)
}
else
{
delegate
?
.
GLAlertSelectViewClick
?(
selectNum
:
selectNum
!
,
view
:
self
)
}
}
else
{
if
selectArray
==
[
99
,
99
,
99
,
99
]
{
HUD
.
flash
(
.
label
(
"
\(
titleLbl
.
text
!
)
"
),
delay
:
1.2
)
...
...
This diff is collapsed.
Click to expand it.
GeliBusinessPlatform/ViewController/应付账款/YingFuZKListViewController.swift
View file @
8da510de
...
...
@@ -9,9 +9,11 @@
import
UIKit
class
YingFuZKListViewController
:
BaseViewController
,
UISearchBarDelegate
,
SearchBarViewDelegate
,
UITableViewDataSource
,
UITableViewDelegate
{
let
UserToken
=
UserDefaults
.
standard
.
value
(
forKey
:
"user_token"
)
var
page
:
Int
=
0
var
keyword
:
String
=
""
var
dataArr
:
Array
<
accountsPayableListDataModel
>
=
[]
//应付
var
datas
:
Array
<
Any
>
=
[]
//应收
@IBOutlet
weak
var
titleLbl
:
UILabel
!
@IBOutlet
weak
var
totalPriceLbl
:
UILabel
!
@IBOutlet
weak
var
topView
:
UIView
!
...
...
@@ -38,35 +40,157 @@ class YingFuZKListViewController: BaseViewController,UISearchBarDelegate,SearchB
make
.
height
.
equalTo
(
30
)
}
searchV
=
searchBr
searchBr
.
placeholderStr
=
"请输入
品牌名称/商品编码
"
searchBr
.
placeholderStr
=
"请输入
单号
"
searchBr
.
cornerRadius
=
35
/
2.0
searchBr
.
delegate
=
self
searchBr
.
delegateL
=
self
listView
.
register
(
UINib
(
nibName
:
"YingFuZhangKuanCell"
,
bundle
:
nil
),
forCellReuseIdentifier
:
"YingFuZhangKuanCell"
)
//下拉刷新相关设置
headerMJ
.
setRefreshingTarget
(
self
,
refreshingAction
:
#selector(
loadData
)
)
listView
.
mj_header
=
headerMJ
//上拉加载相关设置
footerMJ
.
setRefreshingTarget
(
self
,
refreshingAction
:
#selector(
loadMoreData
)
)
listView
.
mj_footer
=
footerMJ
listView
.
mj_header
?
.
beginRefreshing
()
}
//MARK: - CELL DELEGATE
//MARK: - CELL DELEGATE
func
tableView
(
_
tableView
:
UITableView
,
didSelectRowAt
indexPath
:
IndexPath
)
{
let
vc
=
YingFuZhangKuanXQViewController
()
vc
.
navTitle
=
"
\(
barTitle
!
)
详情"
vc
.
navTitle
=
"
\(
barTitle
!
)
详情"
if
(
barTitle
?
.
contains
(
"应付"
))
!
{
let
model
=
dataArr
[
indexPath
.
row
]
vc
.
ven_id
=
model
.
ven_id
!
}
self
.
navigationController
?
.
pushViewController
(
vc
,
animated
:
true
)
}
func
tableView
(
_
tableView
:
UITableView
,
heightForRowAt
indexPath
:
IndexPath
)
->
CGFloat
{
return
49
}
func
tableView
(
_
tableView
:
UITableView
,
numberOfRowsInSection
section
:
Int
)
->
Int
{
return
3
}
func
tableView
(
_
tableView
:
UITableView
,
cellForRowAt
indexPath
:
IndexPath
)
->
UITableViewCell
{
if
(
barTitle
?
.
contains
(
"应付"
))
!
{
return
dataArr
.
count
}
else
{
return
datas
.
count
}
}
func
tableView
(
_
tableView
:
UITableView
,
cellForRowAt
indexPath
:
IndexPath
)
->
UITableViewCell
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
"YingFuZhangKuanCell"
)
as!
YingFuZhangKuanCell
if
(
barTitle
?
.
contains
(
"应付"
))
!
{
let
mo
=
dataArr
[
indexPath
.
row
]
cell
.
nameLbl
.
text
=
mo
.
ven_name
!
if
mo
.
payable_money
!=
"0.00"
{
cell
.
priceLbl
.
text
=
"¥-"
+
mo
.
payable_money
!
}
else
{
cell
.
priceLbl
.
text
=
"¥0"
}
}
else
{
}
return
cell
}
//MARK: - 自定义DELEGATE
func
clearSearchAction
()
{
}
}
//MAKR:--调起搜索后添加个蒙版本
var
blackBtnView
:
UIButton
!
=
nil
func
searchBarSearchButtonClicked
(
_
searchBar
:
UISearchBar
)
{
print
(
"点击搜索进行--"
)
searchBar
.
resignFirstResponder
()
keyword
=
searchBar
.
text
!
listView
.
mj_header
?
.
beginRefreshing
()
}
//MARK:--取消搜索代理
func
clearSearchAction
()
{
print
(
"取消搜索代理了--"
)
}
func
searchBarTextDidEndEditing
(
_
searchBar
:
UISearchBar
)
{
print
(
"编辑即将结束了--"
)
removeBlackBtnView
()
if
searchBar
.
text
?
.
count
==
0
&&
keyword
.
count
!=
0
{
keyword
=
searchBar
.
text
!
listView
.
mj_header
?
.
beginRefreshing
()
}
}
func
searchBarShouldBeginEditing
(
_
searchBar
:
UISearchBar
)
->
Bool
{
print
(
"调起搜索后添加个蒙版本"
)
blackBtnView
=
UIButton
()
blackBtnView
.
backgroundColor
=
UIColor
.
init
(
named
:
"提示视图背景色"
)
self
.
view
.
addSubview
(
blackBtnView
)
blackBtnView
.
snp
.
makeConstraints
{
(
make
)
in
make
.
left
.
right
.
bottom
.
equalToSuperview
()
make
.
top
.
equalTo
(
topView
!.
snp_bottom
)
}
blackBtnView
.
addTarget
(
self
,
action
:
#selector(
removeBlackBtnView
)
,
for
:
.
touchUpInside
)
return
true
}
@objc
func
removeBlackBtnView
(){
if
blackBtnView
!=
nil
{
blackBtnView
.
removeFromSuperview
()
searchV
!.
resignFirstResponder
()
}
}
//MARK:--加载数据
@objc
func
loadData
(){
print
(
"加载数据"
)
page
=
1
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
]
if
(
barTitle
?
.
contains
(
"应付"
))
!
{
accountsPayableList
(
dic
,
success
:
{
(
data
)
in
let
model
=
(
data
as!
accountsPayableListModel
)
self
.
dataArr
.
removeAll
()
model
.
data
?
.
vendor_res
?
.
forEach
({
(
model
)
in
self
.
dataArr
.
append
(
model
)
})
self
.
totalPriceLbl
.
text
=
"¥-
\(
model
.
data
!.
total_payable_money
!
)
"
self
.
listView
.
reloadData
()
self
.
listView
.
mj_header
?
.
endRefreshing
()
self
.
page
=
2
if
model
.
data
?
.
vendor_res
?
.
count
==
0
{
self
.
listView
.
mj_footer
?
.
endRefreshingWithNoMoreData
()
}
else
{
self
.
listView
.
mj_footer
?
.
endRefreshing
()
}
})
{
(
error
)
in
self
.
listView
.
mj_header
?
.
endRefreshing
()
}
}
else
{
//应收
}
}
//MARK:--加载更多数据
@objc
func
loadMoreData
(){
print
(
"加载更多数据"
)
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
]
if
(
barTitle
?
.
contains
(
"应付"
))
!
{
accountsPayableList
(
dic
,
success
:
{
(
data
)
in
let
dataM
=
data
as!
accountsPayableListModel
if
dataM
.
data
?
.
vendor_res
?
.
count
==
0
{
self
.
listView
.
mj_footer
?
.
endRefreshingWithNoMoreData
()
}
else
{
self
.
page
+=
1
dataM
.
data
?
.
vendor_res
?
.
forEach
({
(
model
)
in
self
.
dataArr
.
append
(
model
)
})
self
.
listView
.
reloadData
()
self
.
listView
.
mj_footer
?
.
endRefreshing
()
}
})
{
(
error
)
in
self
.
listView
.
mj_footer
?
.
endRefreshing
()
}
}
else
{
//应收
}
}
}
This diff is collapsed.
Click to expand it.
GeliBusinessPlatform/ViewController/应付账款/YingFuZKListViewController.xib
View file @
8da510de
<?xml version="1.0" encoding="UTF-8"?>
<document
type=
"com.apple.InterfaceBuilder3.CocoaTouch.XIB"
version=
"3.0"
toolsVersion=
"1
5702
"
targetRuntime=
"iOS.CocoaTouch"
propertyAccessControl=
"none"
useAutolayout=
"YES"
useTraitCollections=
"YES"
useSafeAreas=
"YES"
colorMatched=
"YES"
>
<document
type=
"com.apple.InterfaceBuilder3.CocoaTouch.XIB"
version=
"3.0"
toolsVersion=
"1
6097
"
targetRuntime=
"iOS.CocoaTouch"
propertyAccessControl=
"none"
useAutolayout=
"YES"
useTraitCollections=
"YES"
useSafeAreas=
"YES"
colorMatched=
"YES"
>
<device
id=
"retina6_1"
orientation=
"portrait"
appearance=
"light"
/>
<dependencies>
<plugIn
identifier=
"com.apple.InterfaceBuilder.IBCocoaTouchPlugin"
version=
"15704"
/>
<deployment
identifier=
"iOS"
/>
<plugIn
identifier=
"com.apple.InterfaceBuilder.IBCocoaTouchPlugin"
version=
"16087"
/>
<capability
name=
"Named colors"
minToolsVersion=
"9.0"
/>
<capability
name=
"Safe area layout guides"
minToolsVersion=
"9.0"
/>
<capability
name=
"documents saved in the Xcode 8 format"
minToolsVersion=
"8.0"
/>
</dependencies>
<objects>
<placeholder
placeholderIdentifier=
"IBFilesOwner"
id=
"-1"
userLabel=
"File's Owner"
customClass=
"YingFuZKListViewController"
customModule=
"
GeliBusinessPlatform
"
customModuleProvider=
"target"
>
<placeholder
placeholderIdentifier=
"IBFilesOwner"
id=
"-1"
userLabel=
"File's Owner"
customClass=
"YingFuZKListViewController"
customModule=
"
TestClass
"
customModuleProvider=
"target"
>
<connections>
<outlet
property=
"listView"
destination=
"csq-EP-8sj"
id=
"vI5-tf-5NB"
/>
<outlet
property=
"titleLbl"
destination=
"BV0-0O-Gee"
id=
"Cag-EP-rpB"
/>
...
...
This diff is collapsed.
Click to expand it.
GeliBusinessPlatform/ViewController/应付账款/YingFuZhangKuanCell.swift
View file @
8da510de
...
...
@@ -10,6 +10,8 @@ import UIKit
class
YingFuZhangKuanCell
:
UITableViewCell
{
@IBOutlet
weak
var
priceLbl
:
UILabel
!
@IBOutlet
weak
var
nameLbl
:
UILabel
!
override
func
awakeFromNib
()
{
super
.
awakeFromNib
()
self
.
selectionStyle
=
.
none
...
...
This diff is collapsed.
Click to expand it.
GeliBusinessPlatform/ViewController/应付账款/YingFuZhangKuanCell.xib
View file @
8da510de
...
...
@@ -61,6 +61,10 @@
</constraints>
</tableViewCellContentView>
<viewLayoutGuide
key=
"safeArea"
id=
"njF-e1-oar"
/>
<connections>
<outlet
property=
"nameLbl"
destination=
"MMT-eN-xhE"
id=
"EUJ-GO-Vwb"
/>
<outlet
property=
"priceLbl"
destination=
"LNJ-Lj-fmP"
id=
"RjD-pD-TWW"
/>
</connections>
<point
key=
"canvasLocation"
x=
"132"
y=
"122"
/>
</tableViewCell>
</objects>
...
...
This diff is collapsed.
Click to expand it.
GeliBusinessPlatform/ViewController/应付账款/YingFuZhangKuanXQCell.swift
View file @
8da510de
...
...
@@ -15,7 +15,7 @@ class YingFuZhangKuanXQCell: UITableViewCell {
@IBAction
func
submitAction
(
_
sender
:
UIButton
)
{
delegate
?
.
YingFuZhangKuanXQCellBtnClick
?(
cell
:
self
,
sender
:
sender
)
}
var
isFirst
=
false
@IBOutlet
weak
var
p3Title
:
UILabel
!
@IBOutlet
weak
var
p2Title
:
UILabel
!
@IBOutlet
weak
var
p1Title
:
UILabel
!
...
...
@@ -25,6 +25,7 @@ class YingFuZhangKuanXQCell: UITableViewCell {
@IBOutlet
weak
var
priceLbl1
:
UILabel
!
@IBOutlet
weak
var
nameLbl
:
UILabel
!
@IBOutlet
weak
var
dateLbl
:
UILabel
!
var
model
:
accountsPayableDetailDataListModel
?
override
func
awakeFromNib
()
{
super
.
awakeFromNib
()
self
.
selectionStyle
=
.
none
...
...
@@ -35,14 +36,28 @@ class YingFuZhangKuanXQCell: UITableViewCell {
super
.
layoutIfNeeded
()
submitBtn
.
layer
.
cornerRadius
=
3
submitBtn
.
layer
.
masksToBounds
=
true
if
isFirst
{
submitBtn
.
backgroundColor
=
UIColor
(
named
:
"按钮渐变色下,字体颜色"
)
submitBtn
.
setTitleColor
(
UIColor
.
white
,
for
:
.
normal
)
submitBtn
.
layer
.
borderWidth
=
0
}
else
{
priceLbl1
.
text
=
"-"
priceLbl2
.
text
=
"-"
priceLbl3
.
text
=
"-"
if
model
!=
nil
{
nameLbl
.
text
=
model
?
.
po_no
!
dateLbl
.
text
=
dayAndTimeByDouble
(
sender
:
(
model
?
.
create_time
!
)
!
)
if
model
?
.
type
==
1
{
//应付
priceLbl1
.
text
=
model
?
.
money
}
else
{
//已付
priceLbl2
.
text
=
model
?
.
money
}
priceLbl3
.
text
=
model
?
.
payable_money
submitBtn
.
backgroundColor
=
UIColor
.
clear
submitBtn
.
setTitleColor
(
UIColor
(
named
:
"灰色字体颜色"
),
for
:
.
normal
)
submitBtn
.
setTitle
(
"设置未收款"
,
for
:
.
normal
)
submitBtn
.
layer
.
borderWidth
=
1
if
model
?
.
status
==
1
{
submitBtn
.
backgroundColor
=
UIColor
(
named
:
"按钮渐变色下,字体颜色"
)
submitBtn
.
setTitle
(
"付款"
,
for
:
.
normal
)
submitBtn
.
setTitleColor
(
UIColor
.
white
,
for
:
.
normal
)
submitBtn
.
layer
.
borderWidth
=
0
}
}
}
...
...
This diff is collapsed.
Click to expand it.
GeliBusinessPlatform/ViewController/应付账款/YingFuZhangKuanXQCell.xib
View file @
8da510de
...
...
@@ -83,9 +83,8 @@
<nil
key=
"highlightedColor"
/>
</label>
<label
opaque=
"NO"
userInteractionEnabled=
"NO"
contentMode=
"left"
horizontalHuggingPriority=
"251"
verticalHuggingPriority=
"251"
text=
"一"
textAlignment=
"center"
lineBreakMode=
"tailTruncation"
baselineAdjustment=
"alignBaselines"
adjustsFontSizeToFit=
"NO"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"GK8-LK-p2U"
>
<rect
key=
"frame"
x=
"
36"
y=
"100.5"
width=
"42
"
height=
"18.5"
/>
<rect
key=
"frame"
x=
"
50.5"
y=
"100.5"
width=
"13.5
"
height=
"18.5"
/>
<constraints>
<constraint
firstAttribute=
"width"
constant=
"42"
id=
"9ic-Hz-j5h"
/>
<constraint
firstAttribute=
"height"
constant=
"18.5"
id=
"aDS-2o-EEP"
/>
</constraints>
<fontDescription
key=
"fontDescription"
type=
"system"
pointSize=
"13"
/>
...
...
@@ -101,7 +100,6 @@
<label
opaque=
"NO"
userInteractionEnabled=
"NO"
contentMode=
"left"
horizontalHuggingPriority=
"251"
verticalHuggingPriority=
"251"
text=
"¥654156"
textAlignment=
"natural"
lineBreakMode=
"tailTruncation"
baselineAdjustment=
"alignBaselines"
adjustsFontSizeToFit=
"NO"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"yzg-sO-UiV"
>
<rect
key=
"frame"
x=
"274"
y=
"102"
width=
"55"
height=
"16"
/>
<constraints>
<constraint
firstAttribute=
"width"
constant=
"55"
id=
"M82-JN-Yxd"
/>
<constraint
firstAttribute=
"height"
constant=
"16"
id=
"dST-8e-7Vb"
/>
</constraints>
<fontDescription
key=
"fontDescription"
type=
"system"
pointSize=
"13"
/>
...
...
This diff is collapsed.
Click to expand it.
GeliBusinessPlatform/ViewController/应付账款/YingFuZhangKuanXQViewController.swift
View file @
8da510de
...
...
@@ -9,24 +9,77 @@
import
UIKit
class
YingFuZhangKuanXQViewController
:
BaseViewController
,
UISearchBarDelegate
,
SearchBarViewDelegate
,
UITableViewDelegate
,
UITableViewDataSource
,
YingFuZhangKuanXQCellDelegate
,
GLAlertSelectViewDelegate
{
let
UserToken
=
UserDefaults
.
standard
.
value
(
forKey
:
"user_token"
)
var
ven_id
:
Int
?
var
dataArr
:
Array
<
accountsPayableDetailDataListModel
>
=
[]
var
datas
:
Array
<
Any
>
=
[]
func
GLASClose
(
view
:
GLAlertSelectView
,
selectnum
:
Int
,
selectArr
:
Array
<
Int
>
)
{
typeSelect
=
selectnum
glSelectView
?
.
removeFromSuperview
()
glSelectView
=
nil
}
func
GLAlertSelectViewClick
(
selectNum
:
Int
,
view
:
GLAlertSelectView
)
{
typeSelect
=
selectNum
glSelectView
?
.
removeFromSuperview
()
glSelectView
=
nil
func
GLAlertSelectViewFinish
(
sender
:
UIButton
,
title
:
String
,
cellTag
:
Int
)
{
HUD
.
flash
(
.
progress
)
var
dict
=
[
"user_token"
:
UserToken
as
Any
]
switch
title
{
case
"付款"
:
let
model
=
dataArr
[
cellTag
]
dict
[
"po_id"
]
=
model
.
po_id
dict
[
"pay_type"
]
=
sender
.
tag
+
1
dict
[
"pay_status"
]
=
2
payStatus
(
dict
,
success
:
{
(
data
)
in
HUD
.
hide
()
self
.
listView
.
mj_header
?
.
beginRefreshing
()
})
{
(
err
)
in
}
break
case
"设置未收款"
:
let
model
=
dataArr
[
cellTag
]
dict
[
"po_id"
]
=
model
.
po_id
dict
[
"pay_type"
]
=
0
dict
[
"pay_status"
]
=
1
payStatus
(
dict
,
success
:
{
(
data
)
in
HUD
.
hide
()
self
.
listView
.
mj_header
?
.
beginRefreshing
()
})
{
(
err
)
in
}
break
case
"收款"
:
break
case
"未收"
:
break
default
:
break
}
self
.
glSelectView
?
.
removeFromSuperview
()
self
.
glSelectView
=
nil
}
let
payTypeArr
=
[
"已付款"
,
"未付款"
]
let
typeArr
=
[
"现金"
,
"转账(私)"
,
"转账(公)"
,
"转账(微信)"
,
"转账(支付宝)"
]
var
glSelectView
:
GLAlertSelectView
?
var
navTitle
:
String
=
""
var
typeSelect
:
Int
?
var
searchV
:
SearchBarView
?
=
nil
@IBOutlet
weak
var
listView
:
UITableView
!
@IBOutlet
weak
var
searchBGView
:
UIView
!
var
first
=
""
var
second
=
""
override
func
viewDidLoad
()
{
super
.
viewDidLoad
()
...
...
@@ -42,7 +95,7 @@ class YingFuZhangKuanXQViewController:BaseViewController,UISearchBarDelegate,Sea
make
.
height
.
equalTo
(
35
)
}
searchV
=
searchBr
searchBr
.
placeholderStr
=
"请输入
客户名称
"
searchBr
.
placeholderStr
=
"请输入
单号
"
searchBr
.
cornerRadius
=
35
/
2.0
searchBr
.
delegate
=
self
searchBr
.
delegateL
=
self
...
...
@@ -50,6 +103,15 @@ class YingFuZhangKuanXQViewController:BaseViewController,UISearchBarDelegate,Sea
SetTopFrame
(
view
:
searchBGView
,
height
:
44
)
listView
.
separatorStyle
=
.
none
listView
.
register
(
UINib
(
nibName
:
"YingFuZhangKuanXQCell"
,
bundle
:
nil
),
forCellReuseIdentifier
:
"YingFuZhangKuanXQCell"
)
//下拉刷新相关设置
headerMJ
.
setRefreshingTarget
(
self
,
refreshingAction
:
#selector(
loadData
)
)
listView
.
mj_header
=
headerMJ
//上拉加载相关设置
footerMJ
.
setRefreshingTarget
(
self
,
refreshingAction
:
#selector(
loadMoreData
)
)
listView
.
mj_footer
=
footerMJ
listView
.
mj_header
?
.
beginRefreshing
()
}
...
...
@@ -68,7 +130,7 @@ class YingFuZhangKuanXQViewController:BaseViewController,UISearchBarDelegate,Sea
make
.
width
.
equalTo
(
title
.
bounds
.
size
.
width
)
}
let
ti1
=
UILabel
()
ti1
.
text
=
"¥-
594153
"
ti1
.
text
=
"¥-
\(
first
)
"
ti1
.
font
=
UIFont
.
boldSystemFont
(
ofSize
:
13
)
ti1
.
textColor
=
UIColor
(
named
:
"#F57575"
)
view
.
addSubview
(
ti1
)
...
...
@@ -92,7 +154,7 @@ class YingFuZhangKuanXQViewController:BaseViewController,UISearchBarDelegate,Sea
make
.
width
.
equalTo
(
title2
.
bounds
.
size
.
width
)
}
let
ti11
=
UILabel
()
ti11
.
text
=
"¥
-594153
"
ti11
.
text
=
"¥
\(
second
)
"
ti11
.
font
=
UIFont
.
boldSystemFont
(
ofSize
:
13
)
ti11
.
textColor
=
UIColor
(
named
:
"#F57575"
)
view
.
addSubview
(
ti11
)
...
...
@@ -149,12 +211,12 @@ class YingFuZhangKuanXQViewController:BaseViewController,UISearchBarDelegate,Sea
}
return
105.5
}
func
clearSearchAction
()
{
}
func
tableView
(
_
tableView
:
UITableView
,
numberOfRowsInSection
section
:
Int
)
->
Int
{
return
2
if
navTitle
.
contains
(
"应付"
){
return
dataArr
.
count
}
return
datas
.
count
}
func
tableView
(
_
tableView
:
UITableView
,
heightForRowAt
indexPath
:
IndexPath
)
->
CGFloat
{
return
210
...
...
@@ -163,49 +225,150 @@ class YingFuZhangKuanXQViewController:BaseViewController,UISearchBarDelegate,Sea
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
"YingFuZhangKuanXQCell"
)
as!
YingFuZhangKuanXQCell
cell
.
delegate
=
self
cell
.
submitBtn
.
tag
=
indexPath
.
row
cell
.
isFirst
=
false
cell
.
tag
=
indexPath
.
row
if
navTitle
.
contains
(
"应付"
){
if
indexPath
.
row
==
0
{
cell
.
isFirst
=
true
cell
.
submitBtn
.
setTitle
(
"付款"
,
for
:
.
normal
)
if
dataArr
.
count
>
0
{
let
model
=
dataArr
[
indexPath
.
row
]
cell
.
model
=
model
}
}
else
{
cell
.
p1Title
.
text
=
"借方金额"
cell
.
p2Title
.
text
=
"贷方金额"
cell
.
p3Title
.
text
=
"已额"
cell
.
submitBtn
.
setTitle
(
"未收"
,
for
:
.
normal
)
if
indexPath
.
row
==
0
{
cell
.
isFirst
=
true
cell
.
submitBtn
.
setTitle
(
"收款"
,
for
:
.
normal
)
}
}
return
cell
}
//MARK: - 列表按钮改变状态
func
YingFuZhangKuanXQCellBtnClick
(
cell
:
YingFuZhangKuanXQCell
,
sender
:
UIButton
)
{
if
cell
.
tag
==
0
{
//第一栏
let
view
=
GLAlertSelectView
(
frame
:
self
.
view
.
bounds
)
view
.
delegate
=
self
view
.
isYsYf
=
true
view
.
ysyfTitle
=
sender
.
titleLabel
?
.
text
!
as!
String
view
.
cellTag
=
cell
.
tag
switch
sender
.
titleLabel
?
.
text
{
case
"付款"
:
if
glSelectView
==
nil
{
view
.
dataArr
=
typeArr
view
.
titleLbl
.
text
=
"请选择付款方式"
glSelectView
=
view
}
break
case
"设置未收款"
:
if
glSelectView
==
nil
{
let
view
=
GLAlertSelectView
(
frame
:
self
.
view
.
bounds
)
view
.
delegate
=
self
if
typeSelect
!=
nil
&&
typeSelect
!=
10086
{
view
.
selectNum
=
typeSelect
view
.
tempNum
=
view
.
selectNum
view
.
titleLbl
.
text
=
"请选择付款状态"
view
.
selectNum
=
0
view
.
dataArr
=
payTypeArr
glSelectView
=
view
}
break
case
"收款"
:
break
case
"未收"
:
break
default
:
break
}
self
.
view
.
addSubview
(
view
)
}
var
keyword
=
""
var
page
=
0
//MAKR:--调起搜索后添加个蒙版本
var
blackBtnView
:
UIButton
!
=
nil
func
searchBarSearchButtonClicked
(
_
searchBar
:
UISearchBar
)
{
print
(
"点击搜索进行--"
)
searchBar
.
resignFirstResponder
()
keyword
=
searchBar
.
text
!
listView
.
mj_header
?
.
beginRefreshing
()
}
//MARK:--取消搜索代理
func
clearSearchAction
()
{
print
(
"取消搜索代理了--"
)
}
func
searchBarTextDidEndEditing
(
_
searchBar
:
UISearchBar
)
{
print
(
"编辑即将结束了--"
)
removeBlackBtnView
()
if
searchBar
.
text
?
.
count
==
0
&&
keyword
.
count
!=
0
{
keyword
=
searchBar
.
text
!
listView
.
mj_header
?
.
beginRefreshing
()
}
}
func
searchBarShouldBeginEditing
(
_
searchBar
:
UISearchBar
)
->
Bool
{
print
(
"调起搜索后添加个蒙版本"
)
blackBtnView
=
UIButton
()
blackBtnView
.
backgroundColor
=
UIColor
.
init
(
named
:
"提示视图背景色"
)
self
.
view
.
addSubview
(
blackBtnView
)
blackBtnView
.
snp
.
makeConstraints
{
(
make
)
in
make
.
left
.
right
.
bottom
.
equalToSuperview
()
make
.
top
.
equalTo
(
searchBGView
!.
snp_bottom
)
}
blackBtnView
.
addTarget
(
self
,
action
:
#selector(
removeBlackBtnView
)
,
for
:
.
touchUpInside
)
return
true
}
@objc
func
removeBlackBtnView
(){
if
blackBtnView
!=
nil
{
blackBtnView
.
removeFromSuperview
()
searchV
!.
resignFirstResponder
()
}
}
//MARK:--加载数据
@objc
func
loadData
(){
print
(
"加载数据"
)
page
=
1
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
,
"ven_id"
:
ven_id
as
Any
]
if
(
navTitle
.
contains
(
"应付"
)){
accountsPayableDetail
(
dic
,
success
:
{
(
data
)
in
let
model
=
(
data
as!
accountsPayableDetailModel
)
self
.
dataArr
.
removeAll
()
model
.
data
?
.
list
?
.
forEach
({
(
model
)
in
self
.
dataArr
.
append
(
model
)
})
if
model
.
data
?
.
payable
!=
nil
{
self
.
first
=
model
.
data
?
.
payable
as!
String
}
if
model
.
data
?
.
already
!=
nil
{
self
.
second
=
"
\(
model
.
data
!.
already
!
)
"
}
if
navTitle
.
contains
(
"应收"
){
view
.
titleLbl
.
text
=
"请选择收款方式"
self
.
listView
.
reloadData
()
self
.
listView
.
mj_header
?
.
endRefreshing
()
self
.
page
=
2
if
model
.
data
?
.
list
?
.
count
==
0
{
self
.
listView
.
mj_footer
?
.
endRefreshingWithNoMoreData
()
}
else
{
view
.
titleLbl
.
text
=
"请选择付款方式"
self
.
listView
.
mj_footer
?
.
endRefreshing
()
}
view
.
dataArr
=
typeArr
self
.
view
.
addSubview
(
view
)
glSelectView
=
view
})
{
(
error
)
in
self
.
listView
.
mj_header
?
.
endRefreshing
()
}
}
else
{
//第二栏
}
else
{
//应收
}
}
//MARK:--加载更多数据
@objc
func
loadMoreData
(){
print
(
"加载更多数据"
)
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
,
"ven_id"
:
ven_id
as
Any
]
if
(
navTitle
.
contains
(
"应付"
)){
accountsPayableDetail
(
dic
,
success
:
{
(
data
)
in
let
dataM
=
data
as!
accountsPayableDetailModel
if
dataM
.
data
?
.
list
?
.
count
==
0
{
self
.
listView
.
mj_footer
?
.
endRefreshingWithNoMoreData
()
}
else
{
self
.
page
+=
1
dataM
.
data
?
.
list
?
.
forEach
({
(
model
)
in
self
.
dataArr
.
append
(
model
)
})
self
.
listView
.
reloadData
()
self
.
listView
.
mj_footer
?
.
endRefreshing
()
}
})
{
(
error
)
in
self
.
listView
.
mj_footer
?
.
endRefreshing
()
}
}
else
{
//应收
}
}
...
...
This diff is collapsed.
Click to expand it.
GeliBusinessPlatform/ViewController/应付账款/YingFuZhangKuanXQViewController.xib
View file @
8da510de
<?xml version="1.0" encoding="UTF-8"?>
<document
type=
"com.apple.InterfaceBuilder3.CocoaTouch.XIB"
version=
"3.0"
toolsVersion=
"1
5702
"
targetRuntime=
"iOS.CocoaTouch"
propertyAccessControl=
"none"
useAutolayout=
"YES"
useTraitCollections=
"YES"
useSafeAreas=
"YES"
colorMatched=
"YES"
>
<document
type=
"com.apple.InterfaceBuilder3.CocoaTouch.XIB"
version=
"3.0"
toolsVersion=
"1
6097
"
targetRuntime=
"iOS.CocoaTouch"
propertyAccessControl=
"none"
useAutolayout=
"YES"
useTraitCollections=
"YES"
useSafeAreas=
"YES"
colorMatched=
"YES"
>
<device
id=
"retina6_1"
orientation=
"portrait"
appearance=
"light"
/>
<dependencies>
<plugIn
identifier=
"com.apple.InterfaceBuilder.IBCocoaTouchPlugin"
version=
"15704"
/>
<deployment
identifier=
"iOS"
/>
<plugIn
identifier=
"com.apple.InterfaceBuilder.IBCocoaTouchPlugin"
version=
"16087"
/>
<capability
name=
"Named colors"
minToolsVersion=
"9.0"
/>
<capability
name=
"Safe area layout guides"
minToolsVersion=
"9.0"
/>
<capability
name=
"documents saved in the Xcode 8 format"
minToolsVersion=
"8.0"
/>
</dependencies>
<objects>
<placeholder
placeholderIdentifier=
"IBFilesOwner"
id=
"-1"
userLabel=
"File's Owner"
customClass=
"YingFuZhangKuanXQViewController"
customModule=
"
GeliBusinessPlatform
"
customModuleProvider=
"target"
>
<placeholder
placeholderIdentifier=
"IBFilesOwner"
id=
"-1"
userLabel=
"File's Owner"
customClass=
"YingFuZhangKuanXQViewController"
customModule=
"
TestClass
"
customModuleProvider=
"target"
>
<connections>
<outlet
property=
"listView"
destination=
"7VX-Hn-lfa"
id=
"MWv-pp-tI2"
/>
<outlet
property=
"searchBGView"
destination=
"fQf-mJ-t0V"
id=
"Flu-qf-wdv"
/>
...
...
This diff is collapsed.
Click to expand it.
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