Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
galaxy-iOS
Project
Project
Details
Activity
Releases
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
mobile-group
galaxy-iOS
Commits
050d98a7
Commit
050d98a7
authored
Oct 12, 2024
by
Steven杜宇
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
// 预约
parent
ccc88569
Changes
11
Show whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
250 additions
and
42 deletions
+250
-42
YHServiceOrderListViewController.swift
...entService(服务中心)/C/YHServiceOrderListViewController.swift
+3
-0
YHResignAppointContainerViewController.swift
...nt(在港递交预约)/C/YHResignAppointContainerViewController.swift
+3
-1
YHResignAppointSubmitScheduleViewController.swift
...递交预约)/C/YHResignAppointSubmitScheduleViewController.swift
+41
-28
YHResignAppointTimeViewController.swift
...Appoint(在港递交预约)/C/YHResignAppointTimeViewController.swift
+1
-1
YHResignAppointedScheduleLineView.swift
...Appoint(在港递交预约)/V/YHResignAppointedScheduleLineView.swift
+35
-3
YHResignAppointedScheduleSingleItemView.swift
...t(在港递交预约)/V/YHResignAppointedScheduleSingleItemView.swift
+111
-4
YHResignHaveAppointedSingleInfoCell.swift
...point(在港递交预约)/V/YHResignHaveAppointedSingleInfoCell.swift
+30
-0
YHResignAppointViewModel.swift
...ResignHKAppoint(在港递交预约)/VM/YHResignAppointViewModel.swift
+4
-5
Contents.json
...nter/续签/在港递交预约/resign_appint_guide.imageset/Contents.json
+22
-0
icon-展开@2x.png
...ter/续签/在港递交预约/resign_appint_guide.imageset/icon-展开@2x.png
+0
-0
icon-展开@3x.png
...ter/续签/在港递交预约/resign_appint_guide.imageset/icon-展开@3x.png
+0
-0
No files found.
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/C/YHServiceOrderListViewController.swift
View file @
050d98a7
...
@@ -199,6 +199,9 @@ class YHServiceOrderListView: YHBaseViewController {
...
@@ -199,6 +199,9 @@ class YHServiceOrderListView: YHBaseViewController {
}
else
if
type
==
34
{
}
else
if
type
==
34
{
//在港递交预约
//在港递交预约
let
vc
=
YHResignAppointContainerViewController
()
vc
.
renewalId
=
stepId
UIViewController
.
current
?
.
navigationController
?
.
pushViewController
(
vc
)
}
else
if
type
==
35
{
}
else
if
type
==
35
{
//查看续签结果
//查看续签结果
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/Resign(续签)/ResignHKAppoint(在港递交预约)/C/YHResignAppointContainerViewController.swift
View file @
050d98a7
...
@@ -46,7 +46,8 @@ class YHResignAppointContainerViewController: YHBaseViewController {
...
@@ -46,7 +46,8 @@ class YHResignAppointContainerViewController: YHBaseViewController {
[
weak
self
]
success
,
error
in
[
weak
self
]
success
,
error
in
YHHUD
.
hide
()
YHHUD
.
hide
()
guard
let
self
=
self
else
{
return
}
guard
let
self
=
self
else
{
return
}
if
self
.
viewModel
.
appointInfoListModel
.
renewal_List
.
count
<=
0
{
// 没有预约过
var
isNotAppointed
=
self
.
viewModel
.
scheduleInfoList
.
renewal_List
.
count
<=
0
if
isNotAppointed
{
// 没有预约过
// 请求预约人员列表
// 请求预约人员列表
YHHUD
.
show
(
.
progress
(
message
:
"加载中..."
))
YHHUD
.
show
(
.
progress
(
message
:
"加载中..."
))
self
.
viewModel
.
getResignAppointUserlist
(
renewalId
:
self
.
renewalId
)
{
self
.
viewModel
.
getResignAppointUserlist
(
renewalId
:
self
.
renewalId
)
{
...
@@ -60,6 +61,7 @@ class YHResignAppointContainerViewController: YHBaseViewController {
...
@@ -60,6 +61,7 @@ class YHResignAppointContainerViewController: YHBaseViewController {
}
}
}
else
{
// 预约过
}
else
{
// 预约过
self
.
scheduleVC
.
scheduleArr
=
self
.
viewModel
.
scheduleInfoList
.
renewal_List
self
.
scheduleVC
.
view
.
isHidden
=
false
self
.
scheduleVC
.
view
.
isHidden
=
false
self
.
appointVC
.
view
.
isHidden
=
true
self
.
appointVC
.
view
.
isHidden
=
true
}
}
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/Resign(续签)/ResignHKAppoint(在港递交预约)/C/YHResignAppointSubmitScheduleViewController.swift
View file @
050d98a7
...
@@ -11,7 +11,18 @@ import UIKit
...
@@ -11,7 +11,18 @@ import UIKit
class
YHResignAppointSubmitScheduleViewController
:
YHBaseViewController
{
class
YHResignAppointSubmitScheduleViewController
:
YHBaseViewController
{
var
renewalId
:
Int
=
0
var
renewalId
:
Int
=
0
var
familyArr
:
[
String
]
=
[
""
,
""
,
""
,
""
,
""
]
var
scheduleArr
:
[
YHResignAppointGroup
]
=
[]
{
didSet
{
self
.
tableView
.
reloadData
()
}
}
var
isTogether
:
Bool
{
get
{
return
true
// return scheduleArr.count <= 1
}
}
lazy
var
tableView
:
UITableView
=
{
lazy
var
tableView
:
UITableView
=
{
let
tableView
=
UITableView
(
frame
:
CGRect
.
zero
,
style
:
.
grouped
)
let
tableView
=
UITableView
(
frame
:
CGRect
.
zero
,
style
:
.
grouped
)
...
@@ -33,20 +44,20 @@ class YHResignAppointSubmitScheduleViewController: YHBaseViewController {
...
@@ -33,20 +44,20 @@ class YHResignAppointSubmitScheduleViewController: YHBaseViewController {
return
tableView
return
tableView
}()
}()
lazy
var
tips
Btn
:
UIButton
=
{
lazy
var
guide
Btn
:
UIButton
=
{
let
button
=
UIButton
()
let
button
=
UIButton
()
button
.
setTitle
(
"
递交提示
"
,
for
:
.
normal
)
button
.
setTitle
(
"
在港递交指引
"
,
for
:
.
normal
)
button
.
titleLabel
?
.
font
=
.
PFSC_R
(
ofSize
:
11
)
button
.
titleLabel
?
.
font
=
.
PFSC_R
(
ofSize
:
11
)
button
.
setTitleColor
(
UIColor
.
mainTextColor
,
for
:
.
normal
)
button
.
setTitleColor
(
UIColor
.
mainTextColor
,
for
:
.
normal
)
button
.
setImage
(
UIImage
(
named
:
"resign_app
oint_tips_btn
"
),
for
:
.
normal
)
button
.
setImage
(
UIImage
(
named
:
"resign_app
int_guide
"
),
for
:
.
normal
)
button
.
centerTextAndImage
(
imageAboveText
:
true
,
spacing
:
0.0
)
button
.
centerTextAndImage
(
imageAboveText
:
true
,
spacing
:
0.0
)
return
button
return
button
}()
}()
lazy
var
submi
tBtn
:
UIButton
=
{
lazy
var
nex
tBtn
:
UIButton
=
{
let
btn
=
UIButton
()
let
btn
=
UIButton
()
btn
.
backgroundColor
=
.
brandMainColor
btn
.
backgroundColor
=
.
brandMainColor
btn
.
setTitle
(
"
确认提交
"
,
for
:
.
normal
)
btn
.
setTitle
(
"
下一步,去查看递交凭证
"
,
for
:
.
normal
)
btn
.
setTitleColor
(
.
white
,
for
:
.
normal
)
btn
.
setTitleColor
(
.
white
,
for
:
.
normal
)
btn
.
titleLabel
?
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
15
)
btn
.
titleLabel
?
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
15
)
btn
.
addTarget
(
self
,
action
:
#selector(
didSubmitBtnClicked
)
,
for
:
.
touchUpInside
)
btn
.
addTarget
(
self
,
action
:
#selector(
didSubmitBtnClicked
)
,
for
:
.
touchUpInside
)
...
@@ -57,16 +68,16 @@ class YHResignAppointSubmitScheduleViewController: YHBaseViewController {
...
@@ -57,16 +68,16 @@ class YHResignAppointSubmitScheduleViewController: YHBaseViewController {
lazy
var
bottomView
:
UIView
=
{
lazy
var
bottomView
:
UIView
=
{
let
view
=
UIView
()
let
view
=
UIView
()
view
.
backgroundColor
=
.
white
view
.
backgroundColor
=
.
white
view
.
addSubview
(
tips
Btn
)
view
.
addSubview
(
guide
Btn
)
view
.
addSubview
(
submi
tBtn
)
view
.
addSubview
(
nex
tBtn
)
tips
Btn
.
snp
.
makeConstraints
{
make
in
guide
Btn
.
snp
.
makeConstraints
{
make
in
make
.
left
.
equalTo
(
2
2
)
make
.
left
.
equalTo
(
2
0
)
make
.
width
.
equalTo
(
44
)
make
.
width
.
equalTo
(
66
)
make
.
height
.
equalTo
(
4
8
)
make
.
height
.
equalTo
(
4
1
)
make
.
centerY
.
equalTo
(
submi
tBtn
)
make
.
centerY
.
equalTo
(
nex
tBtn
)
}
}
submi
tBtn
.
snp
.
makeConstraints
{
make
in
nex
tBtn
.
snp
.
makeConstraints
{
make
in
make
.
left
.
equalTo
(
tipsBtn
.
snp
.
right
)
.
offset
(
22
)
make
.
left
.
equalTo
(
guideBtn
.
snp
.
right
)
.
offset
(
20
)
make
.
right
.
equalTo
(
-
20
)
make
.
right
.
equalTo
(
-
20
)
make
.
top
.
equalTo
(
8
)
make
.
top
.
equalTo
(
8
)
make
.
height
.
equalTo
(
48
)
make
.
height
.
equalTo
(
48
)
...
@@ -102,21 +113,24 @@ class YHResignAppointSubmitScheduleViewController: YHBaseViewController {
...
@@ -102,21 +113,24 @@ class YHResignAppointSubmitScheduleViewController: YHBaseViewController {
extension
YHResignAppointSubmitScheduleViewController
:
UITableViewDelegate
,
UITableViewDataSource
{
extension
YHResignAppointSubmitScheduleViewController
:
UITableViewDelegate
,
UITableViewDataSource
{
func
tableView
(
_
tableView
:
UITableView
,
numberOfRowsInSection
section
:
Int
)
->
Int
{
func
tableView
(
_
tableView
:
UITableView
,
numberOfRowsInSection
section
:
Int
)
->
Int
{
return
family
Arr
.
count
return
schedule
Arr
.
count
}
}
func
tableView
(
_
tableView
:
UITableView
,
cellForRowAt
indexPath
:
IndexPath
)
->
UITableViewCell
{
func
tableView
(
_
tableView
:
UITableView
,
cellForRowAt
indexPath
:
IndexPath
)
->
UITableViewCell
{
if
0
<=
indexPath
.
row
&&
indexPath
.
row
<
scheduleArr
.
count
{
let
model
=
scheduleArr
[
indexPath
.
row
]
if
isTogether
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHResignHaveAppointedSingleInfoCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHResignHaveAppointedSingleInfoCell
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHResignHaveAppointedSingleInfoCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHResignHaveAppointedSingleInfoCell
cell
.
updateModel
(
model
)
if
0
<=
indexPath
.
row
&&
indexPath
.
row
<
familyArr
.
count
{
return
cell
if
indexPath
.
row
==
4
{
let
cell1
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHResignHaveAppointedMultipleInfoCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHResignHaveAppointedMultipleInfoCell
return
cell1
}
}
// 分组
let
cell2
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHResignHaveAppointedMultipleInfoCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHResignHaveAppointedMultipleInfoCell
return
cell2
}
}
return
cell
let
defaultCell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
"UITableViewCell"
,
for
:
indexPath
)
return
defaultCell
}
}
func
tableView
(
_
tableView
:
UITableView
,
heightForRowAt
indexPath
:
IndexPath
)
->
CGFloat
{
func
tableView
(
_
tableView
:
UITableView
,
heightForRowAt
indexPath
:
IndexPath
)
->
CGFloat
{
...
@@ -125,9 +139,8 @@ extension YHResignAppointSubmitScheduleViewController: UITableViewDelegate, UITa
...
@@ -125,9 +139,8 @@ extension YHResignAppointSubmitScheduleViewController: UITableViewDelegate, UITa
func
tableView
(
_
tableView
:
UITableView
,
didSelectRowAt
indexPath
:
IndexPath
)
{
func
tableView
(
_
tableView
:
UITableView
,
didSelectRowAt
indexPath
:
IndexPath
)
{
if
0
<=
indexPath
.
row
&&
indexPath
.
row
<
familyArr
.
count
{
if
0
<=
indexPath
.
row
&&
indexPath
.
row
<
scheduleArr
.
count
{
let
model
=
familyArr
[
indexPath
.
row
]
let
model
=
scheduleArr
[
indexPath
.
row
]
}
}
}
}
...
@@ -136,7 +149,7 @@ extension YHResignAppointSubmitScheduleViewController: UITableViewDelegate, UITa
...
@@ -136,7 +149,7 @@ extension YHResignAppointSubmitScheduleViewController: UITableViewDelegate, UITa
}
}
private
func
tableView
(
_
tableView
:
UITableView
,
viewForFooterInSection
section
:
Int
)
->
CGFloat
{
private
func
tableView
(
_
tableView
:
UITableView
,
viewForFooterInSection
section
:
Int
)
->
CGFloat
{
return
16
return
0.1
}
}
func
tableView
(
_
tableView
:
UITableView
,
viewForFooterInSection
section
:
Int
)
->
UIView
?
{
func
tableView
(
_
tableView
:
UITableView
,
viewForFooterInSection
section
:
Int
)
->
UIView
?
{
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/Resign(续签)/ResignHKAppoint(在港递交预约)/C/YHResignAppointTimeViewController.swift
View file @
050d98a7
...
@@ -299,7 +299,7 @@ class YHResignAppointTimeViewController: YHBaseViewController {
...
@@ -299,7 +299,7 @@ class YHResignAppointTimeViewController: YHBaseViewController {
}
}
}
}
var
param
:
[
String
:
Any
]
=
[
"renewal_id"
:
renewalId
,
let
param
:
[
String
:
Any
]
=
[
"renewal_id"
:
renewalId
,
"is_together"
:
self
.
togetherSetting
.
is_together
,
"is_together"
:
self
.
togetherSetting
.
is_together
,
"batch"
:
batchs
]
"batch"
:
batchs
]
printLog
(
param
)
printLog
(
param
)
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/Resign(续签)/ResignHKAppoint(在港递交预约)/V/YHResignAppointedScheduleLineView.swift
View file @
050d98a7
...
@@ -26,9 +26,9 @@ class YHResignAppointedScheduleLineView: UIView {
...
@@ -26,9 +26,9 @@ class YHResignAppointedScheduleLineView: UIView {
var
steps
:[
YHScheduleLineStepModel
]
=
{
var
steps
:[
YHScheduleLineStepModel
]
=
{
let
model1
=
YHScheduleLineStepModel
(
title
:
"入境香港准备"
,
time
:
""
)
let
model1
=
YHScheduleLineStepModel
(
title
:
"入境香港准备"
,
time
:
""
)
let
model2
=
YHScheduleLineStepModel
(
title
:
"已确认在港"
,
time
:
"
2024-03-14
"
)
let
model2
=
YHScheduleLineStepModel
(
title
:
"已确认在港"
,
time
:
""
)
let
model3
=
YHScheduleLineStepModel
(
title
:
"银河递交续签资料"
,
time
:
"
2024-03-14
"
,
isNeedUserAction
:
false
)
let
model3
=
YHScheduleLineStepModel
(
title
:
"银河递交续签资料"
,
time
:
""
,
isNeedUserAction
:
false
)
let
model4
=
YHScheduleLineStepModel
(
title
:
"查看递交回执"
,
time
:
"
2024-03-14
"
)
let
model4
=
YHScheduleLineStepModel
(
title
:
"查看递交回执"
,
time
:
""
)
let
model5
=
YHScheduleLineStepModel
(
title
:
"在港等待获批/离港"
,
time
:
""
)
let
model5
=
YHScheduleLineStepModel
(
title
:
"在港等待获批/离港"
,
time
:
""
)
let
model6
=
YHScheduleLineStepModel
(
title
:
"在港等缴费领取新签证"
,
time
:
""
)
let
model6
=
YHScheduleLineStepModel
(
title
:
"在港等缴费领取新签证"
,
time
:
""
)
let
model7
=
YHScheduleLineStepModel
(
title
:
"更新续签旅行证件"
,
time
:
""
)
let
model7
=
YHScheduleLineStepModel
(
title
:
"更新续签旅行证件"
,
time
:
""
)
...
@@ -61,6 +61,26 @@ class YHResignAppointedScheduleLineView: UIView {
...
@@ -61,6 +61,26 @@ class YHResignAppointedScheduleLineView: UIView {
createUI
()
createUI
()
}
}
// 已确认在港时间 银河递交续签资料时间 查看递交回执时间
func
updateDates
(
confirmDate
:
String
,
submitDate
:
String
,
watchDate
:
String
)
{
if
steps
.
count
>=
2
{
// 已确认在港节点
let
confirmModel
=
steps
[
1
]
confirmModel
.
time
=
confirmDate
}
if
steps
.
count
>=
3
{
// 银河递交续签资料节点
let
submitModel
=
steps
[
2
]
submitModel
.
time
=
submitDate
}
if
steps
.
count
>=
4
{
// 查看递交回执节点
let
watchModel
=
steps
[
3
]
watchModel
.
time
=
watchDate
}
self
.
collectView
.
reloadData
()
}
func
createUI
()
{
func
createUI
()
{
self
.
addSubview
(
collectView
)
self
.
addSubview
(
collectView
)
collectView
.
reloadData
()
collectView
.
reloadData
()
...
@@ -101,6 +121,18 @@ extension YHResignAppointedScheduleLineView: UICollectionViewDelegate, UICollect
...
@@ -101,6 +121,18 @@ extension YHResignAppointedScheduleLineView: UICollectionViewDelegate, UICollect
let
model
=
steps
[
indexPath
.
item
]
let
model
=
steps
[
indexPath
.
item
]
model
.
index
=
indexPath
.
item
+
1
model
.
index
=
indexPath
.
item
+
1
cell
.
updateModel
(
model
)
cell
.
updateModel
(
model
)
if
indexPath
.
item
==
0
{
cell
.
leftDotView
.
isHidden
=
true
cell
.
rightDotView
.
isHidden
=
false
}
else
if
indexPath
.
item
==
steps
.
count
-
1
{
cell
.
leftDotView
.
isHidden
=
false
cell
.
rightDotView
.
isHidden
=
true
}
else
{
cell
.
leftDotView
.
isHidden
=
false
cell
.
rightDotView
.
isHidden
=
false
}
}
}
return
cell
return
cell
}
}
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/Resign(续签)/ResignHKAppoint(在港递交预约)/V/YHResignAppointedScheduleSingleItemView.swift
View file @
050d98a7
...
@@ -18,17 +18,19 @@ class YHResignAppointedScheduleSingleItemView: UIView {
...
@@ -18,17 +18,19 @@ class YHResignAppointedScheduleSingleItemView: UIView {
lazy
var
applicantNamesLabel
:
UILabel
=
{
lazy
var
applicantNamesLabel
:
UILabel
=
{
let
label
=
UILabel
()
let
label
=
UILabel
()
label
.
numberOfLines
=
0
label
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
14
)
label
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
14
)
label
.
textColor
=
.
mainTextColor
label
.
textColor
=
.
mainTextColor
label
.
text
=
"申请人:"
label
.
text
=
"申请人:"
return
label
return
label
}()
}()
lazy
var
c
onfirmInHKLabel
:
UILabel
=
{
lazy
var
haveC
onfirmInHKLabel
:
UILabel
=
{
let
label
=
UILabel
()
let
label
=
UILabel
()
label
.
text
=
"已确认在港"
label
.
text
=
"已确认在港"
label
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
13
)
label
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
13
)
label
.
textColor
=
.
init
(
hex
:
0x3CC694
)
label
.
textColor
=
.
init
(
hex
:
0x3CC694
)
label
.
isHidden
=
true
return
label
return
label
}()
}()
...
@@ -39,11 +41,13 @@ class YHResignAppointedScheduleSingleItemView: UIView {
...
@@ -39,11 +41,13 @@ class YHResignAppointedScheduleSingleItemView: UIView {
btn
.
setTitleColor
(
.
white
,
for
:
.
normal
)
btn
.
setTitleColor
(
.
white
,
for
:
.
normal
)
btn
.
setTitle
(
"确认在港"
,
for
:
.
normal
)
btn
.
setTitle
(
"确认在港"
,
for
:
.
normal
)
btn
.
titleLabel
?
.
font
=
.
PFSC_M
(
ofSize
:
11
)
btn
.
titleLabel
?
.
font
=
.
PFSC_M
(
ofSize
:
11
)
btn
.
isHidden
=
true
return
btn
return
btn
}()
}()
lazy
var
submitTimeLabel
:
UILabel
=
{
lazy
var
submitTimeLabel
:
UILabel
=
{
let
label
=
UILabel
()
let
label
=
UILabel
()
label
.
numberOfLines
=
0
label
.
font
=
UIFont
.
PFSC_R
(
ofSize
:
12
)
label
.
font
=
UIFont
.
PFSC_R
(
ofSize
:
12
)
label
.
textColor
=
.
mainTextColor
(
alpha
:
0.5
)
label
.
textColor
=
.
mainTextColor
(
alpha
:
0.5
)
label
.
text
=
"预约递交时间: 0000-00-00 00:00"
label
.
text
=
"预约递交时间: 0000-00-00 00:00"
...
@@ -52,6 +56,7 @@ class YHResignAppointedScheduleSingleItemView: UIView {
...
@@ -52,6 +56,7 @@ class YHResignAppointedScheduleSingleItemView: UIView {
lazy
var
confirmHKTimeLabel
:
UILabel
=
{
lazy
var
confirmHKTimeLabel
:
UILabel
=
{
let
label
=
UILabel
()
let
label
=
UILabel
()
label
.
numberOfLines
=
0
label
.
font
=
UIFont
.
PFSC_R
(
ofSize
:
12
)
label
.
font
=
UIFont
.
PFSC_R
(
ofSize
:
12
)
label
.
textColor
=
.
mainTextColor
(
alpha
:
0.5
)
label
.
textColor
=
.
mainTextColor
(
alpha
:
0.5
)
label
.
text
=
"确认在港时间: 0000-00-00 00:00"
label
.
text
=
"确认在港时间: 0000-00-00 00:00"
...
@@ -72,12 +77,114 @@ class YHResignAppointedScheduleSingleItemView: UIView {
...
@@ -72,12 +77,114 @@ class YHResignAppointedScheduleSingleItemView: UIView {
fatalError
(
"init(coder:) has not been implemented"
)
fatalError
(
"init(coder:) has not been implemented"
)
}
}
func
updateModel
(
_
model
:
YHResignAppointGroup
)
{
var
names
=
"申请人:"
for
(
index
,
user
)
in
model
.
user_list
.
enumerated
()
{
names
+=
user
.
name
if
index
!=
model
.
user_list
.
count
-
1
{
names
+=
"、"
}
}
applicantNamesLabel
.
text
=
names
submitTimeLabel
.
text
=
model
.
ready_to_submit_at
confirmHKTimeLabel
.
text
=
model
.
determine_hk_at
let
dateFormatter
=
DateFormatter
()
dateFormatter
.
dateFormat
=
"yyyy-MM-dd HH:mm:ss"
let
nowDateString
=
dateFormatter
.
string
(
from
:
Date
())
var
confirmStatus
=
YHResignConfirmHKStatus
.
waitConfirmHK
// 是否到了预约递交时间
let
isArriveSubmitTime
=
compareDates
(
model
.
ready_to_submit_at
,
nowDateString
)
if
!
isArriveSubmitTime
{
// 待确认在港
confirmStatus
=
.
waitConfirmHK
}
else
{
confirmStatus
=
!
model
.
determine_hk_at
.
isEmpty
?
.
haveConfirmHK
:
.
canConfirmHK
}
haveConfirmInHKLabel
.
isHidden
=
(
confirmStatus
!=
.
haveConfirmHK
)
confirmInHKBtn
.
isHidden
=
(
confirmStatus
==
.
haveConfirmHK
)
if
confirmStatus
==
.
waitConfirmHK
{
confirmInHKBtn
.
setTitle
(
"待确认在港"
,
for
:
.
normal
)
confirmInHKBtn
.
setTitleColor
(
.
mainTextColor
,
for
:
.
normal
)
confirmInHKBtn
.
backgroundColor
=
.
init
(
hex
:
0xF4F6FA
)
confirmInHKBtn
.
snp
.
updateConstraints
{
make
in
make
.
width
.
equalTo
(
71
)
}
}
else
if
confirmStatus
==
.
canConfirmHK
{
confirmInHKBtn
.
setTitle
(
"确认在港"
,
for
:
.
normal
)
confirmInHKBtn
.
setTitleColor
(
.
white
,
for
:
.
normal
)
confirmInHKBtn
.
backgroundColor
=
.
brandMainColor
confirmInHKBtn
.
snp
.
updateConstraints
{
make
in
make
.
width
.
equalTo
(
68
)
}
}
confirmHKTimeLabel
.
removeFromSuperview
()
confirmHKTimeLabel
.
snp
.
removeConstraints
()
if
confirmStatus
==
.
haveConfirmHK
{
// 已确认在港 需要显示确认在港时间
self
.
addSubview
(
confirmHKTimeLabel
)
confirmHKTimeLabel
.
snp
.
remakeConstraints
{
make
in
make
.
left
.
equalTo
(
18
)
make
.
right
.
equalTo
(
-
18
)
make
.
top
.
equalTo
(
submitTimeLabel
.
snp
.
bottom
)
.
offset
(
8
)
}
scheduleView
.
snp
.
remakeConstraints
{
make
in
make
.
left
.
equalTo
(
18
)
make
.
right
.
equalTo
(
-
18
)
make
.
top
.
equalTo
(
confirmHKTimeLabel
.
snp
.
bottom
)
.
offset
(
18
)
make
.
height
.
equalTo
(
84.0
)
make
.
bottom
.
equalTo
(
-
18
)
}
}
else
{
// 不需要显示确认在港时间
scheduleView
.
snp
.
remakeConstraints
{
make
in
make
.
left
.
equalTo
(
18
)
make
.
right
.
equalTo
(
-
18
)
make
.
top
.
equalTo
(
submitTimeLabel
.
snp
.
bottom
)
.
offset
(
18
)
make
.
height
.
equalTo
(
84.0
)
make
.
bottom
.
equalTo
(
-
18
)
}
}
scheduleView
.
updateDates
(
confirmDate
:
model
.
determine_hk_at
,
submitDate
:
model
.
actually_submit_at
,
watchDate
:
model
.
result_file_at
)
self
.
setNeedsLayout
()
self
.
layoutIfNeeded
()
}
// dateString1 是否不小于dateString2
func
compareDates
(
_
dateString1
:
String
,
_
dateString2
:
String
)
->
Bool
{
let
dateFormatter
=
DateFormatter
()
dateFormatter
.
dateFormat
=
"yyyy-MM-dd HH:mm:ss"
// 将字符串转换为 Date 对象
guard
let
date1
=
dateFormatter
.
date
(
from
:
dateString1
),
let
date2
=
dateFormatter
.
date
(
from
:
dateString2
)
else
{
print
(
"日期格式错误"
)
return
false
}
// 比较日期
if
date1
<
date2
{
print
(
"
\(
dateString1
)
小于
\(
dateString2
)
"
)
return
false
}
return
true
}
func
createUI
()
{
func
createUI
()
{
self
.
addSubview
(
lineView
)
self
.
addSubview
(
lineView
)
self
.
addSubview
(
applicantNamesLabel
)
self
.
addSubview
(
applicantNamesLabel
)
self
.
addSubview
(
confirmInHKBtn
)
self
.
addSubview
(
confirmInHKBtn
)
self
.
addSubview
(
confirmInHKLabel
)
self
.
addSubview
(
haveConfirmInHKLabel
)
self
.
addSubview
(
confirmHKTimeLabel
)
self
.
addSubview
(
submitTimeLabel
)
self
.
addSubview
(
submitTimeLabel
)
self
.
addSubview
(
confirmHKTimeLabel
)
self
.
addSubview
(
confirmHKTimeLabel
)
self
.
addSubview
(
scheduleView
)
self
.
addSubview
(
scheduleView
)
...
@@ -100,7 +207,7 @@ class YHResignAppointedScheduleSingleItemView: UIView {
...
@@ -100,7 +207,7 @@ class YHResignAppointedScheduleSingleItemView: UIView {
make
.
centerY
.
equalTo
(
applicantNamesLabel
)
make
.
centerY
.
equalTo
(
applicantNamesLabel
)
}
}
c
onfirmInHKLabel
.
snp
.
makeConstraints
{
make
in
haveC
onfirmInHKLabel
.
snp
.
makeConstraints
{
make
in
make
.
right
.
equalTo
(
-
18
)
make
.
right
.
equalTo
(
-
18
)
make
.
top
.
equalTo
(
applicantNamesLabel
)
make
.
top
.
equalTo
(
applicantNamesLabel
)
make
.
height
.
equalTo
(
18
)
make
.
height
.
equalTo
(
18
)
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/Resign(续签)/ResignHKAppoint(在港递交预约)/V/YHResignHaveAppointedSingleInfoCell.swift
View file @
050d98a7
...
@@ -8,6 +8,12 @@
...
@@ -8,6 +8,12 @@
import
UIKit
import
UIKit
enum
YHResignConfirmHKStatus
:
Int
{
case
waitConfirmHK
=
0
// 待确认在港
case
canConfirmHK
=
1
// 可点击确认在港
case
haveConfirmHK
=
2
// 已确认在港
}
class
YHResignHaveAppointedSingleInfoCell
:
UITableViewCell
{
class
YHResignHaveAppointedSingleInfoCell
:
UITableViewCell
{
static
let
cellReuseIdentifier
=
"YHResignHaveAppointedSingleInfoCell"
static
let
cellReuseIdentifier
=
"YHResignHaveAppointedSingleInfoCell"
...
@@ -50,6 +56,30 @@ class YHResignHaveAppointedSingleInfoCell: UITableViewCell {
...
@@ -50,6 +56,30 @@ class YHResignHaveAppointedSingleInfoCell: UITableViewCell {
setupUI
()
setupUI
()
}
}
func
updateModel
(
_
model
:
YHResignAppointGroup
)
{
batchView
.
updateModel
(
model
)
}
// dateString1 是否不小于dateString2
func
compareDates
(
_
dateString1
:
String
,
_
dateString2
:
String
)
->
Bool
{
let
dateFormatter
=
DateFormatter
()
dateFormatter
.
dateFormat
=
"yyyy-MM-dd HH:mm:ss"
// 将字符串转换为 Date 对象
guard
let
date1
=
dateFormatter
.
date
(
from
:
dateString1
),
let
date2
=
dateFormatter
.
date
(
from
:
dateString2
)
else
{
print
(
"日期格式错误"
)
return
false
}
// 比较日期
if
date1
<
date2
{
print
(
"
\(
dateString1
)
小于
\(
dateString2
)
"
)
return
false
}
return
true
}
func
setupUI
()
{
func
setupUI
()
{
self
.
selectionStyle
=
.
none
self
.
selectionStyle
=
.
none
self
.
backgroundColor
=
.
clear
self
.
backgroundColor
=
.
clear
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/Resign(续签)/ResignHKAppoint(在港递交预约)/VM/YHResignAppointViewModel.swift
View file @
050d98a7
...
@@ -13,7 +13,7 @@ class YHResignAppointViewModel: NSObject {
...
@@ -13,7 +13,7 @@ class YHResignAppointViewModel: NSObject {
// 赴港人员列表
// 赴港人员列表
var
appointUsers
:
[
YHResignAppointMember
]
=
[]
var
appointUsers
:
[
YHResignAppointMember
]
=
[]
// 预约列表预约
// 预约列表预约
var
appointInfoListModel
:
YHResignAppointListModel
=
YHResignAppointListModel
()
var
scheduleInfoList
:
YHResignAppointListModel
=
YHResignAppointListModel
()
// 赴港人员列表
// 赴港人员列表
func
getResignAppointUserlist
(
renewalId
:
Int
,
callBack
:
@escaping
(
_
success
:
Bool
,
_
error
:
YHErrorModel
?)
->
())
{
func
getResignAppointUserlist
(
renewalId
:
Int
,
callBack
:
@escaping
(
_
success
:
Bool
,
_
error
:
YHErrorModel
?)
->
())
{
...
@@ -37,7 +37,6 @@ class YHResignAppointViewModel: NSObject {
...
@@ -37,7 +37,6 @@ class YHResignAppointViewModel: NSObject {
}
else
{
}
else
{
let
error
:
YHErrorModel
=
YHErrorModel
(
errorCode
:
Int32
(
json
.
code
),
errorMsg
:
json
.
msg
)
let
error
:
YHErrorModel
=
YHErrorModel
(
errorCode
:
Int32
(
json
.
code
),
errorMsg
:
json
.
msg
)
self
.
appointUsers
=
[]
self
.
appointUsers
=
[]
self
.
appointUsers
=
self
.
getUsers
()
callBack
(
false
,
error
)
callBack
(
false
,
error
)
}
}
...
@@ -81,16 +80,16 @@ class YHResignAppointViewModel: NSObject {
...
@@ -81,16 +80,16 @@ class YHResignAppointViewModel: NSObject {
callBack
(
false
,
err
)
callBack
(
false
,
err
)
return
return
}
}
self
.
appointInfoListModel
=
resultModel
self
.
scheduleInfoList
=
resultModel
callBack
(
true
,
nil
)
callBack
(
true
,
nil
)
}
else
{
}
else
{
let
err
=
YHErrorModel
(
errorCode
:
Int32
(
json
.
code
),
errorMsg
:
json
.
msg
.
isEmpty
?
""
:
json
.
msg
)
let
err
=
YHErrorModel
(
errorCode
:
Int32
(
json
.
code
),
errorMsg
:
json
.
msg
.
isEmpty
?
""
:
json
.
msg
)
self
.
appointInfoListModel
=
YHResignAppointListModel
()
self
.
scheduleInfoList
=
YHResignAppointListModel
()
callBack
(
false
,
err
)
callBack
(
false
,
err
)
}
}
}
failBlock
:
{
err
in
}
failBlock
:
{
err
in
self
.
appointInfoListModel
=
YHResignAppointListModel
()
self
.
scheduleInfoList
=
YHResignAppointListModel
()
callBack
(
false
,
err
)
callBack
(
false
,
err
)
}
}
}
}
...
...
galaxy/galaxy/Res/Assets.xcassets/ServiceCenter/续签/在港递交预约/resign_appint_guide.imageset/Contents.json
0 → 100644
View file @
050d98a7
{
"images"
:
[
{
"idiom"
:
"universal"
,
"scale"
:
"1x"
},
{
"filename"
:
"icon-展开@2x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"2x"
},
{
"filename"
:
"icon-展开@3x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"3x"
}
],
"info"
:
{
"author"
:
"xcode"
,
"version"
:
1
}
}
galaxy/galaxy/Res/Assets.xcassets/ServiceCenter/续签/在港递交预约/resign_appint_guide.imageset/icon-展开@2x.png
0 → 100644
View file @
050d98a7
632 Bytes
galaxy/galaxy/Res/Assets.xcassets/ServiceCenter/续签/在港递交预约/resign_appint_guide.imageset/icon-展开@3x.png
0 → 100644
View file @
050d98a7
884 Bytes
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