Commit ce194313 authored by pete谢兆麟's avatar pete谢兆麟

Merge branch 'yinhe-live-1212' of...

Merge branch 'yinhe-live-1212' of http://gitlab.galaxy-immi.com/mobile-group/galaxy-iOS into yinhe-live-1212
parents 395710ce 897dde1e
......@@ -6948,7 +6948,7 @@
CODE_SIGN_ENTITLEMENTS = galaxy/galaxyTestEnv.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 10;
CURRENT_PROJECT_VERSION = 13;
DEVELOPMENT_TEAM = RXHYW88XR7;
ENABLE_USER_SCRIPT_SANDBOXING = NO;
FRAMEWORK_SEARCH_PATHS = (
......@@ -7090,7 +7090,7 @@
CODE_SIGN_ENTITLEMENTS = galaxy/galaxy.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 10;
CURRENT_PROJECT_VERSION = 13;
DEVELOPMENT_TEAM = RXHYW88XR7;
ENABLE_USER_SCRIPT_SANDBOXING = NO;
FRAMEWORK_SEARCH_PATHS = (
......@@ -7295,7 +7295,7 @@
CODE_SIGN_ENTITLEMENTS = galaxy/galaxyDebug.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 10;
CURRENT_PROJECT_VERSION = 13;
DEVELOPMENT_TEAM = RXHYW88XR7;
ENABLE_USER_SCRIPT_SANDBOXING = NO;
FRAMEWORK_SEARCH_PATHS = (
......@@ -7342,7 +7342,7 @@
CODE_SIGN_ENTITLEMENTS = galaxy/galaxy.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 10;
CURRENT_PROJECT_VERSION = 13;
DEVELOPMENT_TEAM = RXHYW88XR7;
ENABLE_USER_SCRIPT_SANDBOXING = NO;
FRAMEWORK_SEARCH_PATHS = (
......
......@@ -502,7 +502,7 @@ extension YHHKPlanItemView : UITextViewDelegate {
guard let model = dataMode else { return }
guard let text = textView.text else { return }
var txtNum : Int = calcTextLength(string: text)
let txtNum : Int = calcTextLength(string: text)
numberLabel.text = txtNum.string + "/\(maxNumbler)"
model.content = text
......
......@@ -167,7 +167,7 @@ extension YHIncomeRecordViewController {
private func setupData() {
let detail: ASAttributedString = .init(string: "备注:全年收入是指应课税(应纳所得税)的就业或业务收入,包括工资薪金、津贴、股票期权及从其拥有的公司所得的利润。由个人投资所产生的收入不会计算在内。", .font(UIFont.PFSC_R(ofSize: 13)), .foreground(UIColor(hexString: "#8993A2") ?? .gray))
let firstSection: [TableRow] = [.consentForHKTravel("收入情况", detail, "您在前一年,全年收入是否达港币100万元或以上")]
let firstSection: [TableRow] = [.consentForHKTravel("收入情况", detail, "您在近十二个月,总收入是否达到港币100万元或以上")]
guard incomeModel.income_over_100 == YHIncomeOver100.true.rawValue else {
datas = [firstSection]
tableView.reloadData()
......
......@@ -116,6 +116,15 @@ class YHMainApplicantInformationViewModel: YHBaseViewModel {
return [section, section1]
} else if nationality.contains("中国-China") && is_live_oversea_year == 1 {
return [section, section2]
} else if nationality.contains("中国") {
if is_live_oversea_year == 1 {
if mainModel.is_handled == 1 {
return [section1, section2]
}
return [section2]
} else {
return [section1]
}
} else {
return [section2]
}
......@@ -340,6 +349,7 @@ class YHMainApplicantInformationViewModel: YHBaseViewModel {
mainModel.address.foreign = item.message ?? ""
case .id33:
mainModel.is_live_oversea_year = item.value?.first?.int ?? 0
mainModel.is_handled = 0
case .id34:
mainModel.birth_place.foreign = item.message ?? ""
case .id35:
......@@ -640,6 +650,19 @@ class YHMainApplicantInformationViewModel: YHBaseViewModel {
guard passport_issue_at.count > 0 else { return false }
guard passport_issue_date_start_at.count > 0 else { return false }
guard passport_issue_date_end_at.count > 0 else { return false }
} else if nationality.contains("中国") {
if is_live_oversea_year == 1 {
guard passport_number.count > 0 else { return false }
guard passport_issue_at.count > 0 else { return false }
guard passport_issue_date_start_at.count > 0 else { return false }
guard passport_issue_date_end_at.count > 0 else { return false }
}
if mainModel.is_handled == 1 {
guard hk_macao_pass_number.count > 0 else { return false }
guard hk_macao_pass_issue_at.count > 0 else { return false }
guard hk_macao_pass_issue_date_start_at.count > 0 else { return false }
guard hk_macao_pass_issue_date_end_at.count > 0 else { return false }
}
} else {
guard passport_number.count > 0 else { return false }
guard passport_issue_at.count > 0 else { return false }
......
......@@ -35,10 +35,25 @@ class YHPreviewFamilyMemberViewController: YHPreviewBaseViewController {
// private var brotherButton : UIButton!
private var arrButtons : [UIButton] = []
lazy var noNetWorkTipsView: YHEmptyDataView = {
let view = YHEmptyDataView.createView("暂无内容", kEmptyCommonBgName)
view.topMargin = 0
view.backgroundColor = .white
view.isHidden = true
return view
}()
}
private extension YHPreviewFamilyMemberViewController {
func setupUI() {
noNetWorkTipsView.isHidden = false
noNetWorkTipsView.backgroundColor = UIColor.contentBkgColor
view.addSubview(self.noNetWorkTipsView)
self.noNetWorkTipsView.topMargin = 20
view.addSubview(buttonHoldView)
buttonHoldView.snp.makeConstraints { make in
make.top.equalToSuperview()
......@@ -259,6 +274,16 @@ private extension YHPreviewFamilyMemberViewController {
previewVM.arrDataForMainApplicationInfo = []
}
homeTableView.reloadData()
if previewVM.arrDataForMainApplicationInfo.count > 0 {
self.noNetWorkTipsView.isHidden = true
self.homeTableView.isHidden = false
} else {
self.noNetWorkTipsView.isHidden = false
self.homeTableView.isHidden = true
}
}
......
......@@ -1368,90 +1368,94 @@ private extension YHPreviewViewModel {
}
}
// 证件信息显示逻辑
var cerInfoArr = [YHPersonInfoCellModel1]()
let a = showCerInfoLogic(familyMember: model, mainApplicantInfo: mainApplicant)
let isNeedShowHK = a.showHK
let isNeedShowPassport = a.showPassport
if isNeedShowHK {
if model.follow == 1 { // 随行 才显示证件信息和证件照片
var str = model.certificates.hkMacaoPass.number
let tmp4 = YHPreviewQuestionAndAnswerModel(question: "旅行证件号码:", answer: str.defaultStringIfEmpty())
// 证件信息显示逻辑
var cerInfoArr = [YHPersonInfoCellModel1]()
let a = showCerInfoLogic(familyMember: model, mainApplicantInfo: mainApplicant)
let isNeedShowHK = a.showHK
let isNeedShowPassport = a.showPassport
str = model.certificates.hkMacaoPass.issueAt
let tmp5 = YHPreviewQuestionAndAnswerModel(question: "签发地:", answer: str.defaultStringIfEmpty())
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 = "长期"
if isNeedShowHK {
var str = model.certificates.hkMacaoPass.number
let tmp4 = YHPreviewQuestionAndAnswerModel(question: "旅行证件号码:", answer: str.defaultStringIfEmpty())
str = model.certificates.hkMacaoPass.issueAt
let tmp5 = YHPreviewQuestionAndAnswerModel(question: "签发地:", answer: str.defaultStringIfEmpty())
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])
cerInfoArr.append(model1)
}
let tmp7 = YHPreviewQuestionAndAnswerModel(question: "届满日期:", answer: str.defaultStringIfEmpty())
let model1 = YHPersonInfoCellModel1(cellTitle: "港澳通行证", cellData: [tmp4,tmp5,tmp6,tmp7])
cerInfoArr.append(model1)
}
if isNeedShowPassport {
//护照及其他旅行证件
var 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 = "长期"
if isNeedShowPassport {
//护照及其他旅行证件
var 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: [tmp9,tmp10,tmp11,tmp12])
cerInfoArr.append(model2)
}
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 back = model.certificates.cnIdentityCard.imgBack
let model1 = YHPersonInfoCellModel2(cellTitle: "中国身份证",frontUrl: front, backUrl: back, idType: 1)
photoArr.append(model1)
} else if cerType == .hkPassPort {
let front = model.certificates.hkMacaoPass.imgFront
let back = model.certificates.hkMacaoPass.imgBack
let model2 = YHPersonInfoCellModel2(cellTitle: "港澳通行证",frontUrl: front, backUrl: back, idType: 2)
photoArr.append(model2)
} else if cerType == .passPort {
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 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 back = model.certificates.cnIdentityCard.imgBack
let model1 = YHPersonInfoCellModel2(cellTitle: "中国身份证",frontUrl: front, backUrl: back, idType: 1)
photoArr.append(model1)
} else if cerType == .hkPassPort {
let front = model.certificates.hkMacaoPass.imgFront
let back = model.certificates.hkMacaoPass.imgBack
let model2 = YHPersonInfoCellModel2(cellTitle: "港澳通行证",frontUrl: front, backUrl: back, idType: 2)
photoArr.append(model2)
} else if cerType == .passPort {
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)
}
let model4 = YHPreviewInfoSessionModel(cellType: .idPictureType, cellTitle: "证件照片", cellData2: photoArr)
arrTemp.append(model4)
arrDataForSpouse = arrTemp
}
......@@ -1615,9 +1619,6 @@ private extension YHPreviewViewModel {
let tmp44 = YHPreviewQuestionAndAnswerModel(question: "婚姻状况:", answer: model.married.defaultStringIfEmpty())
var arr = [tmp0,tmp1,tmp2,tmp3,tmp4,tmp44]
let tmp10 = YHPreviewQuestionAndAnswerModel(question: "是否和主申请人同住:", answer: model.nows == 1 ? "是" : "否")
arr.append(tmp10)
var liveAbord = false //海外
var address = ""
if model.nows == 0 {
......@@ -1648,12 +1649,6 @@ private extension YHPreviewViewModel {
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)
......@@ -1680,91 +1675,94 @@ private extension YHPreviewViewModel {
}
}
// 证件信息显示逻辑
var cerInfoArr = [YHPersonInfoCellModel1]()
let a = showCerInfoLogic(familyMember: model, mainApplicantInfo: mainApplicant)
let isNeedShowHK = a.showHK
let isNeedShowPassport = a.showPassport
if isNeedShowHK {
var str = model.certificates.hkMacaoPass.number
let tmp4 = YHPreviewQuestionAndAnswerModel(question: "旅行证件号码:", answer: str.defaultStringIfEmpty())
str = model.certificates.hkMacaoPass.issueAt
let tmp5 = YHPreviewQuestionAndAnswerModel(question: "签发地:", answer: str.defaultStringIfEmpty())
str = model.certificates.hkMacaoPass.issueDateStartAt
let tmp6 = YHPreviewQuestionAndAnswerModel(question: "签发日期:", answer: str.defaultStringIfEmpty())
if model.follow == 1 { // 随行 才显示证件信息和证件照片
// 证件信息显示逻辑
var cerInfoArr = [YHPersonInfoCellModel1]()
let a = showCerInfoLogic(familyMember: model, mainApplicantInfo: mainApplicant)
let isNeedShowHK = a.showHK
let isNeedShowPassport = a.showPassport
str = model.certificates.hkMacaoPass.issueDateEndAt
if str.isEmpty {
str = ""
} else {
if str == "8888-01-01" {
str = "长期"
if isNeedShowHK {
var str = model.certificates.hkMacaoPass.number
let tmp4 = YHPreviewQuestionAndAnswerModel(question: "旅行证件号码:", answer: str.defaultStringIfEmpty())
str = model.certificates.hkMacaoPass.issueAt
let tmp5 = YHPreviewQuestionAndAnswerModel(question: "签发地:", answer: str.defaultStringIfEmpty())
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])
cerInfoArr.append(model1)
}
let tmp7 = YHPreviewQuestionAndAnswerModel(question: "届满日期:", answer: str.defaultStringIfEmpty())
let model1 = YHPersonInfoCellModel1(cellTitle: "港澳通行证", cellData: [tmp4,tmp5,tmp6,tmp7])
cerInfoArr.append(model1)
}
if isNeedShowPassport {
//护照及其他旅行证件
var 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 = "长期"
if isNeedShowPassport {
//护照及其他旅行证件
var 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: [tmp9,tmp10,tmp11,tmp12])
cerInfoArr.append(model2)
}
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 back = model.certificates.cnIdentityCard.imgBack
let model1 = YHPersonInfoCellModel2(cellTitle: "中国身份证",frontUrl: front, backUrl: back, idType: 1)
photoArr.append(model1)
} else if cerType == .hkPassPort {
let front = model.certificates.hkMacaoPass.imgFront
let back = model.certificates.hkMacaoPass.imgBack
let model2 = YHPersonInfoCellModel2(cellTitle: "港澳通行证",frontUrl: front, backUrl: back, idType: 2)
photoArr.append(model2)
} else if cerType == .passPort {
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 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 back = model.certificates.cnIdentityCard.imgBack
let model1 = YHPersonInfoCellModel2(cellTitle: "中国身份证",frontUrl: front, backUrl: back, idType: 1)
photoArr.append(model1)
} else if cerType == .hkPassPort {
let front = model.certificates.hkMacaoPass.imgFront
let back = model.certificates.hkMacaoPass.imgBack
let model2 = YHPersonInfoCellModel2(cellTitle: "港澳通行证",frontUrl: front, backUrl: back, idType: 2)
photoArr.append(model2)
} else if cerType == .passPort {
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)
}
let model4 = YHPreviewInfoSessionModel(cellType: .idPictureType, cellTitle: "证件照片", cellData2: photoArr)
arrTemp.append(model4)
arrDataForChildren.append(contentsOf: arrTemp)
}
//子女 数据
......
......@@ -186,7 +186,7 @@ extension YHWorkExperiencePositionViewViewController: UITableViewDelegate, UITab
guard let self = self else { return }
self.viewModel.updateModel(model)
let id = model.id
if id != .id1 && id != .id2 && id != .id6 && id != .id10 {
if id != .id1 && id != .id2 && id != .id6 && id != .id10 && id != .id11 {
self.updateDataSource()
}
}
......
......@@ -84,15 +84,15 @@ class YHWorkExperienceListTableViewCell: UITableViewCell {
subTitleLabel = {
let label = UILabel()
label.font = UIFont.PFSC_R(ofSize: 12)
label.text = "(从最近一份全职工作开始,直至毕业后的第一份工作)"
label.text = "从获得有效学位(学士学位或以上)后第一份工作开始,直至最近一份工作"
label.textColor = UIColor.labelTextColor2
label.numberOfLines = 0
return label
}()
centerView.addSubview(subTitleLabel)
subTitleLabel.snp.makeConstraints { make in
make.left.equalTo(20)
make.top.equalTo(50)
make.height.equalTo(20)
make.right.equalTo(-20)
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment