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
8c081e1f
Commit
8c081e1f
authored
Nov 25, 2024
by
Alex朱枝文
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'qmas-1130' into yinhe-live-1212
parents
fd27691a
0bbd29f8
Changes
11
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
489 additions
and
298 deletions
+489
-298
YHIncomeRecordWorkExperienceViewController.swift
...(收入记录)/C/YHIncomeRecordWorkExperienceViewController.swift
+15
-11
YHIncomeInputMoneyCell.swift
...我的信息流程)/IncomeRecord(收入记录)/V/YHIncomeInputMoneyCell.swift
+3
-3
YHMainApplicantInformationViewController.swift
...(主申请人信息)/C/YHMainApplicantInformationViewController.swift
+1
-1
YHMainApplicantInformationViewModel.swift
...tion(主申请人信息)/VM/YHMainApplicantInformationViewModel.swift
+4
-4
YHWorkExpInfoPreviewModel.swift
.../PersonInfoList(个人信息预览)/M/YHWorkExpInfoPreviewModel.swift
+1
-0
YHPreviewInfoNameAndSubNameItemView.swift
...oList(个人信息预览)/V/YHPreviewInfoNameAndSubNameItemView.swift
+21
-18
YHPreviewViewModel.swift
...的信息流程)/PersonInfoList(个人信息预览)/VM/YHPreviewViewModel.swift
+403
-254
YHWorkExperiencePositionViewViewController.swift
...(工作经验)/C/YHWorkExperiencePositionViewViewController.swift
+6
-2
YHWorkExperienceViewController.swift
...rkExperience(工作经验)/C/YHWorkExperienceViewController.swift
+2
-2
YHWorkExperienceCompanySelectView.swift
...xperience(工作经验)/V/YHWorkExperienceCompanySelectView.swift
+31
-1
YHWorkItemListViewModel.swift
...kExperience(工作经验)/ViewModel/YHWorkItemListViewModel.swift
+2
-2
No files found.
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/QMAS(优才)/ServiceProcess(我的信息流程)/IncomeRecord(收入记录)/C/YHIncomeRecordWorkExperienceViewController.swift
View file @
8c081e1f
...
@@ -497,32 +497,36 @@ extension YHIncomeRecordWorkExperienceViewController: UITableViewDelegate, UITab
...
@@ -497,32 +497,36 @@ extension YHIncomeRecordWorkExperienceViewController: UITableViewDelegate, UITab
extension
YHIncomeRecordWorkExperienceViewController
{
extension
YHIncomeRecordWorkExperienceViewController
{
private
func
checkInput
()
->
Bool
{
private
func
checkInput
()
->
Bool
{
var
retValue
=
true
var
updateRows
:
[
IndexPath
]
=
[]
if
companyModel
.
has_all_file
==
YHIncomeRecordHasAllFile
.
unknown
.
rawValue
{
if
companyModel
.
has_all_file
==
YHIncomeRecordHasAllFile
.
unknown
.
rawValue
{
isHasAllFileOK
=
false
isHasAllFileOK
=
false
if
let
hasAllFileIndexPath
=
hasAllFileIndexPath
,
tableView
.
numberOfSections
>
hasAllFileIndexPath
.
section
,
tableView
.
numberOfRows
(
inSection
:
hasAllFileIndexPath
.
section
)
>
hasAllFileIndexPath
.
row
{
if
let
hasAllFileIndexPath
=
hasAllFileIndexPath
,
tableView
.
numberOfSections
>
hasAllFileIndexPath
.
section
,
tableView
.
numberOfRows
(
inSection
:
hasAllFileIndexPath
.
section
)
>
hasAllFileIndexPath
.
row
{
tableView
.
reloadRows
(
at
:
[
hasAllFileIndexPath
],
with
:
.
none
)
updateRows
.
append
(
hasAllFileIndexPath
)
}
}
ret
urn
false
ret
Value
=
false
}
}
isHasAllFileOK
=
true
if
companyModel
.
income_type
.
count
==
0
{
if
companyModel
.
income_type
.
count
==
0
{
isIncomeTypeOK
=
false
isIncomeTypeOK
=
false
if
let
incomeTypeIndexPath
=
incomeTypeIndexPath
,
tableView
.
numberOfSections
>
incomeTypeIndexPath
.
section
,
tableView
.
numberOfRows
(
inSection
:
incomeTypeIndexPath
.
section
)
>
incomeTypeIndexPath
.
row
{
if
let
incomeTypeIndexPath
=
incomeTypeIndexPath
,
tableView
.
numberOfSections
>
incomeTypeIndexPath
.
section
,
tableView
.
numberOfRows
(
inSection
:
incomeTypeIndexPath
.
section
)
>
incomeTypeIndexPath
.
row
{
tableView
.
reloadRows
(
at
:
[
incomeTypeIndexPath
],
with
:
.
none
)
updateRows
.
append
(
incomeTypeIndexPath
)
}
}
ret
urn
false
ret
Value
=
false
}
}
isIncomeTypeOK
=
true
if
companyModel
.
income_money
==
0
{
if
companyModel
.
income_money
==
0
{
isIncomeMoneyOK
=
false
isIncomeMoneyOK
=
false
if
let
incomMoneyIndexPath
=
incomMoneyIndexPath
,
tableView
.
numberOfSections
>
incomMoneyIndexPath
.
section
,
tableView
.
numberOfRows
(
inSection
:
incomMoneyIndexPath
.
section
)
>
incomMoneyIndexPath
.
row
{
if
let
incomMoneyIndexPath
=
incomMoneyIndexPath
,
tableView
.
numberOfSections
>
incomMoneyIndexPath
.
section
,
tableView
.
numberOfRows
(
inSection
:
incomMoneyIndexPath
.
section
)
>
incomMoneyIndexPath
.
row
{
tableView
.
reloadRows
(
at
:
[
incomMoneyIndexPath
],
with
:
.
none
)
updateRows
.
append
(
incomMoneyIndexPath
)
}
}
return
false
retValue
=
false
}
if
updateRows
.
count
>
0
{
tableView
.
reloadRows
(
at
:
updateRows
,
with
:
.
none
)
isHasAllFileOK
=
true
isIncomeTypeOK
=
true
isIncomeMoneyOK
=
true
}
}
isIncomeMoneyOK
=
true
return
retValue
return
true
}
}
private
func
requestData
(
isNeedLoading
:
Bool
=
false
)
{
private
func
requestData
(
isNeedLoading
:
Bool
=
false
)
{
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/QMAS(优才)/ServiceProcess(我的信息流程)/IncomeRecord(收入记录)/V/YHIncomeInputMoneyCell.swift
View file @
8c081e1f
...
@@ -57,7 +57,7 @@ class YHIncomeInputMoneyCell: YHResignDocumentCell {
...
@@ -57,7 +57,7 @@ class YHIncomeInputMoneyCell: YHResignDocumentCell {
let
label
=
UILabel
()
let
label
=
UILabel
()
label
.
font
=
.
PFSC_R
(
ofSize
:
12
)
label
.
font
=
.
PFSC_R
(
ofSize
:
12
)
label
.
textColor
=
.
failColor
label
.
textColor
=
.
failColor
label
.
text
=
"请
选择
"
label
.
text
=
"请
输入
"
return
label
return
label
}()
}()
...
@@ -110,11 +110,11 @@ class YHIncomeInputMoneyCell: YHResignDocumentCell {
...
@@ -110,11 +110,11 @@ class YHIncomeInputMoneyCell: YHResignDocumentCell {
infoFailLabel
.
isHidden
=
!
needShowFailButton
infoFailLabel
.
isHidden
=
!
needShowFailButton
infoFailLabel
.
snp
.
remakeConstraints
{
make
in
infoFailLabel
.
snp
.
remakeConstraints
{
make
in
if
needShowFailButton
{
if
needShowFailButton
{
make
.
top
.
equalTo
(
info
Detail
Label
.
snp
.
bottom
)
.
offset
(
6
)
make
.
top
.
equalTo
(
info
Title
Label
.
snp
.
bottom
)
.
offset
(
6
)
}
}
make
.
left
.
equalToSuperview
()
.
offset
(
18
)
make
.
left
.
equalToSuperview
()
.
offset
(
18
)
make
.
right
.
lessThanOrEqualToSuperview
()
.
offset
(
-
18
)
make
.
right
.
lessThanOrEqualToSuperview
()
.
offset
(
-
18
)
make
.
bottom
.
e
qualToSuperview
()
.
offset
(
-
16
)
make
.
bottom
.
lessThanOrE
qualToSuperview
()
.
offset
(
-
16
)
}
}
}
}
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/QMAS(优才)/ServiceProcess(我的信息流程)/MainApplicantInformation(主申请人信息)/C/YHMainApplicantInformationViewController.swift
View file @
8c081e1f
...
@@ -187,7 +187,7 @@ extension YHMainApplicantInformationViewController: UITableViewDelegate, UITable
...
@@ -187,7 +187,7 @@ extension YHMainApplicantInformationViewController: UITableViewDelegate, UITable
guard
let
self
=
self
else
{
return
}
guard
let
self
=
self
else
{
return
}
self
.
viewModel
.
updateModel
(
model
)
self
.
viewModel
.
updateModel
(
model
)
let
id
=
model
.
id
let
id
=
model
.
id
if
id
!=
.
id32
&&
id
!=
.
id4
&&
id
!=
.
id8
&&
id
!=
.
id9
&&
id
!=
.
id12
&&
id
!=
.
id13
&&
id
!=
.
id17
&&
id
!=
.
id18
&&
id
!=
.
id21
&&
id
!=
.
id22
&&
id
!=
.
id23
&&
id
!=
.
id34
&&
id
!=
.
id29
&&
id
!=
.
id30
&&
id
!=
.
id35
{
if
id
!=
.
id32
&&
id
!=
.
id4
&&
id
!=
.
id8
&&
id
!=
.
id9
&&
id
!=
.
id12
&&
id
!=
.
id13
&&
id
!=
.
id17
&&
id
!=
.
id18
&&
id
!=
.
id21
&&
id
!=
.
id22
&&
id
!=
.
id23
&&
id
!=
.
id
26
&&
id
!=
.
id
34
&&
id
!=
.
id29
&&
id
!=
.
id30
&&
id
!=
.
id35
{
self
.
updateDataSource
()
self
.
updateDataSource
()
}
}
}
}
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/QMAS(优才)/ServiceProcess(我的信息流程)/MainApplicantInformation(主申请人信息)/VM/YHMainApplicantInformationViewModel.swift
View file @
8c081e1f
...
@@ -112,9 +112,9 @@ class YHMainApplicantInformationViewModel: YHBaseViewModel {
...
@@ -112,9 +112,9 @@ class YHMainApplicantInformationViewModel: YHBaseViewModel {
let
section2
=
YHSectionItemModel
(
title
:
section3String
,
models
:
[
item5
,
item6
,
item7
,
item8
])
let
section2
=
YHSectionItemModel
(
title
:
section3String
,
models
:
[
item5
,
item6
,
item7
,
item8
])
let
addressCountry
=
mainModel
.
address
.
country
let
addressCountry
=
mainModel
.
address
.
country
if
(
nationality
.
contains
(
"中国
"
)
&&
addressCountry
.
contains
(
"中国"
))
||
(
nationality
.
contains
(
"中国
"
)
&&
is_live_oversea_year
==
0
)
{
if
(
nationality
.
contains
(
"中国
-China"
)
&&
addressCountry
.
contains
(
"中国-China"
))
||
(
nationality
.
contains
(
"中国-China
"
)
&&
is_live_oversea_year
==
0
)
{
return
[
section
,
section1
]
return
[
section
,
section1
]
}
else
if
nationality
.
contains
(
"中国"
)
&&
is_live_oversea_year
==
1
{
}
else
if
nationality
.
contains
(
"中国
-China
"
)
&&
is_live_oversea_year
==
1
{
return
[
section
,
section2
]
return
[
section
,
section2
]
}
else
{
}
else
{
return
[
section2
]
return
[
section2
]
...
@@ -158,13 +158,13 @@ class YHMainApplicantInformationViewModel: YHBaseViewModel {
...
@@ -158,13 +158,13 @@ class YHMainApplicantInformationViewModel: YHBaseViewModel {
let
addressCountry
=
mainModel
.
address
.
country
let
addressCountry
=
mainModel
.
address
.
country
let
nationality
=
mainModel
.
nationality
let
nationality
=
mainModel
.
nationality
let
is_live_oversea_year
=
mainModel
.
is_live_oversea_year
let
is_live_oversea_year
=
mainModel
.
is_live_oversea_year
if
(
nationality
.
contains
(
"中国
-China"
)
&&
addressCountry
.
contains
(
"中国-China"
))
||
(
nationality
.
contains
(
"中国-China
"
)
&&
is_live_oversea_year
==
0
)
{
if
(
nationality
.
contains
(
"中国
"
)
&&
addressCountry
.
contains
(
"中国"
))
||
(
nationality
.
contains
(
"中国
"
)
&&
is_live_oversea_year
==
0
)
{
if
mainModel
.
is_handled
==
1
{
if
mainModel
.
is_handled
==
1
{
return
[
section
,
section1
]
return
[
section
,
section1
]
}
else
{
}
else
{
return
[
section
]
return
[
section
]
}
}
}
else
if
nationality
.
contains
(
"中国
-China
"
)
&&
is_live_oversea_year
==
1
{
}
else
if
nationality
.
contains
(
"中国"
)
&&
is_live_oversea_year
==
1
{
return
[
section
,
section2
]
return
[
section
,
section2
]
}
else
{
}
else
{
return
[
section2
]
return
[
section2
]
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/QMAS(优才)/ServiceProcess(我的信息流程)/PersonInfoList(个人信息预览)/M/YHWorkExpInfoPreviewModel.swift
View file @
8c081e1f
...
@@ -32,6 +32,7 @@ class YHWorkExpInfoPreviewDetail_NewModel : SmartCodable {
...
@@ -32,6 +32,7 @@ class YHWorkExpInfoPreviewDetail_NewModel : SmartCodable {
var
professional_level
:
String
=
""
var
professional_level
:
String
=
""
var
work_duty
:
String
=
""
var
work_duty
:
String
=
""
var
work_highlights
:
String
=
""
var
work_highlights
:
String
=
""
var
company_location
:
String
=
""
var
attachment_list
:
[
WorkExpFilePreviewModel
]
=
[]
var
attachment_list
:
[
WorkExpFilePreviewModel
]
=
[]
var
position_list
:
[
YHWorkExpPosition_NewModel
]
=
[]
var
position_list
:
[
YHWorkExpPosition_NewModel
]
=
[]
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/QMAS(优才)/ServiceProcess(我的信息流程)/PersonInfoList(个人信息预览)/V/YHPreviewInfoNameAndSubNameItemView.swift
View file @
8c081e1f
...
@@ -42,10 +42,10 @@ class YHPreviewInfoNameAndSubNameItemView: UIView {
...
@@ -42,10 +42,10 @@ class YHPreviewInfoNameAndSubNameItemView: UIView {
nameLable
.
snp
.
makeConstraints
{
make
in
nameLable
.
snp
.
makeConstraints
{
make
in
make
.
top
.
equalToSuperview
()
.
offset
(
18
)
make
.
top
.
equalToSuperview
()
.
offset
(
18
)
make
.
left
.
equalToSuperview
()
make
.
left
.
equalToSuperview
()
make
.
width
.
lessThanOrEqualTo
(
154
)
//
make.width.lessThanOrEqualTo(154)
make
.
height
.
equalTo
(
20
)
make
.
height
.
equalTo
(
20
)
}
}
nameLable
.
setContentCompressionResistancePriority
(
.
required
,
for
:
.
horizontal
)
addSubview
(
subtitleLable
)
addSubview
(
subtitleLable
)
subtitleLable
.
snp
.
makeConstraints
{
make
in
subtitleLable
.
snp
.
makeConstraints
{
make
in
...
@@ -56,6 +56,9 @@ class YHPreviewInfoNameAndSubNameItemView: UIView {
...
@@ -56,6 +56,9 @@ class YHPreviewInfoNameAndSubNameItemView: UIView {
make
.
bottom
.
equalToSuperview
()
make
.
bottom
.
equalToSuperview
()
}
}
nameLable
.
setContentCompressionResistancePriority
(
.
required
,
for
:
.
horizontal
)
subtitleLable
.
setContentCompressionResistancePriority
(
.
defaultLow
,
for
:
.
horizontal
)
}
}
}
}
...
@@ -65,22 +68,22 @@ extension YHPreviewInfoNameAndSubNameItemView {
...
@@ -65,22 +68,22 @@ extension YHPreviewInfoNameAndSubNameItemView {
subtitleLable
.
text
=
subtitle
subtitleLable
.
text
=
subtitle
//处理特长的字符
//处理特长的字符
if
title
.
contains
(
"相关工作是否属国际工作经验:"
)
||
title
.
contains
(
"公司营业额/港元(近一年):"
)
||
title
.
contains
(
"是否在海外居住满1年及以上:"
)
{
//
if title.contains("相关工作是否属国际工作经验:") || title.contains("公司营业额/港元(近一年):") || title.contains("是否在海外居住满1年及以上:") {
nameLable
.
snp
.
remakeConstraints
{
make
in
//
nameLable.snp.remakeConstraints { make in
make
.
top
.
equalToSuperview
()
.
offset
(
18
)
//
make.top.equalToSuperview().offset(18)
make
.
left
.
equalToSuperview
()
//
make.left.equalToSuperview()
make
.
width
.
lessThanOrEqualTo
(
240
)
//
make.width.lessThanOrEqualTo(240)
make
.
height
.
equalTo
(
20
)
//
make.height.equalTo(20)
}
//
}
nameLable
.
setContentCompressionResistancePriority
(
.
required
,
for
:
.
horizontal
)
//
nameLable.setContentCompressionResistancePriority(.required, for: .horizontal)
}
else
if
title
.
contains
(
"主申请人或现配偶是否拥有孩子护养权:"
)
{
//
} else if title.contains("主申请人或现配偶是否拥有孩子护养权:") {
nameLable
.
snp
.
remakeConstraints
{
make
in
//
nameLable.snp.remakeConstraints { make in
make
.
top
.
equalToSuperview
()
.
offset
(
18
)
//
make.top.equalToSuperview().offset(18)
make
.
left
.
equalToSuperview
()
//
make.left.equalToSuperview()
make
.
width
.
lessThanOrEqualTo
(
260
)
//
make.width.lessThanOrEqualTo(260)
make
.
height
.
equalTo
(
20
)
//
make.height.equalTo(20)
}
//
}
}
//
}
}
}
}
}
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/QMAS(优才)/ServiceProcess(我的信息流程)/PersonInfoList(个人信息预览)/VM/YHPreviewViewModel.swift
View file @
8c081e1f
...
@@ -8,6 +8,13 @@
...
@@ -8,6 +8,13 @@
import
UIKit
import
UIKit
enum
YHCerPhotoInfoType
:
Int
{
case
none
=
0
case
idCard
=
1
case
hkPassPort
=
2
case
passPort
=
3
}
class
YHPreviewViewModel
:
YHBaseViewModel
{
class
YHPreviewViewModel
:
YHBaseViewModel
{
//工作经验
//工作经验
var
workExpInfoPreviewModel
:
YHWorkExpInfoPreviewModel
?
var
workExpInfoPreviewModel
:
YHWorkExpInfoPreviewModel
?
...
@@ -254,6 +261,17 @@ private extension YHPreviewViewModel {
...
@@ -254,6 +261,17 @@ private extension YHPreviewViewModel {
if
model
.
is_ipo_company
{
if
model
.
is_ipo_company
{
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"您是否拥有此公司所有权(10%以上股权):"
,
answer
:
model
.
has_ipo_company_equity
?
"是"
:
"否"
)
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"您是否拥有此公司所有权(10%以上股权):"
,
answer
:
model
.
has_ipo_company_equity
?
"是"
:
"否"
)
arr1
.
append
(
tmp2
)
arr1
.
append
(
tmp2
)
if
model
.
has_ipo_company_equity
{
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"公司全年盈利达港币 500 万元或以上(或等值外币):"
,
answer
:
model
.
has_ipo_sales_reached
?
"是"
:
"否"
)
arr1
.
append
(
tmp2
)
if
model
.
has_ipo_sales_reached
{
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"您的公司所在地:"
,
answer
:
model
.
company_location
.
defaultStringIfEmpty
())
arr1
.
append
(
tmp2
)
}
}
}
else
{
}
else
{
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"您是否拥有此公司所有权(50%以上股权):"
,
answer
:
model
.
has_company_equity
?
"是"
:
"否"
)
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"您是否拥有此公司所有权(50%以上股权):"
,
answer
:
model
.
has_company_equity
?
"是"
:
"否"
)
...
@@ -265,7 +283,7 @@ private extension YHPreviewViewModel {
...
@@ -265,7 +283,7 @@ private extension YHPreviewViewModel {
}
}
if
model
.
has_sales_reached
{
if
model
.
has_sales_reached
{
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"您的公司所在地:"
,
answer
:
"缺少地址字段"
)
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"您的公司所在地:"
,
answer
:
model
.
company_location
.
defaultStringIfEmpty
()
)
arr1
.
append
(
tmp2
)
arr1
.
append
(
tmp2
)
}
}
...
@@ -274,7 +292,11 @@ private extension YHPreviewViewModel {
...
@@ -274,7 +292,11 @@ private extension YHPreviewViewModel {
let
tmp7
=
YHPreviewQuestionAndAnswerModel
(
question
:
"入职年月:"
,
answer
:
model
.
enter_time
)
let
tmp7
=
YHPreviewQuestionAndAnswerModel
(
question
:
"入职年月:"
,
answer
:
model
.
enter_time
)
let
tmp8
=
YHPreviewQuestionAndAnswerModel
(
question
:
"离职年月:"
,
answer
:
model
.
leave_time
)
let
tmp8
=
YHPreviewQuestionAndAnswerModel
(
question
:
"离职年月:"
,
answer
:
model
.
leave_time
)
let
tmp9
=
YHPreviewQuestionAndAnswerModel
(
question
:
"工作证明文件:"
,
answer
:
model
.
work_certificate
)
let
tmp9
=
YHPreviewQuestionAndAnswerModel
(
question
:
"工作证明文件:"
,
answer
:
model
.
work_certificate
)
let
tmp10
=
YHPreviewQuestionAndAnswerModel
(
question
:
"职位水平类别:"
,
answer
:
model
.
professional_level
)
let
tempppp0
=
YHConstantArrayData
.
getShowNameBy
(
indexStr
:
String
(
model
.
professional_level
),
type
:
.
level
)
let
tmp10
=
YHPreviewQuestionAndAnswerModel
(
question
:
"职位水平类别:"
,
answer
:
tempppp0
)
arr1
.
append
(
contentsOf
:
[
tmp7
,
tmp8
,
tmp9
,
tmp10
])
arr1
.
append
(
contentsOf
:
[
tmp7
,
tmp8
,
tmp9
,
tmp10
])
}
}
...
@@ -293,7 +315,7 @@ private extension YHPreviewViewModel {
...
@@ -293,7 +315,7 @@ private extension YHPreviewViewModel {
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"职责性质:"
,
answer
:
item
.
wduty
.
defaultStringIfEmpty
())
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"职责性质:"
,
answer
:
item
.
wduty
.
defaultStringIfEmpty
())
let
tmp3
=
YHPreviewQuestionAndAnswerModel
(
question
:
"开始就职年月:"
,
answer
:
item
.
entry_time
.
defaultStringIfEmpty
())
let
tmp3
=
YHPreviewQuestionAndAnswerModel
(
question
:
"开始就职年月:"
,
answer
:
item
.
entry_time
.
defaultStringIfEmpty
())
let
tmp4
=
YHPreviewQuestionAndAnswerModel
(
question
:
"结束就职年月:"
,
answer
:
item
.
departure_time
.
defaultStringIfEmpty
())
let
tmp4
=
YHPreviewQuestionAndAnswerModel
(
question
:
"结束就职年月:"
,
answer
:
item
.
departure_time
.
defaultStringIfEmpty
())
let
ttt
=
item
.
experience_scope
+
"、"
+
item
.
experience_sub_scope
let
ttt
=
item
.
experience_scope
+
(
item
.
experience_sub_scope
.
isEmpty
?
""
:
(
"-"
+
item
.
experience_sub_scope
))
let
tmp5
=
YHPreviewQuestionAndAnswerModel
(
question
:
"经验领域:"
,
answer
:
ttt
)
let
tmp5
=
YHPreviewQuestionAndAnswerModel
(
question
:
"经验领域:"
,
answer
:
ttt
)
let
tmp6
=
YHPreviewQuestionAndAnswerModel
(
question
:
"相关工作是否属国际工作经验:"
,
answer
:
item
.
is_international_work_experience
?
"是"
:
"否"
)
let
tmp6
=
YHPreviewQuestionAndAnswerModel
(
question
:
"相关工作是否属国际工作经验:"
,
answer
:
item
.
is_international_work_experience
?
"是"
:
"否"
)
let
place
=
item
.
work_country
+
"-"
+
item
.
work_city
let
place
=
item
.
work_country
+
"-"
+
item
.
work_city
...
@@ -489,17 +511,17 @@ private extension YHPreviewViewModel {
...
@@ -489,17 +511,17 @@ private extension YHPreviewViewModel {
var
title
=
""
var
title
=
""
if
let
item
=
model
.
school_address
{
if
let
item
=
model
.
school_address
{
if
item
.
country
.
contains
(
"中国"
)
{
if
item
.
country
.
contains
(
"中国"
)
{
title
=
"
国内
"
title
=
""
if
item
.
area
.
count
>
1
{
if
item
.
area
.
count
>
1
{
title
=
title
+
item
.
area
[
0
]
+
"/"
+
item
.
area
[
1
]
title
=
title
+
item
.
area
[
0
]
+
"/"
+
item
.
area
[
1
]
}
}
}
else
{
}
else
{
title
=
"国外 "
+
item
.
country
+
"-"
+
item
.
foreign
title
=
item
.
country
+
"-"
+
item
.
foreign
}
}
}
else
{
}
else
{
title
=
"--"
title
=
"--"
}
}
let
tmp7
=
YHPreviewQuestionAndAnswerModel
(
question
:
"上课
地点
:"
,
answer
:
title
)
let
tmp7
=
YHPreviewQuestionAndAnswerModel
(
question
:
"上课
城市
:"
,
answer
:
title
)
let
arr
=
[
tmp5
,
tmp0
,
tmp1
,
tmp2
,
tmp3
,
tmp4
,
tmp7
]
let
arr
=
[
tmp5
,
tmp0
,
tmp1
,
tmp2
,
tmp3
,
tmp4
,
tmp7
]
...
@@ -575,7 +597,7 @@ private extension YHPreviewViewModel {
...
@@ -575,7 +597,7 @@ private extension YHPreviewViewModel {
let
tmp1
=
YHPreviewQuestionAndAnswerModel
(
question
:
"曾用名:"
,
answer
:
model
.
used_name
.
defaultStringIfEmpty
())
let
tmp1
=
YHPreviewQuestionAndAnswerModel
(
question
:
"曾用名:"
,
answer
:
model
.
used_name
.
defaultStringIfEmpty
())
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"婚前姓氏:"
,
answer
:
model
.
surname
.
defaultStringIfEmpty
())
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"婚前姓氏:"
,
answer
:
model
.
surname
.
defaultStringIfEmpty
())
let
tmp3
=
YHPreviewQuestionAndAnswerModel
(
question
:
"出生日期:"
,
answer
:
model
.
birthday
)
let
tmp3
=
YHPreviewQuestionAndAnswerModel
(
question
:
"出生日期:"
,
answer
:
model
.
birthday
)
let
tmp4
=
YHPreviewQuestionAndAnswerModel
(
question
:
"出生城市:"
,
answer
:
model
.
birth_place
)
let
tmp4
=
YHPreviewQuestionAndAnswerModel
(
question
:
"出生城市:"
,
answer
:
model
.
birth_place
_details
)
var
msg
=
model
.
sex
//后台 王辉维护这个字段 前端直接展示
var
msg
=
model
.
sex
//后台 王辉维护这个字段 前端直接展示
let
tmp5
=
YHPreviewQuestionAndAnswerModel
(
question
:
"性别:"
,
answer
:
msg
)
let
tmp5
=
YHPreviewQuestionAndAnswerModel
(
question
:
"性别:"
,
answer
:
msg
)
...
@@ -754,6 +776,22 @@ private extension YHPreviewViewModel {
...
@@ -754,6 +776,22 @@ private extension YHPreviewViewModel {
}
}
do
{
//配偶
if
let
model
=
basiceInfoPreviewModel
?
.
spouse
{
let
answer0
=
model
.
child_departure
?
.
has
==
"Y"
?
"是"
:
"否"
let
remark0
=
answer0
==
"是"
?
(
model
.
child_departure
?
.
info
??
""
)
:
nil
let
tmp0
=
YHPreviewQuestionAndAnswerModel
(
question
:
"1、是否曾被拒绝入境/递解/遣送或要求离开香港?"
,
answer
:
answer0
,
remark
:
remark0
)
let
answer1
=
model
.
child_deny
?
.
has
==
"Y"
?
"是"
:
"否"
let
remark1
=
answer1
==
"是"
?
(
model
.
child_deny
?
.
info
??
""
)
:
nil
let
tmp1
=
YHPreviewQuestionAndAnswerModel
(
question
:
"2、是否曾被拒绝签发签证/进入许可以入境香港?"
,
answer
:
answer1
,
remark
:
remark1
)
let
arr
=
[
tmp0
,
tmp1
]
let
model1
=
YHPreviewInfoSessionModel
(
cellType
:
.
questionAndAnswer
,
cellTitle
:
"配偶"
,
cellData0
:
arr
)
arrDataForBasicInfo
.
append
(
model1
)
}
}
do
{
do
{
//子女 - xxx
//子女 - xxx
if
let
arrChild
=
basiceInfoPreviewModel
?
.
child
{
if
let
arrChild
=
basiceInfoPreviewModel
?
.
child
{
...
@@ -777,24 +815,6 @@ private extension YHPreviewViewModel {
...
@@ -777,24 +815,6 @@ private extension YHPreviewViewModel {
}
}
}
}
do
{
//配偶
if
let
model
=
basiceInfoPreviewModel
?
.
spouse
{
let
answer0
=
model
.
child_departure
?
.
has
==
"Y"
?
"是"
:
"否"
let
remark0
=
answer0
==
"是"
?
(
model
.
child_departure
?
.
info
??
""
)
:
nil
let
tmp0
=
YHPreviewQuestionAndAnswerModel
(
question
:
"1、是否曾被拒绝入境/递解/遣送或要求离开香港?"
,
answer
:
answer0
,
remark
:
remark0
)
let
answer1
=
model
.
child_deny
?
.
has
==
"Y"
?
"是"
:
"否"
let
remark1
=
answer1
==
"是"
?
(
model
.
child_deny
?
.
info
??
""
)
:
nil
let
tmp1
=
YHPreviewQuestionAndAnswerModel
(
question
:
"2、是否曾被拒绝签发签证/进入许可以入境香港?"
,
answer
:
answer1
,
remark
:
remark1
)
let
arr
=
[
tmp0
,
tmp1
]
let
model1
=
YHPreviewInfoSessionModel
(
cellType
:
.
questionAndAnswer
,
cellTitle
:
"配偶"
,
cellData0
:
arr
)
arrDataForBasicInfo
.
append
(
model1
)
}
}
do
{
do
{
//家庭背景
//家庭背景
if
let
model
=
basiceInfoPreviewModel
?
.
background
{
if
let
model
=
basiceInfoPreviewModel
?
.
background
{
...
@@ -1287,13 +1307,10 @@ private extension YHPreviewViewModel {
...
@@ -1287,13 +1307,10 @@ private extension YHPreviewViewModel {
let
tmp12
=
YHPreviewQuestionAndAnswerModel
(
question
:
"是否在海外居住满1年及以上:"
,
answer
:
title
)
let
tmp12
=
YHPreviewQuestionAndAnswerModel
(
question
:
"是否在海外居住满1年及以上:"
,
answer
:
title
)
arr
.
append
(
tmp12
)
arr
.
append
(
tmp12
)
}
}
let
tmp133
=
YHPreviewQuestionAndAnswerModel
(
question
:
"详细地址:"
,
answer
:
address
.
defaultStringIfEmpty
())
let
tmp133
=
YHPreviewQuestionAndAnswerModel
(
question
:
"详细地址:"
,
answer
:
address
.
defaultStringIfEmpty
())
arr
.
append
(
tmp133
)
arr
.
append
(
tmp133
)
let
tmp13
=
YHPreviewQuestionAndAnswerModel
(
question
:
"目前是否在港:"
,
answer
:
model
.
hkIdentity
.
isEmpty
==
false
?
"是"
:
"否"
)
arr
.
append
(
tmp13
)
let
isHKIdCardHandled
=
model
.
isHaveHKIdentityCard
()
let
isHKIdCardHandled
=
model
.
isHaveHKIdentityCard
()
let
isHKIdCardHandledString
=
isHKIdCardHandled
?
"是"
:
"否"
let
isHKIdCardHandledString
=
isHKIdCardHandled
?
"是"
:
"否"
let
tmp14
=
YHPreviewQuestionAndAnswerModel
(
question
:
"是否办理过香港身份证:"
,
answer
:
isHKIdCardHandledString
)
let
tmp14
=
YHPreviewQuestionAndAnswerModel
(
question
:
"是否办理过香港身份证:"
,
answer
:
isHKIdCardHandledString
)
...
@@ -1352,85 +1369,90 @@ private extension YHPreviewViewModel {
...
@@ -1352,85 +1369,90 @@ private extension YHPreviewViewModel {
}
}
}
}
if
model
.
isFollow
()
{
// 证件信息显示逻辑
//1.跟随 证件信息
var
cerInfoArr
=
[
YHPersonInfoCellModel1
]()
do
{
let
a
=
showCerInfoLogic
(
familyMember
:
model
,
mainApplicantInfo
:
mainApplicant
)
var
arr
=
[
YHPersonInfoCellModel1
]()
let
isNeedShowHK
=
a
.
showHK
//港澳通行证
let
isNeedShowPassport
=
a
.
showPassport
if
model
.
isHandled
==
1
{
var
str
=
model
.
certificates
.
hkMacaoPass
.
number
if
isNeedShowHK
{
let
tmp4
=
YHPreviewQuestionAndAnswerModel
(
question
:
"旅行社证件号码:"
,
answer
:
str
.
defaultStringIfEmpty
())
var
str
=
model
.
certificates
.
hkMacaoPass
.
number
str
=
model
.
certificates
.
hkMacaoPass
.
issueAt
let
tmp4
=
YHPreviewQuestionAndAnswerModel
(
question
:
"旅行社证件号码:"
,
answer
:
str
.
defaultStringIfEmpty
())
let
tmp5
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发地:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
hkMacaoPass
.
issueAt
str
=
model
.
certificates
.
hkMacaoPass
.
issueDateStartAt
let
tmp5
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发地:"
,
answer
:
str
.
defaultStringIfEmpty
())
let
tmp6
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
hkMacaoPass
.
issueDateStartAt
str
=
model
.
certificates
.
hkMacaoPass
.
issueDateEndAt
let
tmp6
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
if
str
.
isEmpty
{
str
=
""
str
=
model
.
certificates
.
hkMacaoPass
.
issueDateEndAt
}
else
{
if
str
.
isEmpty
{
if
str
==
"8888-01-01"
{
str
=
""
str
=
"长期"
}
else
{
}
if
str
==
"8888-01-01"
{
}
str
=
"长期"
let
tmp7
=
YHPreviewQuestionAndAnswerModel
(
question
:
"届满日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
let
model1
=
YHPersonInfoCellModel1
(
cellTitle
:
"港澳通行证"
,
cellData
:
[
tmp4
,
tmp5
,
tmp6
,
tmp7
])
arr
.
append
(
model1
)
}
if
model
.
nationality
!=
"中国-China"
{
//护照及其他旅行证件
var
str
=
YHConstantArrayData
.
getShowNameBy
(
indexStr
:
String
(
model
.
certificates
.
passport
.
passPortType
),
type
:
.
idType
)
let
tmp8
=
YHPreviewQuestionAndAnswerModel
(
question
:
"证件类别:"
,
answer
:
str
)
str
=
model
.
certificates
.
passport
.
number
let
tmp9
=
YHPreviewQuestionAndAnswerModel
(
question
:
"证件号码:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
passport
.
issueAt
let
tmp10
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发地:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
passport
.
issueDateStartAt
let
tmp11
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
passport
.
issueDateEndAt
if
str
.
isEmpty
{
str
=
""
}
else
{
if
str
==
"8888-01-01"
{
str
=
"长期"
}
}
let
tmp12
=
YHPreviewQuestionAndAnswerModel
(
question
:
"届满日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
let
model2
=
YHPersonInfoCellModel1
(
cellTitle
:
"护照及其他旅行证件"
,
cellData
:
[
tmp8
,
tmp9
,
tmp10
,
tmp11
,
tmp12
])
arr
.
append
(
model2
)
}
}
let
model3
=
YHPreviewInfoSessionModel
(
cellType
:
.
idCardInfoType
,
cellTitle
:
"证件信息"
,
cellData1
:
arr
)
arrTemp
.
append
(
model3
)
}
}
let
tmp7
=
YHPreviewQuestionAndAnswerModel
(
question
:
"届满日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
let
model1
=
YHPersonInfoCellModel1
(
cellTitle
:
"港澳通行证"
,
cellData
:
[
tmp4
,
tmp5
,
tmp6
,
tmp7
])
cerInfoArr
.
append
(
model1
)
}
if
isNeedShowPassport
{
//护照及其他旅行证件
//2.跟随 证件照
var
str
=
model
.
certificates
.
passport
.
number
do
{
let
tmp9
=
YHPreviewQuestionAndAnswerModel
(
question
:
"证件号码:"
,
answer
:
str
.
defaultStringIfEmpty
())
//证件照片
str
=
model
.
certificates
.
passport
.
issueAt
let
tmp10
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发地:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
passport
.
issueDateStartAt
let
tmp11
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
passport
.
issueDateEndAt
if
str
.
isEmpty
{
str
=
""
}
else
{
if
str
==
"8888-01-01"
{
str
=
"长期"
}
}
let
tmp12
=
YHPreviewQuestionAndAnswerModel
(
question
:
"届满日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
let
model2
=
YHPersonInfoCellModel1
(
cellTitle
:
"护照及其他旅行证件"
,
cellData
:
[
tmp9
,
tmp10
,
tmp11
,
tmp12
])
cerInfoArr
.
append
(
model2
)
}
let
model3
=
YHPreviewInfoSessionModel
(
cellType
:
.
idCardInfoType
,
cellTitle
:
"证件信息"
,
cellData1
:
cerInfoArr
)
arrTemp
.
append
(
model3
)
// 证件照片显示逻辑
let
cerPhotoArr
=
showCerPhotoLogic
(
familyMember
:
model
,
mainApplicantInfo
:
mainApplicant
)
var
photoArr
=
[
YHPersonInfoCellModel2
]()
for
cerType
in
cerPhotoArr
{
if
cerType
==
.
idCard
{
let
front
=
model
.
certificates
.
cnIdentityCard
.
imgFront
let
front
=
model
.
certificates
.
cnIdentityCard
.
imgFront
let
back
=
model
.
certificates
.
cnIdentityCard
.
imgBack
let
back
=
model
.
certificates
.
cnIdentityCard
.
imgBack
let
model1
=
YHPersonInfoCellModel2
(
cellTitle
:
"中国身份证"
,
frontUrl
:
front
,
backUrl
:
back
,
idType
:
1
)
let
model1
=
YHPersonInfoCellModel2
(
cellTitle
:
"中国身份证"
,
frontUrl
:
front
,
backUrl
:
back
,
idType
:
1
)
var
arr
=
[
model1
]
photoArr
.
append
(
model1
)
if
model
.
isHandled
==
1
{
}
else
if
cerType
==
.
hkPassPort
{
let
front
=
model
.
certificates
.
hkMacaoPass
.
imgFront
let
front
=
model
.
certificates
.
hkMacaoPass
.
imgFront
let
back
=
model
.
certificates
.
hkMacaoPass
.
imgBack
let
back
=
model
.
certificates
.
hkMacaoPass
.
imgBack
let
model2
=
YHPersonInfoCellModel2
(
cellTitle
:
"港澳通行证"
,
frontUrl
:
front
,
backUrl
:
back
,
idType
:
2
)
let
model2
=
YHPersonInfoCellModel2
(
cellTitle
:
"港澳通行证"
,
frontUrl
:
front
,
backUrl
:
back
,
idType
:
2
)
a
rr
.
append
(
model2
)
photoA
rr
.
append
(
model2
)
}
let
model4
=
YHPreviewInfoSessionModel
(
cellType
:
.
idPictureType
,
cellTitle
:
"证件照片"
,
cellData2
:
arr
)
}
else
if
cerType
==
.
passPort
{
arrTemp
.
append
(
model4
)
let
front
=
model
.
certificates
.
passport
.
imgFront
let
back
=
model
.
certificates
.
passport
.
imgBack
let
model3
=
YHPersonInfoCellModel2
(
cellTitle
:
"护照"
,
frontUrl
:
front
,
backUrl
:
back
,
idType
:
3
)
photoArr
.
append
(
model3
)
}
}
}
}
let
model4
=
YHPreviewInfoSessionModel
(
cellType
:
.
idPictureType
,
cellTitle
:
"证件照片"
,
cellData2
:
photoArr
)
arrTemp
.
append
(
model4
)
arrDataForSpouse
=
arrTemp
arrDataForSpouse
=
arrTemp
}
}
...
@@ -1481,16 +1503,12 @@ private extension YHPreviewViewModel {
...
@@ -1481,16 +1503,12 @@ private extension YHPreviewViewModel {
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"婚前姓氏:"
,
answer
:
model
.
surname
.
defaultStringIfEmpty
())
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"婚前姓氏:"
,
answer
:
model
.
surname
.
defaultStringIfEmpty
())
let
sexStr
=
YHConstantArrayData
.
getShowNameBy
(
indexStr
:
String
(
model
.
sex
),
type
:
.
sex
)
let
sexStr
=
YHConstantArrayData
.
getShowNameBy
(
indexStr
:
String
(
model
.
sex
),
type
:
.
sex
)
let
tmp22
=
YHPreviewQuestionAndAnswerModel
(
question
:
"性别:"
,
answer
:
sexStr
)
let
tmp3
=
YHPreviewQuestionAndAnswerModel
(
question
:
"出生日期:"
,
answer
:
model
.
birthday
)
let
tmp3
=
YHPreviewQuestionAndAnswerModel
(
question
:
"出生日期:"
,
answer
:
model
.
birthday
)
var
city
=
""
var
city
=
""
if
model
.
birthPlaceAboard
==
0
{
if
model
.
birthPlaceAboard
==
0
{
//国内
//国内
if
model
.
birthPlace
.
area
.
count
>
1
{
city
=
"国内 "
+
model
.
birthPlace
.
details
city
=
"国内 "
+
model
.
birthPlace
.
area
[
0
]
+
"/"
+
model
.
birthPlace
.
area
[
1
]
}
else
{
city
=
"国内 --"
}
}
else
{
}
else
{
//国外
//国外
city
=
"国外 "
+
model
.
birthPlace
.
foreign
city
=
"国外 "
+
model
.
birthPlace
.
foreign
...
@@ -1498,29 +1516,8 @@ private extension YHPreviewViewModel {
...
@@ -1498,29 +1516,8 @@ private extension YHPreviewViewModel {
let
tmp4
=
YHPreviewQuestionAndAnswerModel
(
question
:
"出生城市:"
,
answer
:
city
)
let
tmp4
=
YHPreviewQuestionAndAnswerModel
(
question
:
"出生城市:"
,
answer
:
city
)
let
tmp5
=
YHPreviewQuestionAndAnswerModel
(
question
:
"婚姻状况:"
,
answer
:
model
.
married
)
let
tmp5
=
YHPreviewQuestionAndAnswerModel
(
question
:
"婚姻状况:"
,
answer
:
model
.
married
)
var
arr
:[
YHPreviewQuestionAndAnswerModel
]
=
[
tmp0
,
tmp1
,
tmp2
,
tmp3
,
tmp4
,
tmp5
]
let
tmp55
=
YHPreviewQuestionAndAnswerModel
(
question
:
"职业:"
,
answer
:
model
.
occupation
)
var
arr
=
[
tmp0
,
tmp1
,
tmp2
,
tmp22
,
tmp3
,
tmp4
,
tmp5
,
tmp55
]
if
model
.
occupation
.
contains
(
"在职"
)
{
let
tmp5
=
YHPreviewQuestionAndAnswerModel
(
question
:
"职业名称:"
,
answer
:
model
.
occupationName
)
arr
.
append
(
tmp5
)
}
// let tmp7 = YHPreviewQuestionAndAnswerModel(question: "是否拥有学位:", answer: model.hasDegree == "1" ? "有学位" : "无学位")
// arr.append(tmp7)
//
// if model.hasDegree == "1" {
// for(index,item) in model.hasDegreeJson.enumerated() {
//
// let addationIndex = model.hasDegreeJson.count > 1 ? String(index + 1) : ""
// let title = "学位证" + addationIndex + ":"
// let tmp8 = YHPreviewQuestionAndAnswerModel(question: title, answer: item.degree)
// arr.append(tmp8)
// let tmp9 = YHPreviewQuestionAndAnswerModel(question: "学位证颁发地区:", answer: item.address)
// arr.append(tmp9)
// }
// }
let
tmp10
=
YHPreviewQuestionAndAnswerModel
(
question
:
"是否和主申请人同住:"
,
answer
:
model
.
nows
==
1
?
"是"
:
"否"
)
let
tmp10
=
YHPreviewQuestionAndAnswerModel
(
question
:
"是否和主申请人同住:"
,
answer
:
model
.
nows
==
1
?
"是"
:
"否"
)
arr
.
append
(
tmp10
)
arr
.
append
(
tmp10
)
...
@@ -1554,21 +1551,17 @@ private extension YHPreviewViewModel {
...
@@ -1554,21 +1551,17 @@ private extension YHPreviewViewModel {
arr
.
append
(
tmp12
)
arr
.
append
(
tmp12
)
}
}
if
true
{
let
title
=
model
.
isPreviousMarriageChild
()
?
"是"
:
"否"
let
tmp12
=
YHPreviewQuestionAndAnswerModel
(
question
:
"是否为前次婚姻的子女"
,
answer
:
title
)
arr
.
append
(
tmp12
)
}
if
model
.
nows
==
0
{
if
model
.
nows
==
0
{
let
tmp133
=
YHPreviewQuestionAndAnswerModel
(
question
:
"详细地址:"
,
answer
:
address
.
defaultStringIfEmpty
())
let
tmp133
=
YHPreviewQuestionAndAnswerModel
(
question
:
"详细地址:"
,
answer
:
address
.
defaultStringIfEmpty
())
arr
.
append
(
tmp133
)
arr
.
append
(
tmp133
)
}
}
let
tmp13
=
YHPreviewQuestionAndAnswerModel
(
question
:
"目前是否在港:"
,
answer
:
model
.
hkIdentity
.
isEmpty
==
false
?
"是"
:
"否"
)
arr
.
append
(
tmp13
)
if
model
.
hkIdentity
.
isEmpty
==
false
{
let
tmp14
=
YHPreviewQuestionAndAnswerModel
(
question
:
"获准逗留至:"
,
answer
:
model
.
childInHk
.
info
)
let
tmp15
=
YHPreviewQuestionAndAnswerModel
(
question
:
"在港身份:"
,
answer
:
model
.
hkIdentity
==
"其他"
?
(
model
.
hkIdentityOther
.
defaultStringIfEmpty
(
detaultValue
:
"其他"
))
:
model
.
hkIdentity
)
arr
.
append
(
contentsOf
:
[
tmp14
,
tmp15
])
}
let
isHKIdCardHandled
=
model
.
isHaveHKIdentityCard
()
let
isHKIdCardHandled
=
model
.
isHaveHKIdentityCard
()
let
isHKIdCardHandledString
=
isHKIdCardHandled
?
"是"
:
"否"
let
isHKIdCardHandledString
=
isHKIdCardHandled
?
"是"
:
"否"
let
tmp16
=
YHPreviewQuestionAndAnswerModel
(
question
:
"是否办理过香港身份证:"
,
answer
:
isHKIdCardHandledString
)
let
tmp16
=
YHPreviewQuestionAndAnswerModel
(
question
:
"是否办理过香港身份证:"
,
answer
:
isHKIdCardHandledString
)
...
@@ -1595,8 +1588,6 @@ private extension YHPreviewViewModel {
...
@@ -1595,8 +1588,6 @@ private extension YHPreviewViewModel {
let
tmp0
=
YHPreviewQuestionAndAnswerModel
(
question
:
"是否随行至香港:"
,
answer
:
"否"
)
let
tmp0
=
YHPreviewQuestionAndAnswerModel
(
question
:
"是否随行至香港:"
,
answer
:
"否"
)
let
arr
=
[
tmp0
]
let
arr
=
[
tmp0
]
var
title
=
""
var
title
=
""
if
totalChild
>
1
{
if
totalChild
>
1
{
title
=
String
(
childIndex
+
1
)
title
=
String
(
childIndex
+
1
)
...
@@ -1607,32 +1598,66 @@ private extension YHPreviewViewModel {
...
@@ -1607,32 +1598,66 @@ private extension YHPreviewViewModel {
do
{
do
{
//配偶信息-否
//配偶信息-否
let
tmp0
=
YHPreviewQuestionAndAnswerModel
(
question
:
"
配偶
姓名:"
,
answer
:
model
.
subsetName
)
let
tmp0
=
YHPreviewQuestionAndAnswerModel
(
question
:
"
子女
姓名:"
,
answer
:
model
.
subsetName
)
let
tmp1
=
YHPreviewQuestionAndAnswerModel
(
question
:
"曾用名:"
,
answer
:
model
.
usedName
.
defaultStringIfEmpty
())
let
tmp1
=
YHPreviewQuestionAndAnswerModel
(
question
:
"曾用名:"
,
answer
:
model
.
usedName
.
defaultStringIfEmpty
())
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"婚前姓氏:"
,
answer
:
model
.
surname
.
defaultStringIfEmpty
())
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"婚前姓氏:"
,
answer
:
model
.
surname
.
defaultStringIfEmpty
())
let
sexStr
=
YHConstantArrayData
.
getShowNameBy
(
indexStr
:
String
(
model
.
sex
),
type
:
.
sex
)
let
sexStr
=
YHConstantArrayData
.
getShowNameBy
(
indexStr
:
String
(
model
.
sex
),
type
:
.
sex
)
let
tmp22
=
YHPreviewQuestionAndAnswerModel
(
question
:
"性别:"
,
answer
:
sexStr
)
let
tmp3
=
YHPreviewQuestionAndAnswerModel
(
question
:
"出生日期:"
,
answer
:
model
.
birthday
)
let
tmp3
=
YHPreviewQuestionAndAnswerModel
(
question
:
"出生日期:"
,
answer
:
model
.
birthday
)
var
city
=
""
var
city
=
""
if
model
.
birthPlaceAboard
==
0
{
if
model
.
birthPlaceAboard
==
0
{
//国内
//国内
if
model
.
birthPlace
.
area
.
count
>
1
{
city
=
"国内 "
+
model
.
birthPlace
.
details
city
=
"国内 "
+
model
.
birthPlace
.
area
[
0
]
+
"/"
+
model
.
birthPlace
.
area
[
1
]
}
else
{
city
=
"国内 --"
}
}
else
{
}
else
{
//国外
//国外
city
=
"国外 "
+
model
.
birthPlace
.
foreign
city
=
"国外 "
+
model
.
birthPlace
.
foreign
}
}
let
tmp4
=
YHPreviewQuestionAndAnswerModel
(
question
:
"出生城市:"
,
answer
:
city
)
let
tmp4
=
YHPreviewQuestionAndAnswerModel
(
question
:
"出生城市:"
,
answer
:
city
)
let
tmp44
=
YHPreviewQuestionAndAnswerModel
(
question
:
"婚姻状况:"
,
answer
:
model
.
married
.
defaultStringIfEmpty
())
let
tmp44
=
YHPreviewQuestionAndAnswerModel
(
question
:
"婚姻状况:"
,
answer
:
model
.
married
.
defaultStringIfEmpty
())
let
tmp444
=
YHPreviewQuestionAndAnswerModel
(
question
:
"职业:"
,
answer
:
model
.
occupation
.
defaultStringIfEmpty
())
var
arr
=
[
tmp0
,
tmp1
,
tmp2
,
tmp3
,
tmp4
,
tmp44
]
var
arr
=
[
tmp0
,
tmp1
,
tmp2
,
tmp22
,
tmp3
,
tmp4
,
tmp44
,
tmp444
]
let
tmp10
=
YHPreviewQuestionAndAnswerModel
(
question
:
"是否和主申请人同住:"
,
answer
:
model
.
nows
==
1
?
"是"
:
"否"
)
if
model
.
occupation
.
contains
(
"在职"
)
{
arr
.
append
(
tmp10
)
let
tmp5
=
YHPreviewQuestionAndAnswerModel
(
question
:
"职业名称:"
,
answer
:
model
.
occupationName
)
arr
.
append
(
tmp5
)
var
liveAbord
=
false
//海外
var
address
=
""
if
model
.
nows
==
0
{
var
title
=
""
if
model
.
address
.
country
.
contains
(
"中国"
)
{
//国内
title
=
"国内 "
if
model
.
address
.
area
.
count
>
1
{
title
=
title
+
model
.
address
.
area
[
0
]
+
"/"
+
model
.
address
.
area
[
1
]
}
else
{
title
=
"国内 --"
}
address
=
model
.
address
.
details
}
else
{
//国外
title
=
model
.
address
.
country
liveAbord
=
true
address
=
model
.
address
.
foreign
}
let
tmp11
=
YHPreviewQuestionAndAnswerModel
(
question
:
"现居住地址:"
,
answer
:
title
)
arr
.
append
(
tmp11
)
}
if
liveAbord
==
true
{
let
title
=
model
.
isLiveOverseaYear
==
1
?
"是"
:
"否"
let
tmp12
=
YHPreviewQuestionAndAnswerModel
(
question
:
"是否在海外居住满1年及以上:"
,
answer
:
title
)
arr
.
append
(
tmp12
)
}
if
true
{
let
title
=
model
.
isPreviousMarriageChild
()
?
"是"
:
"否"
let
tmp12
=
YHPreviewQuestionAndAnswerModel
(
question
:
"是否为前次婚姻的子女"
,
answer
:
title
)
arr
.
append
(
tmp12
)
}
if
model
.
nows
==
0
{
let
tmp133
=
YHPreviewQuestionAndAnswerModel
(
question
:
"详细地址:"
,
answer
:
address
.
defaultStringIfEmpty
())
arr
.
append
(
tmp133
)
}
}
let
isHKIdCardHandled
=
model
.
isHaveHKIdentityCard
()
let
isHKIdCardHandled
=
model
.
isHaveHKIdentityCard
()
...
@@ -1656,119 +1681,90 @@ private extension YHPreviewViewModel {
...
@@ -1656,119 +1681,90 @@ private extension YHPreviewViewModel {
}
}
}
}
if
model
.
isFollow
()
{
// 证件信息显示逻辑
//1.跟随 证件信息
var
cerInfoArr
=
[
YHPersonInfoCellModel1
]()
do
{
let
a
=
showCerInfoLogic
(
familyMember
:
model
,
mainApplicantInfo
:
mainApplicant
)
//中国身份证
let
isNeedShowHK
=
a
.
showHK
var
str
=
model
.
certificates
.
cnIdentityCard
.
number
let
isNeedShowPassport
=
a
.
showPassport
let
tmp0
=
YHPreviewQuestionAndAnswerModel
(
question
:
"中国身份证号码:"
,
answer
:
str
.
defaultStringIfEmpty
())
if
isNeedShowHK
{
str
=
model
.
certificates
.
cnIdentityCard
.
issueAt
let
tmp1
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发地:"
,
answer
:
str
.
defaultStringIfEmpty
())
var
str
=
model
.
certificates
.
hkMacaoPass
.
number
let
tmp4
=
YHPreviewQuestionAndAnswerModel
(
question
:
"旅行社证件号码:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
cnIdentityCard
.
issueDateStartAt
let
tmp2
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
hkMacaoPass
.
issueAt
let
tmp5
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发地:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
cnIdentityCard
.
issueDateEndAt
if
str
.
isEmpty
{
str
=
model
.
certificates
.
hkMacaoPass
.
issueDateStartAt
str
=
""
let
tmp6
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
}
else
{
if
str
==
"8888-01-01"
{
str
=
model
.
certificates
.
hkMacaoPass
.
issueDateEndAt
str
=
"长期"
if
str
.
isEmpty
{
}
str
=
""
}
}
else
{
let
tmp3
=
YHPreviewQuestionAndAnswerModel
(
question
:
"届满日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
if
str
==
"8888-01-01"
{
let
model0
=
YHPersonInfoCellModel1
(
cellTitle
:
"中国身份证"
,
cellData
:
[
tmp0
,
tmp1
,
tmp2
,
tmp3
])
str
=
"长期"
var
arr
=
[
model0
]
//港澳通行证
if
model
.
isHandled
==
1
{
str
=
model
.
certificates
.
hkMacaoPass
.
number
let
tmp4
=
YHPreviewQuestionAndAnswerModel
(
question
:
"旅行社证件号码:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
hkMacaoPass
.
issueAt
let
tmp5
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发地:"
,
answer
:
str
)
str
=
model
.
certificates
.
hkMacaoPass
.
issueDateStartAt
let
tmp6
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
hkMacaoPass
.
issueDateEndAt
if
str
.
isEmpty
{
str
=
""
}
else
{
if
str
==
"8888-01-01"
{
str
=
"长期"
}
}
let
tmp7
=
YHPreviewQuestionAndAnswerModel
(
question
:
"届满日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
let
model1
=
YHPersonInfoCellModel1
(
cellTitle
:
"港澳通行证"
,
cellData
:
[
tmp4
,
tmp5
,
tmp6
,
tmp7
])
arr
.
append
(
model1
)
}
if
model
.
nationality
!=
"中国-China"
{
//护照及其他旅行证件
var
str
=
YHConstantArrayData
.
getShowNameBy
(
indexStr
:
String
(
model
.
certificates
.
passport
.
passPortType
),
type
:
.
idType
)
let
tmp8
=
YHPreviewQuestionAndAnswerModel
(
question
:
"证件类别:"
,
answer
:
str
)
str
=
model
.
certificates
.
passport
.
number
let
tmp9
=
YHPreviewQuestionAndAnswerModel
(
question
:
"证件号码:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
passport
.
issueAt
let
tmp10
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发地:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
passport
.
issueDateStartAt
let
tmp11
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发日期:"
,
answer
:
str
)
str
=
model
.
certificates
.
passport
.
issueDateEndAt
if
str
.
isEmpty
{
str
=
""
}
else
{
if
str
==
"8888-01-01"
{
str
=
"长期"
}
}
let
tmp12
=
YHPreviewQuestionAndAnswerModel
(
question
:
"届满日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
let
model2
=
YHPersonInfoCellModel1
(
cellTitle
:
"护照及其他旅行证件"
,
cellData
:
[
tmp8
,
tmp9
,
tmp10
,
tmp11
,
tmp12
])
arr
.
append
(
model2
)
}
var
title
=
""
if
totalChild
>
1
{
title
=
String
(
childIndex
+
1
)
}
}
let
model3
=
YHPreviewInfoSessionModel
(
cellType
:
.
idCardInfoType
,
cellTitle
:
"证件信息"
+
title
,
cellData1
:
arr
)
arrTemp
.
append
(
model3
)
}
}
let
tmp7
=
YHPreviewQuestionAndAnswerModel
(
question
:
"届满日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
let
model1
=
YHPersonInfoCellModel1
(
cellTitle
:
"港澳通行证"
,
cellData
:
[
tmp4
,
tmp5
,
tmp6
,
tmp7
])
cerInfoArr
.
append
(
model1
)
}
if
isNeedShowPassport
{
//护照及其他旅行证件
//2.跟随 证件照
var
str
=
model
.
certificates
.
passport
.
number
do
{
let
tmp9
=
YHPreviewQuestionAndAnswerModel
(
question
:
"证件号码:"
,
answer
:
str
.
defaultStringIfEmpty
())
//证件照片
str
=
model
.
certificates
.
passport
.
issueAt
let
tmp10
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发地:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
passport
.
issueDateStartAt
let
tmp11
=
YHPreviewQuestionAndAnswerModel
(
question
:
"签发日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
str
=
model
.
certificates
.
passport
.
issueDateEndAt
if
str
.
isEmpty
{
str
=
""
}
else
{
if
str
==
"8888-01-01"
{
str
=
"长期"
}
}
let
tmp12
=
YHPreviewQuestionAndAnswerModel
(
question
:
"届满日期:"
,
answer
:
str
.
defaultStringIfEmpty
())
let
model2
=
YHPersonInfoCellModel1
(
cellTitle
:
"护照及其他旅行证件"
,
cellData
:
[
tmp9
,
tmp10
,
tmp11
,
tmp12
])
cerInfoArr
.
append
(
model2
)
}
let
model3
=
YHPreviewInfoSessionModel
(
cellType
:
.
idCardInfoType
,
cellTitle
:
"证件信息"
,
cellData1
:
cerInfoArr
)
arrTemp
.
append
(
model3
)
// 证件照片显示逻辑
let
cerPhotoArr
=
showCerPhotoLogic
(
familyMember
:
model
,
mainApplicantInfo
:
mainApplicant
)
var
photoArr
=
[
YHPersonInfoCellModel2
]()
for
cerType
in
cerPhotoArr
{
if
cerType
==
.
idCard
{
let
front
=
model
.
certificates
.
cnIdentityCard
.
imgFront
let
front
=
model
.
certificates
.
cnIdentityCard
.
imgFront
let
back
=
model
.
certificates
.
cnIdentityCard
.
imgBack
let
back
=
model
.
certificates
.
cnIdentityCard
.
imgBack
let
model1
=
YHPersonInfoCellModel2
(
cellTitle
:
"中国身份证"
,
frontUrl
:
front
,
backUrl
:
back
,
idType
:
1
)
let
model1
=
YHPersonInfoCellModel2
(
cellTitle
:
"中国身份证"
,
frontUrl
:
front
,
backUrl
:
back
,
idType
:
1
)
var
arr
=
[
model1
]
photoArr
.
append
(
model1
)
if
model
.
isHandled
==
1
{
}
else
if
cerType
==
.
hkPassPort
{
let
front
=
model
.
certificates
.
hkMacaoPass
.
imgFront
let
front
=
model
.
certificates
.
hkMacaoPass
.
imgFront
let
back
=
model
.
certificates
.
hkMacaoPass
.
imgBack
let
back
=
model
.
certificates
.
hkMacaoPass
.
imgBack
let
model2
=
YHPersonInfoCellModel2
(
cellTitle
:
"港澳通行证"
,
frontUrl
:
front
,
backUrl
:
back
,
idType
:
2
)
let
model2
=
YHPersonInfoCellModel2
(
cellTitle
:
"港澳通行证"
,
frontUrl
:
front
,
backUrl
:
back
,
idType
:
2
)
arr
.
append
(
model2
)
photoArr
.
append
(
model2
)
}
var
title
=
""
}
else
if
cerType
==
.
passPort
{
if
totalChild
>
1
{
let
front
=
model
.
certificates
.
passport
.
imgFront
title
=
String
(
childIndex
+
1
)
let
back
=
model
.
certificates
.
passport
.
imgBack
}
let
model3
=
YHPersonInfoCellModel2
(
cellTitle
:
"护照"
,
frontUrl
:
front
,
backUrl
:
back
,
idType
:
3
)
let
model4
=
YHPreviewInfoSessionModel
(
cellType
:
.
idPictureType
,
cellTitle
:
"证件照片"
+
title
,
cellData2
:
arr
)
photoArr
.
append
(
model3
)
arrTemp
.
append
(
model4
)
}
}
}
}
let
model4
=
YHPreviewInfoSessionModel
(
cellType
:
.
idPictureType
,
cellTitle
:
"证件照片"
,
cellData2
:
photoArr
)
arrTemp
.
append
(
model4
)
arrDataForChildren
.
append
(
contentsOf
:
arrTemp
)
arrDataForChildren
.
append
(
contentsOf
:
arrTemp
)
}
}
...
@@ -1836,4 +1832,157 @@ private extension YHPreviewViewModel {
...
@@ -1836,4 +1832,157 @@ private extension YHPreviewViewModel {
}
}
}
}
}
}
func
showCerInfoLogic
(
familyMember
:
YHFamilyMember
?,
mainApplicantInfo
:
YHMyMainApplicantInfoModel
?)
->
(
showHK
:
Bool
,
isHKMust
:
Bool
,
showPassport
:
Bool
,
isPassportMust
:
Bool
)
{
guard
let
familyMember
=
familyMember
else
{
return
(
false
,
false
,
false
,
false
)
}
// 中国国籍&居住国内、中国国籍&居住国外不满一年
// 1) 办理过港澳通
// 证件上传:身份证+港澳通
// 证件信息:港澳通行证必填(无身份证、护照)
//
// 2) 没办理过港澳通
// 证件上传:身份证
// 证件信息:港澳通行证非必填(无身份证、护照)
//
// 中国国籍&居住国外满一年
// 证件上传:护照+身份证
// 证件信息:护照必填(无身份证)
//
// 外籍国籍(无论是否在国外居住满一年):
// 证件上传:护照
// 证件信息:仅护照且必填(无身份证)
// 是否显示港澳通行证
var
showHK
=
false
// 港澳通行证是否必填
var
isHKMust
=
false
// 是否显示护照
var
showPassport
=
false
// 护照是否必填
var
isPassportMust
=
false
// 国籍
let
nationality
=
familyMember
.
nationality
// 居住国外是否满一年
var
is_live_oversea_year
=
familyMember
.
isOverSeasOver1Year
()
// 居住国家
var
liveCountry
=
familyMember
.
address
.
country
if
familyMember
.
isLiveTother
(),
let
mainApplicant
=
mainApplicantInfo
{
// 与主申请人同住用主申请人的居住信息判断
liveCountry
=
mainApplicant
.
applicant_address
.
country
is_live_oversea_year
=
mainApplicant
.
isOverSeasOver1Year
()
}
if
nationality
.
contains
(
"中国"
)
{
// 中国国籍
let
isLiveInChina
=
liveCountry
.
contains
(
"中国"
.
local
)
if
isLiveInChina
{
// 居住国内
if
familyMember
.
isHandled
==
0
{
// 没办理过港澳通行证
// 证件信息:港澳通行证非必填(无身份证、护照)
showHK
=
true
isHKMust
=
false
}
else
{
// 办理过港澳通行证
// 证件信息:港澳通行证必填(无身份证、护照)
showHK
=
true
isHKMust
=
true
}
}
else
{
// 居住国外
if
!
is_live_oversea_year
{
// 居住国外不满一年
if
familyMember
.
isHandled
==
0
{
// 没办理过港澳通行证
// 证件信息:港澳通行证非必填(无身份证、护照)
showHK
=
true
isHKMust
=
false
}
else
{
// 办理过港澳通行证
// 证件信息:港澳通行证必填(无身份证、护照)
showHK
=
true
isHKMust
=
true
}
}
else
{
// 居住国外满一年
// 证件信息:护照必填(无身份证)
showPassport
=
true
isPassportMust
=
true
}
}
}
else
{
// 外国国籍
// 证件信息:仅护照且必填(无身份证)
showPassport
=
true
isPassportMust
=
true
}
return
(
showHK
,
isHKMust
,
showPassport
,
isPassportMust
)
}
func
showCerPhotoLogic
(
familyMember
:
YHFamilyMember
?,
mainApplicantInfo
:
YHMyMainApplicantInfoModel
?)
->
[
YHCerPhotoInfoType
]
{
guard
let
familyMember
=
familyMember
else
{
return
[
.
none
]
}
// 中国国籍&居住国内、中国国籍&居住国外不满一年
// 1) 办理过港澳通
// 证件上传:身份证+港澳通
// 证件信息:港澳通行证必填(无身份证、护照)
//
// 2) 没办理过港澳通
// 证件上传:身份证
// 证件信息:港澳通行证非必填(无身份证、护照)
//
// 中国国籍&居住国外满一年
// 证件上传:护照+身份证
// 证件信息:护照必填(无身份证)
//
// 外籍国籍(无论是否在国外居住满一年):
// 证件上传:护照
// 证件信息:仅护照且必填(无身份证)
// 国籍
let
nationality
=
familyMember
.
nationality
// 居住国外是否满一年
var
is_live_oversea_year
=
familyMember
.
isOverSeasOver1Year
()
// 居住国家
var
liveCountry
=
familyMember
.
address
.
country
if
familyMember
.
isLiveTother
(),
let
mainApplicant
=
mainApplicantInfo
{
// 与主申请人同住用主申请人的居住信息判断
liveCountry
=
mainApplicant
.
applicant_address
.
country
is_live_oversea_year
=
mainApplicant
.
isOverSeasOver1Year
()
}
if
nationality
.
contains
(
"中国"
)
{
// 中国国籍
let
isLiveInChina
=
liveCountry
.
contains
(
"中国"
.
local
)
if
isLiveInChina
{
// 居住国内
if
familyMember
.
isHandled
==
0
{
// 没办理过港澳通行证
// 证件上传:身份证
return
[
.
idCard
]
}
else
{
// 办理过港澳通行证
// 证件上传:身份证+港澳通
return
[
.
idCard
,
.
hkPassPort
]
}
}
else
{
// 居住国外
if
!
is_live_oversea_year
{
// 居住国外不满一年
if
familyMember
.
isHandled
==
0
{
// 没办理过港澳通行证
// 证件上传:身份证
return
[
.
idCard
]
}
else
{
// 办理过港澳通行证
// 证件上传:身份证+港澳通
return
[
.
idCard
,
.
hkPassPort
]
}
}
else
{
// 居住国外满一年
// 证件上传:护照+身份证
return
[
.
passPort
,
.
idCard
]
}
}
}
else
{
// 外国国籍
// 证件信息:仅护照且必填(无身份证)
return
[
.
passPort
]
}
}
}
}
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/QMAS(优才)/ServiceProcess(我的信息流程)/WorkExperience(工作经验)/C/YHWorkExperiencePositionViewViewController.swift
View file @
8c081e1f
...
@@ -24,7 +24,7 @@ class YHWorkExperiencePositionViewViewController: YHBaseViewController {
...
@@ -24,7 +24,7 @@ class YHWorkExperiencePositionViewViewController: YHBaseViewController {
var
isShowPrompt
:
Bool
=
false
var
isShowPrompt
:
Bool
=
false
var
isShowMessageSelect
:
Bool
=
true
var
isShowMessageSelect
:
Bool
=
true
var
isKeyboardShow
:
Bool
=
false
var
isKeyboardShow
:
Bool
=
false
var
selectReasonIndex
:
Int
=
5
var
selectReasonIndex
:
Int
=
0
var
selectEditItem
=
YHWorkExperienceFileModel
()
var
selectEditItem
=
YHWorkExperienceFileModel
()
override
func
viewDidLoad
()
{
override
func
viewDidLoad
()
{
...
@@ -170,7 +170,11 @@ class YHWorkExperiencePositionViewViewController: YHBaseViewController {
...
@@ -170,7 +170,11 @@ class YHWorkExperiencePositionViewViewController: YHBaseViewController {
extension
YHWorkExperiencePositionViewViewController
:
UITableViewDelegate
,
UITableViewDataSource
{
extension
YHWorkExperiencePositionViewViewController
:
UITableViewDelegate
,
UITableViewDataSource
{
func
tableView
(
_
tableView
:
UITableView
,
numberOfRowsInSection
section
:
Int
)
->
Int
{
func
tableView
(
_
tableView
:
UITableView
,
numberOfRowsInSection
section
:
Int
)
->
Int
{
return
2
if
self
.
viewModel
.
position
.
is_international_work_experience
==
1
{
return
2
}
else
{
return
1
}
}
}
func
tableView
(
_
tableView
:
UITableView
,
cellForRowAt
indexPath
:
IndexPath
)
->
UITableViewCell
{
func
tableView
(
_
tableView
:
UITableView
,
cellForRowAt
indexPath
:
IndexPath
)
->
UITableViewCell
{
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/QMAS(优才)/ServiceProcess(我的信息流程)/WorkExperience(工作经验)/C/YHWorkExperienceViewController.swift
View file @
8c081e1f
...
@@ -379,7 +379,7 @@ class YHWorkExperienceViewController: YHBaseViewController {
...
@@ -379,7 +379,7 @@ class YHWorkExperienceViewController: YHBaseViewController {
}
}
@objc
func
keyboardWillShow
(
_
notification
:
Notification
)
{
@objc
func
keyboardWillShow
(
_
notification
:
Notification
)
{
if
stepView
.
currentIndex
!=
0
{
if
stepView
.
currentIndex
!=
0
&&
stepView
.
currentIndex
!=
3
{
// 当键盘将要显示时调用此函数
// 当键盘将要显示时调用此函数
stepView
.
snp
.
remakeConstraints
{
make
in
stepView
.
snp
.
remakeConstraints
{
make
in
make
.
top
.
equalTo
(
k_Height_NavigationtBarAndStatuBar
)
make
.
top
.
equalTo
(
k_Height_NavigationtBarAndStatuBar
)
...
@@ -402,7 +402,7 @@ class YHWorkExperienceViewController: YHBaseViewController {
...
@@ -402,7 +402,7 @@ class YHWorkExperienceViewController: YHBaseViewController {
}
}
@objc
func
keyboardWillHide
(
_
notification
:
Notification
)
{
@objc
func
keyboardWillHide
(
_
notification
:
Notification
)
{
if
stepView
.
currentIndex
!=
0
{
if
stepView
.
currentIndex
!=
0
&&
stepView
.
currentIndex
!=
3
{
// 当键盘将要隐藏时调用此函数
// 当键盘将要隐藏时调用此函数
stepView
.
snp
.
remakeConstraints
{
make
in
stepView
.
snp
.
remakeConstraints
{
make
in
make
.
top
.
equalTo
(
k_Height_NavigationtBarAndStatuBar
)
make
.
top
.
equalTo
(
k_Height_NavigationtBarAndStatuBar
)
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/QMAS(优才)/ServiceProcess(我的信息流程)/WorkExperience(工作经验)/V/YHWorkExperienceCompanySelectView.swift
View file @
8c081e1f
...
@@ -809,7 +809,7 @@ class YHCompanyReasonFileCell: UITableViewCell {
...
@@ -809,7 +809,7 @@ class YHCompanyReasonFileCell: UITableViewCell {
var
titleLabel
:
UILabel
!
var
titleLabel
:
UILabel
!
var
subTitleLabel
:
UILabel
!
var
subTitleLabel
:
UILabel
!
var
mainItemView
:
UIView
!
var
mainItemView
:
UIView
!
var
alertLabel
:
UILabel
!
var
dataSource
:
[
String
]
=
[
"验资报告"
,
"审计报告"
,
"绝对实益拥有人声明书"
,
"企业所得税月(季)度预缴纳税申报表(A类)(前4个季度/前12个月)"
,
"企业所得税完税证明(表格式)"
,
"企业所得税年度纳税申报表(A类) (近一年度)"
,
"工作证明"
]
var
dataSource
:
[
String
]
=
[
"验资报告"
,
"审计报告"
,
"绝对实益拥有人声明书"
,
"企业所得税月(季)度预缴纳税申报表(A类)(前4个季度/前12个月)"
,
"企业所得税完税证明(表格式)"
,
"企业所得税年度纳税申报表(A类) (近一年度)"
,
"工作证明"
]
var
model
:
YHWorkExperienceCompanyModel
?
{
var
model
:
YHWorkExperienceCompanyModel
?
{
didSet
{
didSet
{
...
@@ -892,6 +892,21 @@ class YHCompanyReasonFileCell: UITableViewCell {
...
@@ -892,6 +892,21 @@ class YHCompanyReasonFileCell: UITableViewCell {
make
.
top
.
equalTo
(
52
)
make
.
top
.
equalTo
(
52
)
}
}
alertLabel
=
{
let
label
=
UILabel
()
label
.
numberOfLines
=
0
let
b
:
ASAttributedString
=
.
init
(
"若不能提供以上证明材料,将导致您的该收入"
,
.
font
(
UIFont
.
PFSC_R
(
ofSize
:
14
)),
.
foreground
(
UIColor
(
hex
:
0x8993a2
)))
let
c
:
ASAttributedString
=
.
init
(
"不被认可不予加分"
,
.
font
(
UIFont
.
PFSC_R
(
ofSize
:
14
)),
.
foreground
(
UIColor
.
failColor
))
let
d
:
ASAttributedString
=
.
init
(
",请尽可能准备以上材料并修改此选项)"
,
.
font
(
UIFont
.
PFSC_R
(
ofSize
:
14
)),
.
foreground
(
UIColor
(
hex
:
0x8993a2
)))
label
.
attributed
.
text
=
b
+
c
+
d
return
label
}()
centerView
.
addSubview
(
alertLabel
)
alertLabel
.
snp
.
makeConstraints
{
make
in
make
.
left
.
equalTo
(
18
)
make
.
right
.
equalTo
(
-
18
)
make
.
bottom
.
equalTo
(
-
16
)
}
}
}
func
updateAllViews
()
{
func
updateAllViews
()
{
...
@@ -999,12 +1014,14 @@ class YHCompanyReasonFileCell: UITableViewCell {
...
@@ -999,12 +1014,14 @@ class YHCompanyReasonFileCell: UITableViewCell {
rightButton
.
isSelected
=
false
rightButton
.
isSelected
=
false
leftButton
.
layer
.
borderWidth
=
1
leftButton
.
layer
.
borderWidth
=
1
rightButton
.
layer
.
borderWidth
=
0
rightButton
.
layer
.
borderWidth
=
0
alertLabel
.
isHidden
=
true
}
}
if
model
?
.
has_provide_certificate
==
2
{
if
model
?
.
has_provide_certificate
==
2
{
rightButton
.
isSelected
=
true
rightButton
.
isSelected
=
true
leftButton
.
isSelected
=
false
leftButton
.
isSelected
=
false
leftButton
.
layer
.
borderWidth
=
0
leftButton
.
layer
.
borderWidth
=
0
rightButton
.
layer
.
borderWidth
=
1
rightButton
.
layer
.
borderWidth
=
1
alertLabel
.
isHidden
=
false
}
}
for
i
in
0
..<
dataSource
.
count
{
for
i
in
0
..<
dataSource
.
count
{
let
agreeButton
=
{
let
agreeButton
=
{
...
@@ -1062,6 +1079,13 @@ class YHCompanyReasonFileCell: UITableViewCell {
...
@@ -1062,6 +1079,13 @@ class YHCompanyReasonFileCell: UITableViewCell {
if
let
block
=
selectBlock
{
if
let
block
=
selectBlock
{
block
(
model
??
YHWorkExperienceCompanyModel
())
block
(
model
??
YHWorkExperienceCompanyModel
())
}
}
mainItemView
.
snp
.
remakeConstraints
{
make
in
make
.
left
.
right
.
equalToSuperview
()
make
.
bottom
.
equalTo
(
-
16
)
make
.
top
.
equalTo
(
52
)
}
alertLabel
.
isHidden
=
true
}
}
@objc
func
rightClick
(
sender
:
UIButton
)
{
@objc
func
rightClick
(
sender
:
UIButton
)
{
...
@@ -1069,6 +1093,12 @@ class YHCompanyReasonFileCell: UITableViewCell {
...
@@ -1069,6 +1093,12 @@ class YHCompanyReasonFileCell: UITableViewCell {
if
let
block
=
selectBlock
{
if
let
block
=
selectBlock
{
block
(
model
??
YHWorkExperienceCompanyModel
())
block
(
model
??
YHWorkExperienceCompanyModel
())
}
}
mainItemView
.
snp
.
remakeConstraints
{
make
in
make
.
left
.
right
.
equalToSuperview
()
make
.
bottom
.
equalTo
(
-
72
)
make
.
top
.
equalTo
(
52
)
}
alertLabel
.
isHidden
=
false
}
}
}
}
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/QMAS(优才)/ServiceProcess(我的信息流程)/WorkExperience(工作经验)/ViewModel/YHWorkItemListViewModel.swift
View file @
8c081e1f
...
@@ -60,8 +60,8 @@ class YHWorkItemListViewModel: YHBaseViewModel {
...
@@ -60,8 +60,8 @@ class YHWorkItemListViewModel: YHBaseViewModel {
func
requestWorkTimeRemarkWorkExperience
(
_
orderId
:
String
,
_
isSaveAll
:
Int
=
0
,
callBackBlock
:
@escaping
(
_
success
:
Bool
?,
_
error
:
YHErrorModel
?)
->
())
{
func
requestWorkTimeRemarkWorkExperience
(
_
orderId
:
String
,
_
isSaveAll
:
Int
=
0
,
callBackBlock
:
@escaping
(
_
success
:
Bool
?,
_
error
:
YHErrorModel
?)
->
())
{
let
params
:
[
String
:
Any
]
=
[
"order_id"
:
orderId
,
let
params
:
[
String
:
Any
]
=
[
"order_id"
:
orderId
,
"work_time_
overlap
_remark"
:
self
.
mainModel
.
work_time_overlap_remark
,
"work_time_
empty
_remark"
:
self
.
mainModel
.
work_time_overlap_remark
,
"work_time_
empty
_remark"
:
self
.
mainModel
.
work_time_empty_remark
,
"work_time_
overlap
_remark"
:
self
.
mainModel
.
work_time_empty_remark
,
"is_save_all"
:
isSaveAll
]
"is_save_all"
:
isSaveAll
]
let
strUrl
=
YHBaseUrlManager
.
shared
.
curURL
()
+
YHAllApiName
.
WorkExperience
.
saveWorkTimeRemark
let
strUrl
=
YHBaseUrlManager
.
shared
.
curURL
()
+
YHAllApiName
.
WorkExperience
.
saveWorkTimeRemark
let
_
=
YHNetRequest
.
postRequest
(
url
:
strUrl
,
params
:
params
)
{
[
weak
self
]
json
,
code
in
let
_
=
YHNetRequest
.
postRequest
(
url
:
strUrl
,
params
:
params
)
{
[
weak
self
]
json
,
code
in
...
...
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