Commit 9ca1bcb8 authored by David黄金龙's avatar David黄金龙

Merge branch 'develop' into davidhuang

* develop:
  // 选择器
  主申请人数据save和submit
  // 配偶基本信息
  保存接口
parents c9a5f43b 502f58ef
...@@ -79,34 +79,96 @@ class YHSpouseBasicInfoVC: YHBaseViewController { ...@@ -79,34 +79,96 @@ class YHSpouseBasicInfoVC: YHBaseViewController {
func loadBasicInfo() { func loadBasicInfo() {
guard let spouse = spouse else { return }
items.removeAll()
// 配偶信息
let title0 = YHFormTitleItem(type: .spouseInfo) let title0 = YHFormTitleItem(type: .spouseInfo)
let item01 = YHFormDetailItem(type: .everName) let item00 = YHFormDetailItem(type: .spouseName)
let item02 = YHFormDetailItem(type: .befourMarryFirstName) item00.placeHolder = "请输入".local
item00.value = spouse.subsetName
let item01 = YHFormDetailItem(type: .everName, isNeed: false)
item01.placeHolder = "选填".local
item01.value = spouse.usedName
let item02 = YHFormDetailItem(type: .befourMarryFirstName, isNeed: false)
item02.placeHolder = "如有则填写,仅支持输入字".local
item02.value = spouse.surname
let item03 = YHFormDetailItem(type: .birthday) let item03 = YHFormDetailItem(type: .birthday)
item03.placeHolder = "请选择".local
item03.value = spouse.birthday
let item04 = YHFormDetailItem(type: .birthNation) let item04 = YHFormDetailItem(type: .birthNation)
item04.value = String(spouse.isBirthOverSeas())
let item05 = YHFormDetailItem(type: .birthCity) let item05 = YHFormDetailItem(type: .birthCity)
let arr0:[YHFormItemProtocol] = [title0, item01, item02, item03, item04, item05] if spouse.isBirthOverSeas() {
item05.value = spouse.birthPlace?.foreign
item05.placeHolder = "请输入".local
} else {
item05.value = spouse.birthPlace?.area?.joined(separator: ",")
item05.placeHolder = "请选择".local
}
let arr0:[YHFormItemProtocol] = [title0, item00, item01, item02, item03, item04, item05]
// 职业信息
let title1 = YHFormTitleItem(type: .occupationInfo) let title1 = YHFormTitleItem(type: .occupationInfo)
let item10 = YHFormDetailItem(type: .occupation) let item10 = YHFormDetailItem(type: .occupation)
item10.value = spouse.occupation
item10.placeHolder = "请输入".local
let item11 = YHFormDetailItem(type: .occupationName) let item11 = YHFormDetailItem(type: .occupationName)
item11.value = spouse.occupationName
item11.placeHolder = "请输入".local
let arr1:[YHFormItemProtocol] = [title1, item10, item11] let arr1:[YHFormItemProtocol] = [title1, item10, item11]
// 职业信息
let title2 = YHFormTitleItem(type: .degreeInfo) let title2 = YHFormTitleItem(type: .degreeInfo)
let item20 = YHFormDetailItem(type: .ownDegree) let item20 = YHFormDetailItem(type: .ownDegree)
item20.placeHolder = "请选择".local
let item21 = YHFormDetailItem(type: .degreeDetailInfo) item20.value = spouse.hasDegreeStr()
let item22 = YHFormDetailItem(type: .degreeDetailInfo)
// let item21 = YHFormDetailItem(type: .degreeDetailInfo)
// let item22 = YHFormDetailItem(type: .degreeDetailInfo)
let item23 = YHFormAddItem(type: .addDegree) let item23 = YHFormAddItem(type: .addDegree)
let arr2:[YHFormItemProtocol] = [title2, item20, item21, item22, item23] let arr2:[YHFormItemProtocol] = [title2, item20, item23]
// 在港信息
let title3 = YHFormTitleItem(type: .inHongKongInfo)
let item30 = YHFormDetailItem(type: .isNowInHK)
item30.value = String(spouse.isNowInHK())
var arr3:[YHFormItemProtocol] = [title3, item30]
let title3 = YHFormTitleItem(type: .hkIdentityCardInfo)
let item30 = YHFormDetailItem(type: .isHaveHkIdentityCard)
let item31 = YHFormDetailItem(type: .hkIdentityCardNumber)
let arr3:[YHFormItemProtocol] = [title3, item30, item31]
items.append(contentsOf: [arr0, arr1, arr2, arr3]) if spouse.isNowInHK() { // 目前在港才显示 逗留期限和在港身份
let item31 = YHFormDetailItem(type: .stayHKDate)
item31.placeHolder = "请选择".local
item31.value = spouse.childInHk?.info
let item32 = YHFormDetailItem(type: .roleInHK)
item32.placeHolder = "请选择".local
item32.value = spouse.hkIdentity
arr3.append(contentsOf: [item31, item32])
}
// 香港身份证
let title4 = YHFormTitleItem(type: .hkIdentityCardInfo)
let item40 = YHFormDetailItem(type: .isHaveHkIdentityCard)
item40.value = String(spouse.isHaveHKIdentityCard())
var arr4:[YHFormItemProtocol] = [title4, item40]
if spouse.isHaveHKIdentityCard() { // 办理过香港身份证才显示证号
let item41 = YHFormDetailItem(type: .hkIdentityCardNumber)
item41.value = spouse.hkIdentityCard
arr4.append(item41)
}
items.append(contentsOf: [arr0, arr1, arr2, arr3, arr4])
tableView.reloadData() tableView.reloadData()
} }
...@@ -120,6 +182,19 @@ class YHSpouseBasicInfoVC: YHBaseViewController { ...@@ -120,6 +182,19 @@ class YHSpouseBasicInfoVC: YHBaseViewController {
} }
if item is YHFormDetailItem { if item is YHFormDetailItem {
let detailItem = item as! YHFormDetailItem let detailItem = item as! YHFormDetailItem
if detailItem.type == .birthCity {
var isBirthOverSeas = false
if let spouse = spouse {
isBirthOverSeas = spouse.isBirthOverSeas()
}
if isBirthOverSeas {
return .inputText
} else {
return .selectSheet
}
}
if detailItem.type == .spouseName if detailItem.type == .spouseName
|| detailItem.type == .everName || detailItem.type == .everName
|| detailItem.type == .befourMarryFirstName || detailItem.type == .befourMarryFirstName
...@@ -129,7 +204,6 @@ class YHSpouseBasicInfoVC: YHBaseViewController { ...@@ -129,7 +204,6 @@ class YHSpouseBasicInfoVC: YHBaseViewController {
return .inputText return .inputText
} }
if detailItem.type == .birthday if detailItem.type == .birthday
|| detailItem.type == .birthCity
|| detailItem.type == .occupation || detailItem.type == .occupation
|| detailItem.type == .stayHKDate || detailItem.type == .stayHKDate
|| detailItem.type == .roleInHK || detailItem.type == .roleInHK
...@@ -181,39 +255,102 @@ extension YHSpouseBasicInfoVC : UITableViewDelegate, UITableViewDataSource { ...@@ -181,39 +255,102 @@ extension YHSpouseBasicInfoVC : UITableViewDelegate, UITableViewDataSource {
return cell return cell
} }
if cellType == .inputText { // 输入文字cell
let cell = tableView.dequeueReusableCell(withIdentifier: YHFormItemInputTextCell.cellReuseIdentifier, for: indexPath) as! YHFormItemInputTextCell
cell.title = item.getTitle()
return cell
}
if cellType == .selectSheet { // 点击选择列表cell
let cell = tableView.dequeueReusableCell(withIdentifier: YHFormItemSelectSheetCell.cellReuseIdentifier, for: indexPath) as! YHFormItemSelectSheetCell
cell.title = item.getTitle()
return cell
}
if cellType == .twoChoice { // 双项选择cell
let cell = tableView.dequeueReusableCell(withIdentifier: YHFormItemDoubleChoiceCell.cellReuseIdentifier, for: indexPath) as! YHFormItemDoubleChoiceCell
cell.title = item.getTitle()
let answers = [YHFormChoiceItem(title: "是".local, isSelect: true),
YHFormChoiceItem(title: "否".local, isSelect: false)]
cell.answerArr = answers
return cell
}
if cellType == .addItem { // 新增item cell if cellType == .addItem { // 新增item cell
let cell = tableView.dequeueReusableCell(withIdentifier: YHFormItemAddCell.cellReuseIdentifier, for: indexPath) as! YHFormItemAddCell let cell = tableView.dequeueReusableCell(withIdentifier: YHFormItemAddCell.cellReuseIdentifier, for: indexPath) as! YHFormItemAddCell
cell.title = item.getTitle() cell.title = item.getTitle()
return cell return cell
} }
if cellType == .degreeDetailInfo { // 学位cell if item is YHFormDetailItem {
let detailItem = item as! YHFormDetailItem
let cell = tableView.dequeueReusableCell(withIdentifier: YHFormItemDegreeInfoCell.cellReuseIdentifier, for: indexPath) as! YHFormItemDegreeInfoCell if cellType == .inputText { // 输入文字cell
cell.title = item.getTitle() let cell = tableView.dequeueReusableCell(withIdentifier: YHFormItemInputTextCell.cellReuseIdentifier, for: indexPath) as! YHFormItemInputTextCell
return cell cell.isMust = detailItem.isNeed
cell.placeHolder = detailItem.placeHolder
cell.title = detailItem.getTitle()
cell.text = detailItem.value
cell.textChange = {
[weak self] text in
guard let self = self else { return }
if detailItem.type == .spouseName {
self.spouse?.subsetName = text
} else if detailItem.type == .everName {
self.spouse?.usedName = text
} else if detailItem.type == .befourMarryFirstName {
self.spouse?.surname = text
} else if detailItem.type == .birthCity {
self.spouse?.birthPlace?.foreign = text
} else if detailItem.type == .occupationName {
self.spouse?.occupationName = text
} else if detailItem.type == .hkIdentityCardNumber {
self.spouse?.hkIdentityCard = text
}
}
return cell
}
if cellType == .selectSheet { // 点击选择列表cell
let cell = tableView.dequeueReusableCell(withIdentifier: YHFormItemSelectSheetCell.cellReuseIdentifier, for: indexPath) as! YHFormItemSelectSheetCell
cell.isMust = detailItem.isNeed
cell.placeHolder = detailItem.placeHolder
cell.title = detailItem.getTitle()
cell.detail = detailItem.value
return cell
}
if cellType == .twoChoice { // 双项选择cell
let cell = tableView.dequeueReusableCell(withIdentifier: YHFormItemDoubleChoiceCell.cellReuseIdentifier, for: indexPath) as! YHFormItemDoubleChoiceCell
cell.isMust = detailItem.isNeed
cell.title = item.getTitle()
cell.answerArr = nil
if detailItem.type == .birthNation { // 出生国家
var select = false
if let value = detailItem.value {
select = Bool(value)!
}
let answers = [YHFormChoiceItem(title: "国内".local, isSelect: !select),
YHFormChoiceItem(title: "国外".local, isSelect: select)]
cell.answerArr = answers
cell.answerBlock = {
[weak self] (answers, index) in
guard let self = self else { return }
let selectItem = answers[index]
self.spouse?.setBirthOverSeas(selectItem.title == "国外".local)
self.loadBasicInfo()
}
} else if detailItem.type == .isHaveHkIdentityCard || detailItem.type == .isNowInHK { // 是否办理过香港身份证 是否在岗
var select = false
if let value = detailItem.value {
select = Bool(value)!
}
let answers = [YHFormChoiceItem(title: "是".local, isSelect: select),
YHFormChoiceItem(title: "否".local, isSelect: !select)]
cell.answerArr = answers
cell.answerBlock = {
[weak self] (answers, index) in
guard let self = self else { return }
let selectItem = answers[index]
if detailItem.type == .isNowInHK {
self.spouse?.setNowIsInHK(selectItem.title == "是".local)
} else if detailItem.type == .isHaveHkIdentityCard {
self.spouse?.setHaveHKIdentityCard(selectItem.title == "是".local)
}
self.loadBasicInfo()
}
}
return cell
}
if cellType == .degreeDetailInfo { // 学位cell
let cell = tableView.dequeueReusableCell(withIdentifier: YHFormItemDegreeInfoCell.cellReuseIdentifier, for: indexPath) as! YHFormItemDegreeInfoCell
cell.title = item.getTitle()
return cell
}
} }
return createDefaultCell(indexPath) return createDefaultCell(indexPath)
} }
...@@ -271,8 +408,74 @@ extension YHSpouseBasicInfoVC : UITableViewDelegate, UITableViewDataSource { ...@@ -271,8 +408,74 @@ extension YHSpouseBasicInfoVC : UITableViewDelegate, UITableViewDataSource {
func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) { func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
let vc = YHParentInfoVC() if !(0..<items.count).contains(indexPath.section) { return }
self.navigationController?.pushViewController(vc) let arr:[YHFormItemProtocol] = items[indexPath.section]
if !(0..<arr.count).contains(indexPath.row) { return }
let item = arr[indexPath.row]
if item is YHFormDetailItem {
let detailItem = item as! YHFormDetailItem
if detailItem.type == .birthday || detailItem.type == .stayHKDate { // 出生日期/获准滞留至
YHDatePickView.show(type: .yyyymmdd) { [weak self] date in
guard let self = self else { return }
if detailItem.type == .birthday {
self.spouse?.birthday = date
} else if detailItem.type == .stayHKDate {
self.spouse?.childInHk?.info = date
}
self.loadBasicInfo()
}
} else if detailItem.type == .birthCity { // 出生城市
var isBirthOverSeas = false
if let spouse = spouse {
isBirthOverSeas = spouse.isOverSeasOver1Year()
}
// 出生国外时 出生城市是输入框
if isBirthOverSeas { return }
let vc = YHAddressViewController()
vc.backLocationStringController = {
[weak self] (string1, string2, string3, string4) in
guard let self = self else { return }
print("\(string1)\n\(string2)\n\(string3)\n\(string4)")
self.spouse?.birthPlace?.area = [string2, string3, string4]
self.loadBasicInfo()
}
self.present(vc, animated: true)
} else if detailItem.type == .roleInHK { // 在港身份
let identity = self.spouse?.hkIdentity ?? ""
YHFormPickerView.show(type: .identity, selectTitle:identity ) {
[weak self] selectType in
guard let self = self else { return }
self.spouse?.hkIdentity = selectType.title
self.loadBasicInfo()
}
} else if detailItem.type == .occupation {
let occupation = self.spouse?.occupation ?? ""
YHFormPickerView.show(type: .occupation, selectTitle:occupation ) {
[weak self] selectType in
guard let self = self else { return }
self.spouse?.occupation = selectType.title
self.loadBasicInfo()
}
} else if detailItem.type == .ownDegree {
let hasDegree = self.spouse?.hasDegree ?? "无学位"
YHFormPickerView.show(type: .ownDegree, selectTitle:hasDegree ) {
[weak self] selectType in
guard let self = self else { return }
let ownDegree = (selectType.title == YHFormPickerViewSubType.ownDegree(.hasDegree).title)
self.spouse?.setHasDegree(ownDegree)
self.loadBasicInfo()
}
}
}
} }
func createCorner(cell:UITableViewCell, arr:Array<Any>, indexPath:IndexPath) { func createCorner(cell:UITableViewCell, arr:Array<Any>, indexPath:IndexPath) {
......
...@@ -126,7 +126,7 @@ class YHSpouseInfoVC: YHBaseViewController, YHSpouseInfoVCProtocol { ...@@ -126,7 +126,7 @@ class YHSpouseInfoVC: YHBaseViewController, YHSpouseInfoVCProtocol {
self.view.addSubview(uploadVC.view) self.view.addSubview(uploadVC.view)
self.view.addSubview(initalInfoVC.view) self.view.addSubview(initalInfoVC.view)
stepView.dataSource = ["初始信息".local, "证件上传".local, "基本信息".local, "证件信息".local] stepView.dataSource = ["初始信息".local, "证件上传".local, "证件信息".local, "基本信息".local]
stepView.block = {[weak self] (index) in stepView.block = {[weak self] (index) in
guard let self = self else { return } guard let self = self else { return }
print("follow:%d", self.orderId) print("follow:%d", self.orderId)
...@@ -139,7 +139,7 @@ class YHSpouseInfoVC: YHBaseViewController, YHSpouseInfoVCProtocol { ...@@ -139,7 +139,7 @@ class YHSpouseInfoVC: YHBaseViewController, YHSpouseInfoVCProtocol {
self.view.addSubview(basicInfoVC.view) self.view.addSubview(basicInfoVC.view)
self.view.addSubview(initalInfoVC.view) self.view.addSubview(initalInfoVC.view)
stepView.dataSource = ["初始信息".local, "证件信息".local] stepView.dataSource = ["初始信息".local, "基本信息".local]
stepView.block = {[weak self] (index) in stepView.block = {[weak self] (index) in
guard let self = self else { return } guard let self = self else { return }
print("follow:%d", self.orderId) print("follow:%d", self.orderId)
...@@ -157,9 +157,7 @@ extension YHSpouseInfoVC { ...@@ -157,9 +157,7 @@ extension YHSpouseInfoVC {
guard let spouse = spouse else { return } guard let spouse = spouse else { return }
guard let info = spouse.toDictionary() else { return } guard let info = spouse.toDictionary() else { return }
let follow = spouse.follow
let dict:[String: Any] = ["orderId":self.orderId, let dict:[String: Any] = ["orderId":self.orderId,
"relation":spouse.relationType.rawValue, "relation":spouse.relationType.rawValue,
"step":spouse.step, "step":spouse.step,
......
...@@ -175,6 +175,7 @@ extension YHSpouseInitialInfoVC : UITableViewDelegate, UITableViewDataSource { ...@@ -175,6 +175,7 @@ extension YHSpouseInitialInfoVC : UITableViewDelegate, UITableViewDataSource {
if detailItem.type == .isAccompanyToHK || detailItem.type == .isHandleHKPassPort || detailItem.type == .isLiveTother || detailItem.type == .isLiveOverSeasMore1Year { if detailItem.type == .isAccompanyToHK || detailItem.type == .isHandleHKPassPort || detailItem.type == .isLiveTother || detailItem.type == .isLiveOverSeasMore1Year {
let cell = tableView.dequeueReusableCell(withIdentifier: YHFormItemDoubleChoiceCell.cellReuseIdentifier, for: indexPath) as! YHFormItemDoubleChoiceCell let cell = tableView.dequeueReusableCell(withIdentifier: YHFormItemDoubleChoiceCell.cellReuseIdentifier, for: indexPath) as! YHFormItemDoubleChoiceCell
cell.isMust = detailItem.isNeed
cell.title = detailItem.getTitle() cell.title = detailItem.getTitle()
var select = false var select = false
...@@ -345,7 +346,7 @@ extension YHSpouseInitialInfoVC : UITableViewDelegate, UITableViewDataSource { ...@@ -345,7 +346,7 @@ extension YHSpouseInitialInfoVC : UITableViewDelegate, UITableViewDataSource {
} }
self.present(vc, animated: true) self.present(vc, animated: true)
} }
} }
} }
......
...@@ -457,69 +457,81 @@ enum YHFamilyMemberType: Int { ...@@ -457,69 +457,81 @@ enum YHFamilyMemberType: Int {
class YHFamilyMember: SmartCodable, YHFormItemProtocol { class YHFamilyMember: SmartCodable, YHFormItemProtocol {
var id: Int = 0 var id: Int = 0
// 是否已故
var deceased: Int = 0 var deceased: Int = 0
var custody: Int = 0 var custody: Int = 0
// 国籍
var nationality: String? var nationality: String?
var orderId: Int = 0 var orderId: Int = 0
// 关系 1父亲 2母亲 3配偶 4子女 5兄弟姐妹
var relation: String? var relation: String?
// 是否拥有学位
var hasDegree: String? var hasDegree: String?
// mark any // mark any
// var hasDegreeJson: [YHHasDegreeJson]? // var hasDegreeJson: [YHHasDegreeJson]?
var hasDegreeJson: SmartAny? var hasDegreeJson: SmartAny?
// 是否随行至香港
var follow: Int = 0 var follow: Int = 0
var statement: Int = 0 var statement: Int = 0
// 姓名
var subsetName: String? var subsetName: String?
// mark any // mark any
// var subsetNamePinyin: YHSubsetNamePinyin? // var subsetNamePinyin: YHSubsetNamePinyin?
var subsetNamePinyin: SmartAny? var subsetNamePinyin: SmartAny?
// 曾用名
var usedName: String? var usedName: String?
// 出生日期
var birthday: String? var birthday: String?
// 出生国家地区 (国内/国外)
var birthPlaceAboard: Int = 0 var birthPlaceAboard: Int = 0
// mark any // 出生地址信息
// var birthPlace: YHAddress? var birthPlace: YHAddress?
var birthPlace: SmartAny?
// 职业
var occupation: String? var occupation: String?
// 职业名称
var occupationName: String? var occupationName: String?
// mark any // mark any
var operatorAme: SmartAny? var operatorAme: SmartAny?
// 香港身份证号
// mark any
// var childHasHkId: YHChildStepchildClass?
var childHasHkId: SmartAny?
var hkIdentityCard: String? var hkIdentityCard: String?
// 性别
var sex: Int = 0 var sex: Int = 0
// 婚姻状况
var married: String? var married: String?
// 是否与主申请人同住
var nows: Int = 0 var nows: Int = 0
// 居住地址
var address: YHAddress? var address: YHAddress?
// mark any // 香港身份证信息
// var childStepchild: YHChildStepchildClass? var childHasHkId: YHChildStepchildClass?
var childStepchild: SmartAny? var childStepchild: YHChildStepchildClass?
// 在港信息
// mark any var childInHk: YHChildStepchildClass?
// var childInHk: YHChildStepchildClass?
var childInHk: SmartAny?
// mark any // mark any
var countryIdentity: SmartAny? var countryIdentity: SmartAny?
// 在港身份
var hkIdentity: String? var hkIdentity: String?
var hkIdentityOther: String? var hkIdentityOther: String?
// 现居住国家
var liveCountry: String? var liveCountry: String?
// 是否要办理港澳通行证
var isHandled: Int = 0 var isHandled: Int = 0
var finishFollow: Int = 0 var finishFollow: Int = 0
var step: Int = 0 var step: Int = 0
// 未填写项数
var notFillNum: Int = 0 var notFillNum: Int = 0
// 是否在海外居住满1年及以上
var isLiveOverseaYear: Int = 0 var isLiveOverseaYear: Int = 0
// 婚前刑事
var surname: String? var surname: String?
// mark any // mark any
...@@ -577,8 +589,8 @@ class YHFamilyMember: SmartCodable, YHFormItemProtocol { ...@@ -577,8 +589,8 @@ class YHFamilyMember: SmartCodable, YHFormItemProtocol {
return follow == 1 return follow == 1
} }
func setFollow(_ follow:Bool) { func setFollow(_ value:Bool) {
self.follow = (follow ? 1 : 0) self.follow = (value ? 1 : 0)
} }
// 是否要办理港澳通行证 // 是否要办理港澳通行证
...@@ -586,8 +598,8 @@ class YHFamilyMember: SmartCodable, YHFormItemProtocol { ...@@ -586,8 +598,8 @@ class YHFamilyMember: SmartCodable, YHFormItemProtocol {
return self.isHandled == 1 return self.isHandled == 1
} }
func setNeedHandleHKPassPort(_ need:Bool) { func setNeedHandleHKPassPort(_ value:Bool) {
self.isHandled = (need ? 1 : 0) self.isHandled = (value ? 1 : 0)
} }
// 是否与主申请人同住 // 是否与主申请人同住
...@@ -595,8 +607,8 @@ class YHFamilyMember: SmartCodable, YHFormItemProtocol { ...@@ -595,8 +607,8 @@ class YHFamilyMember: SmartCodable, YHFormItemProtocol {
return self.nows == 1 return self.nows == 1
} }
func setLiveTother(_ together:Bool) { func setLiveTother(_ value:Bool) {
self.nows = (together ? 1 : 0) self.nows = (value ? 1 : 0)
} }
// 是否在海外居住满1年及以上 // 是否在海外居住满1年及以上
...@@ -608,6 +620,60 @@ class YHFamilyMember: SmartCodable, YHFormItemProtocol { ...@@ -608,6 +620,60 @@ class YHFamilyMember: SmartCodable, YHFormItemProtocol {
self.isLiveOverseaYear = value ? 1 : 0 self.isLiveOverseaYear = value ? 1 : 0
} }
// 是否出生国外
func isBirthOverSeas() -> Bool {
return self.birthPlaceAboard == 1
}
func setBirthOverSeas(_ value:Bool) {
return self.birthPlaceAboard = value ? 1 : 0
}
// 目前是否在港
func isNowInHK() -> Bool {
if let inHK = self.childInHk {
if inHK.has == "Y" {
return true
} else if inHK.has == "N" {
return false
}
}
return false
}
func setNowIsInHK(_ value:Bool) {
self.childInHk?.has = value ? "Y" : "N"
}
// 是否办理过香港身份证
func isHaveHKIdentityCard() -> Bool {
if let hasHkId = self.childHasHkId {
if hasHkId.has == "Y" {
return true
} else if hasHkId.has == "N" {
return false
}
}
return false
}
func setHaveHKIdentityCard(_ value:Bool) {
self.childHasHkId?.has = value ? "Y" : "N"
}
// 是否拥有学位
func hasDegreeStr() -> String? {
if hasDegree == "1" {
return "有学位"
} else {
return "无学位"
}
}
func setHasDegree(_ val:Bool) {
self.hasDegree = val ? "1" : "0"
}
var relationType:YHFamilyMemberType { var relationType:YHFamilyMemberType {
......
...@@ -21,6 +21,7 @@ ...@@ -21,6 +21,7 @@
print(selectType.title) print(selectType.title)
} }
*/ */
...@@ -30,17 +31,22 @@ enum YHFormPickerViewType: Int { ...@@ -30,17 +31,22 @@ enum YHFormPickerViewType: Int {
// 按自然顺序递增 // 按自然顺序递增
case none = 0 case none = 0
// 学位 // 学位
case degree = 1 case degree
// 学位有无
case ownDegree
// 婚姻 // 婚姻
case marriage = 2 case marriage
// 授课形式 // 授课形式
case edution = 3 case edution
// 职业 // 职业
case occupation = 4 case occupation
// 性别 // 性别
case gender = 5 case gender
// 证件 // 证件
case certificate = 6 case certificate
// 在港身份
case identity
} }
enum YHFormPickerViewSubType { enum YHFormPickerViewSubType {
...@@ -48,16 +54,23 @@ enum YHFormPickerViewSubType { ...@@ -48,16 +54,23 @@ enum YHFormPickerViewSubType {
case none case none
case marriage(YHPickerViewMarriageType) case marriage(YHPickerViewMarriageType)
case degree(YHPickerViewDegreeType) case degree(YHPickerViewDegreeType)
case ownDegree(YHPickerViewHasDegreeType)
case education(YHPickerViewEducationType) case education(YHPickerViewEducationType)
case occupation(YHPickerViewOccupationType) case occupation(YHPickerViewOccupationType)
case gender(YHPickerViewGenderType) case gender(YHPickerViewGenderType)
case certificate(YHPickerViewCertificateType) case certificate(YHPickerViewCertificateType)
case identity(YHPickerViewIdentityType)
var title:String { var title:String {
switch self { switch self {
case .none: case .none:
return "".local return "".local
case .ownDegree(.hasDegree):
return "有学位".local
case .ownDegree(.noDegree):
return "无学位".local
case .marriage(.unmarriage): case .marriage(.unmarriage):
return "未婚".local return "未婚".local
...@@ -112,87 +125,101 @@ enum YHFormPickerViewSubType { ...@@ -112,87 +125,101 @@ enum YHFormPickerViewSubType {
return "联合国通行证".local return "联合国通行证".local
case .certificate(.officialPassport): case .certificate(.officialPassport):
return "公务护照".local return "公务护照".local
case .identity(.student):
return "学生".local
case .identity(.employment):
return "就业".local
case .identity(.residence):
return "居留".local
case .identity(.visit):
return "访问".local
case .identity(.other):
return "其他".local
} }
} }
static func getType(_ title: String?) -> YHFormPickerViewSubType { var index:Int {
switch self {
guard let title = title else { return .none }
if title == "未婚".local {
return .marriage(.unmarriage)
} else if title == "已婚".local {
return .marriage(.marriaged)
} else if title == "分居".local {
return .marriage(.separated)
} else if title == "离婚".local {
return .marriage(.divorced)
} else if title == "丧偶".local {
return .marriage(.widowed)
} else if title == "学士学位".local { case .none:
return .degree(.bachelor) return 0
} else if title == "硕士学位".local {
return .degree(.master)
} else if title == "硕士学位".local {
return .degree(.doctor)
} else if title == "全日制".local { case .marriage(.unmarriage):
return .education(.fullTime) return 0
} else if title == "兼读制".local { case .marriage(.marriaged):
return .education(.partTime) return 1
} else if title == "遥距课程".local { case .marriage(.separated):
return .education(.distanceCourses) return 2
case .marriage(.divorced):
return 3
case .marriage(.widowed):
return 4
case .degree(.bachelor):
return 0
case .degree(.master):
return 1
case .degree(.doctor):
return 2
} else if title == "在职".local { case .education(.fullTime):
return .occupation(.onTheJob) return 0
} else if title == "退休".local { case .education(.partTime):
return .occupation(.retire) return 1
} else if title == "无业".local { case.education(.distanceCourses):
return .occupation(.unemployed) return 2
} else if title == "学生".local {
return .occupation(.student) case .occupation(.onTheJob):
return 0
} else if title == "男".local { case .occupation(.retire):
return .gender(.male) return 1
} else if title == "女".local { case .occupation(.unemployed):
return .gender(.female) return 2
case .occupation(.student):
return 3
case .gender(.male):
return 0
case .gender(.female):
return 1
} else if title == "护照".local { case .certificate(.passport):
return .certificate(.passport) return 0
} else if title == "外交护照".local { case .certificate(.travelPassport):
return .certificate(.diplomaticPassport) return 1
} else if title == "旅游通行证".local { case .certificate(.diplomaticPassport):
return .certificate(.travelPassport) return 2
} else if title == "公务护照".local { case .certificate(.chineseStatelessTravelPassport):
return .certificate(.officialPassport) return 3
} else if title == "中国发无国籍旅游证件".local { case .certificate(.otherStatelessTravelPassport):
return .certificate(.chineseStatelessTravelPassport) return 4
} else if title == "其他无国籍旅行证件".local { case .certificate(.unitedNationsPassport):
return .certificate(.otherStatelessTravelPassport) return 5
} else if title == "联合国通行证".local { case .certificate(.officialPassport):
return .certificate(.unitedNationsPassport) return 6
case .ownDegree(_):
return 0
case .identity(_):
return 1
} }
return .none
} }
} }
enum YHPickerViewMarriageType { enum YHPickerViewMarriageType: Int {
// 未婚 // 未婚
case unmarriage case unmarriage = 0
// 已婚 // 已婚
case marriaged case marriaged = 1
// 离婚 // 离婚
case divorced case divorced = 2
// 分居 // 分居
case separated case separated = 3
// 丧偶 // 丧偶
case widowed case widowed = 4
} }
enum YHPickerViewDegreeType { enum YHPickerViewDegreeType {
...@@ -224,29 +251,49 @@ enum YHPickerViewOccupationType { ...@@ -224,29 +251,49 @@ enum YHPickerViewOccupationType {
case student case student
} }
enum YHPickerViewGenderType { enum YHPickerViewGenderType: Int {
// 男 // 男
case male case male = 0
// 女 // 女
case female case female = 1
} }
enum YHPickerViewCertificateType { enum YHPickerViewCertificateType: Int {
// 护照 // 护照
case passport case passport = 0
// 外交护照 // 外交护照
case diplomaticPassport case diplomaticPassport = 1
// 公务护照 // 公务护照
case officialPassport case officialPassport = 2
// 中国发无国籍旅游证件 // 中国发无国籍旅游证件
case chineseStatelessTravelPassport case chineseStatelessTravelPassport = 3
// 旅游通行证 // 旅游通行证
case travelPassport case travelPassport = 4
// 联合国通行证 // 联合国通行证
case unitedNationsPassport case unitedNationsPassport = 5
// 其他无国籍旅行证件 // 其他无国籍旅行证件
case otherStatelessTravelPassport case otherStatelessTravelPassport = 6
}
enum YHPickerViewIdentityType {
// 学生
case student
// 就业
case employment
// 居留
case residence
// 访问
case visit
// 其他
case other
}
enum YHPickerViewHasDegreeType {
// 无学位
case noDegree
// 有学位
case hasDegree
} }
...@@ -266,14 +313,14 @@ class YHFormPickerView: UIView { ...@@ -266,14 +313,14 @@ class YHFormPickerView: UIView {
let type: YHFormPickerViewType let type: YHFormPickerViewType
var selectType:YHFormPickerViewSubType? private var selectType:YHFormPickerViewSubType?
var selectTitle:String? { private var selectTitle:String? {
didSet { didSet {
let type:YHFormPickerViewSubType = YHFormPickerViewSubType.getType(selectTitle) let type:YHFormPickerViewSubType = getSubType(selectTitle)
selectType = type selectType = type
} }
} }
var selectBlock:((YHFormPickerViewSubType)->Void)? private var selectBlock:((YHFormPickerViewSubType)->Void)?
var title: String? { var title: String? {
didSet { didSet {
...@@ -397,6 +444,19 @@ class YHFormPickerView: UIView { ...@@ -397,6 +444,19 @@ class YHFormPickerView: UIView {
YHFormPickerViewItem(type: .certificate(.travelPassport)), YHFormPickerViewItem(type: .certificate(.travelPassport)),
YHFormPickerViewItem(type: .certificate(.unitedNationsPassport)), YHFormPickerViewItem(type: .certificate(.unitedNationsPassport)),
YHFormPickerViewItem(type: .certificate(.otherStatelessTravelPassport))], YHFormPickerViewItem(type: .certificate(.otherStatelessTravelPassport))],
// 在港身份
.identity:
[YHFormPickerViewItem(type: .identity(.student)),
YHFormPickerViewItem(type: .identity(.employment)),
YHFormPickerViewItem(type: .identity(.residence)),
YHFormPickerViewItem(type: .identity(.visit)),
YHFormPickerViewItem(type: .identity(.other))],
.ownDegree:
[YHFormPickerViewItem(type: .ownDegree(.noDegree)),
YHFormPickerViewItem(type: .ownDegree(.hasDegree))]
] ]
}() }()
...@@ -541,6 +601,10 @@ class YHFormPickerView: UIView { ...@@ -541,6 +601,10 @@ class YHFormPickerView: UIView {
return "选择性别" return "选择性别"
case .certificate: case .certificate:
return "选择证件" return "选择证件"
case .identity:
return "选择在港身份"
case .ownDegree:
return "是否拥有学位"
} }
} }
} }
...@@ -597,3 +661,98 @@ extension YHFormPickerView: UIPickerViewDelegate, UIPickerViewDataSource { ...@@ -597,3 +661,98 @@ extension YHFormPickerView: UIPickerViewDelegate, UIPickerViewDataSource {
return label return label
} }
} }
extension YHFormPickerView {
func getSubType(_ title: String?) -> YHFormPickerViewSubType {
guard let title = title else { return .none }
switch type {
case .none:
return .none
case .degree:
if title == "学士学位".local {
return .degree(.bachelor)
} else if title == "硕士学位".local {
return .degree(.master)
} else if title == "硕士学位".local {
return .degree(.doctor)
}
case .marriage:
if title == "未婚".local {
return .marriage(.unmarriage)
} else if title == "已婚".local {
return .marriage(.marriaged)
} else if title == "分居".local {
return .marriage(.separated)
} else if title == "离婚".local {
return .marriage(.divorced)
} else if title == "丧偶".local {
return .marriage(.widowed)
}
case .edution:
if title == "全日制".local {
return .education(.fullTime)
} else if title == "兼读制".local {
return .education(.partTime)
} else if title == "遥距课程".local {
return .education(.distanceCourses)
}
case .occupation:
if title == "在职".local {
return .occupation(.onTheJob)
} else if title == "退休".local {
return .occupation(.retire)
} else if title == "无业".local {
return .occupation(.unemployed)
} else if title == "学生".local {
return .occupation(.student)
}
case .gender:
if title == "男".local {
return .gender(.male)
} else if title == "女".local {
return .gender(.female)
}
case .certificate:
if title == "护照".local {
return .certificate(.passport)
} else if title == "外交护照".local {
return .certificate(.diplomaticPassport)
} else if title == "旅游通行证".local {
return .certificate(.travelPassport)
} else if title == "公务护照".local {
return .certificate(.officialPassport)
} else if title == "中国发无国籍旅游证件".local {
return .certificate(.chineseStatelessTravelPassport)
} else if title == "其他无国籍旅行证件".local {
return .certificate(.otherStatelessTravelPassport)
} else if title == "联合国通行证".local {
return .certificate(.unitedNationsPassport)
}
case .identity:
if title == "学生".local {
return .identity(.student)
} else if title == "就业".local {
return .identity(.employment)
} else if title == "居留".local {
return .identity(.residence)
} else if title == "访问".local {
return .identity(.visit)
} else if title == "其他".local {
return .identity(.other)
}
case .ownDegree:
if title == "无学位".local {
return .ownDegree(.noDegree)
} else if title == "有学位".local {
return .ownDegree(.hasDegree)
}
}
return .none
}
}
...@@ -24,6 +24,7 @@ class YHFormChoiceItem { ...@@ -24,6 +24,7 @@ class YHFormChoiceItem {
class YHFormItemDoubleChoiceCell: UITableViewCell { class YHFormItemDoubleChoiceCell: UITableViewCell {
static let cellReuseIdentifier = "YHFormItemDoubleChoiceCell" static let cellReuseIdentifier = "YHFormItemDoubleChoiceCell"
private let btnWidth = 70.0 private let btnWidth = 70.0
private let btnHeight = 32.0 private let btnHeight = 32.0
private let btnTitleSelectColor = UIColor.brandMainColor private let btnTitleSelectColor = UIColor.brandMainColor
...@@ -32,21 +33,27 @@ class YHFormItemDoubleChoiceCell: UITableViewCell { ...@@ -32,21 +33,27 @@ class YHFormItemDoubleChoiceCell: UITableViewCell {
private let btnBgSelectColor = UIColor.brandMainColor.withAlphaComponent(0.08) private let btnBgSelectColor = UIColor.brandMainColor.withAlphaComponent(0.08)
private let answerBaseTag = 9527 private let answerBaseTag = 9527
// 是否必须字段
var isMust:Bool = false
var answerBlock:(([YHFormChoiceItem], Int)->Void)? var answerBlock:(([YHFormChoiceItem], Int)->Void)?
var title:String? { var title:String? {
didSet { didSet {
if let question = title { if let title = title, !title.isEmpty {
let str = "*"+question let str = (isMust ? ("*"+title) : title)
let attributes: [NSAttributedString.Key: Any] = [ let attributes: [NSAttributedString.Key: Any] = [
.font: UIFont.PFSC_R(ofSize: 14), .font: UIFont.PFSC_R(ofSize: 14),
.foregroundColor: UIColor.mainTextColor .foregroundColor: UIColor.mainTextColor]
]
let questionAttrStr = NSMutableAttributedString(string: str, attributes: attributes) let questionAttrStr = NSMutableAttributedString(string: str, attributes: attributes)
let starRange = NSRange(location: 0, length: 1) if isMust {
questionAttrStr.addAttribute(NSAttributedString.Key.foregroundColor, value: UIColor(hex:0xFF3A3A), range: starRange) let starRange = NSRange(location: 0, length: 1)
questionAttrStr.addAttribute(NSAttributedString.Key.foregroundColor, value: UIColor(hex:0xFF3A3A), range: starRange)
}
titleLabel.attributedText = questionAttrStr titleLabel.attributedText = questionAttrStr
} else {
titleLabel.text = ""
} }
} }
} }
...@@ -134,8 +141,6 @@ class YHFormItemDoubleChoiceCell: UITableViewCell { ...@@ -134,8 +141,6 @@ class YHFormItemDoubleChoiceCell: UITableViewCell {
func setupUI() { func setupUI() {
self.selectionStyle = .none self.selectionStyle = .none
title = " 1、是否曾在香港或其他地方因任何罪行或违法行为被定罪?是否曾在香港或其他地方因任何罪行或违法行为被定罪?是否曾在香港或其他地方因任何罪行或违法行为被定罪?是否曾在香港或其他地方因任何罪行或违法行为被定罪?是否曾在香港或其他地方因任何罪行或违法行为被定罪? "
contentView.addSubview(titleLabel) contentView.addSubview(titleLabel)
contentView.addSubview(answer2Btn) contentView.addSubview(answer2Btn)
......
...@@ -28,7 +28,7 @@ class YHFormItemEnterDetailCell: UITableViewCell { ...@@ -28,7 +28,7 @@ class YHFormItemEnterDetailCell: UITableViewCell {
var title:String? { var title:String? {
didSet { didSet {
if let title = title { if let title = title, !title.isEmpty {
let str = (isMust ? ("*"+title) : title) let str = (isMust ? ("*"+title) : title)
let attributes: [NSAttributedString.Key: Any] = [ let attributes: [NSAttributedString.Key: Any] = [
.font: titleFont, .font: titleFont,
...@@ -40,6 +40,8 @@ class YHFormItemEnterDetailCell: UITableViewCell { ...@@ -40,6 +40,8 @@ class YHFormItemEnterDetailCell: UITableViewCell {
questionAttrStr.addAttribute(NSAttributedString.Key.foregroundColor, value: UIColor(hex:0xFF3A3A), range: starRange) questionAttrStr.addAttribute(NSAttributedString.Key.foregroundColor, value: UIColor(hex:0xFF3A3A), range: starRange)
} }
titleLabel.attributedText = questionAttrStr titleLabel.attributedText = questionAttrStr
} else {
titleLabel.text = ""
} }
} }
} }
......
...@@ -20,7 +20,7 @@ class YHFormItemExpireDateCell: UITableViewCell { ...@@ -20,7 +20,7 @@ class YHFormItemExpireDateCell: UITableViewCell {
var title:String? { var title:String? {
didSet { didSet {
if let title = title { if let title = title, !title.isEmpty {
let str = (isMust ? ("*"+title) : title) let str = (isMust ? ("*"+title) : title)
let attributes: [NSAttributedString.Key: Any] = [ let attributes: [NSAttributedString.Key: Any] = [
.font: UIFont.PFSC_R(ofSize: 14), .font: UIFont.PFSC_R(ofSize: 14),
...@@ -31,6 +31,8 @@ class YHFormItemExpireDateCell: UITableViewCell { ...@@ -31,6 +31,8 @@ class YHFormItemExpireDateCell: UITableViewCell {
questionAttrStr.addAttribute(NSAttributedString.Key.foregroundColor, value: UIColor(hex:0xFF3A3A), range: starRange) questionAttrStr.addAttribute(NSAttributedString.Key.foregroundColor, value: UIColor(hex:0xFF3A3A), range: starRange)
} }
titleLabel.attributedText = questionAttrStr titleLabel.attributedText = questionAttrStr
} else {
titleLabel.text = ""
} }
} }
} }
......
...@@ -65,7 +65,7 @@ class YHFormItemInputTextCell: UITableViewCell { ...@@ -65,7 +65,7 @@ class YHFormItemInputTextCell: UITableViewCell {
private lazy var textField:UITextField = { private lazy var textField:UITextField = {
let textField = UITextField() let textField = UITextField()
textField.backgroundColor = .clear textField.backgroundColor = .clear
textField.placeholder = "请如实填写" textField.placeholder = "请输入"
textField.font = UIFont.PFSC_M(ofSize: 14) textField.font = UIFont.PFSC_M(ofSize: 14)
textField.tintColor = UIColor.mainTextColor textField.tintColor = UIColor.mainTextColor
textField.textColor = UIColor.mainTextColor textField.textColor = UIColor.mainTextColor
......
...@@ -28,17 +28,22 @@ class YHMainApplicantInformationViewController: YHBaseViewController { ...@@ -28,17 +28,22 @@ class YHMainApplicantInformationViewController: YHBaseViewController {
func getData() { func getData() {
viewModel.requestMainInformation("133969") {[weak self] success, error in viewModel.requestMainInformation("133969") {[weak self] success, error in
guard let self = self else { return } guard let self = self else { return }
if self.stepView.currentIndex == 0 { self.stepView.currentIndex = self.viewModel.mainModel.step ?? 0
self.dataSource = self.viewModel.getBaseDataSource() self.updateDataSource()
} else if self.stepView.currentIndex == 1 { }
self.dataSource = self.viewModel.getIDCardDataSource() }
} else if self.stepView.currentIndex == 2 {
self.dataSource = self.viewModel.getDocumentInformation() func updateDataSource() {
} else if self.stepView.currentIndex == 3 { if self.stepView.currentIndex == 0 {
self.dataSource = self.viewModel.getDetailDataSource() self.dataSource = self.viewModel.getBaseDataSource()
} } else if self.stepView.currentIndex == 1 {
self.tableView.reloadData() self.dataSource = self.viewModel.getIDCardDataSource()
} else if self.stepView.currentIndex == 2 {
self.dataSource = self.viewModel.getDocumentInformation()
} else if self.stepView.currentIndex == 3 {
self.dataSource = self.viewModel.getDetailDataSource()
} }
self.tableView.reloadData()
} }
func setView() { func setView() {
...@@ -47,7 +52,7 @@ class YHMainApplicantInformationViewController: YHBaseViewController { ...@@ -47,7 +52,7 @@ class YHMainApplicantInformationViewController: YHBaseViewController {
step.dataSource = ["初始信息", "证件上传", "基本信息", "证件信息"] step.dataSource = ["初始信息", "证件上传", "基本信息", "证件信息"]
step.block = { [weak self] (index) in step.block = { [weak self] (index) in
guard let self = self else { return } guard let self = self else { return }
self.getData() self.updateDataSource()
} }
return step return step
}() }()
...@@ -80,10 +85,20 @@ class YHMainApplicantInformationViewController: YHBaseViewController { ...@@ -80,10 +85,20 @@ class YHMainApplicantInformationViewController: YHBaseViewController {
bottomView = { bottomView = {
let bottom = YHBottomNextView() let bottom = YHBottomNextView()
bottom.block = { [weak self] in bottom.nextblock = { [weak self] in
guard let self = self else { return } guard let self = self else { return }
self.stepView.currentIndex = self.stepView.currentIndex + 1 self.stepView.currentIndex = self.stepView.currentIndex + 1
self.getData() self.viewModel.updateMainInformation(.submit) {[weak self] success in
guard let self = self else { return }
self.stepView.currentIndex = self.stepView.currentIndex
self.updateDataSource()
}
}
bottom.saveBlock = { [weak self] in
guard let self = self else { return }
self.viewModel.updateMainInformation(.save) {[weak self] success in
guard let self = self else { return }
}
} }
return bottom return bottom
}() }()
...@@ -110,6 +125,10 @@ extension YHMainApplicantInformationViewController: UITableViewDelegate, UITable ...@@ -110,6 +125,10 @@ extension YHMainApplicantInformationViewController: UITableViewDelegate, UITable
} else { } else {
let cell = tableView.dequeueReusableCell(withClass: YHMainInformationTableViewCell.self) let cell = tableView.dequeueReusableCell(withClass: YHMainInformationTableViewCell.self)
cell.dataSource = dataSource?[indexPath.row] cell.dataSource = dataSource?[indexPath.row]
cell.informationBlock = {[weak self] model in
guard let self = self else { return }
self.viewModel.updateModel(model)
}
return cell return cell
} }
} }
......
...@@ -10,7 +10,8 @@ import UIKit ...@@ -10,7 +10,8 @@ import UIKit
class YHBottomNextView: UIView { class YHBottomNextView: UIView {
typealias Block = () -> () typealias Block = () -> ()
var block: Block? var nextblock: Block?
var saveBlock: Block?
var saveButton: UIButton! var saveButton: UIButton!
var nextButton: UIButton! var nextButton: UIButton!
...@@ -66,11 +67,13 @@ class YHBottomNextView: UIView { ...@@ -66,11 +67,13 @@ class YHBottomNextView: UIView {
@objc func save() { @objc func save() {
if let block = saveBlock {
block()
}
} }
@objc func goNext() { @objc func goNext() {
if let block = block { if let block = nextblock {
block() block()
} }
} }
......
...@@ -9,8 +9,8 @@ ...@@ -9,8 +9,8 @@
import UIKit import UIKit
class YHItemView: UIView { class YHItemView: UIView {
typealias Block = (_ model: YHItemModel) -> () typealias ItemBlock = (_ model: YHItemModel) -> ()
var block: Block? var block: ItemBlock?
var titleLabel: UILabel! var titleLabel: UILabel!
var messageTextField: UITextField! var messageTextField: UITextField!
var nextStepImageView: UIImageView! var nextStepImageView: UIImageView!
...@@ -139,16 +139,31 @@ class YHItemView: UIView { ...@@ -139,16 +139,31 @@ class YHItemView: UIView {
let questionAttrStr = NSMutableAttributedString(string: str, attributes: attributes) let questionAttrStr = NSMutableAttributedString(string: str, attributes: attributes)
titleLabel.attributedText = questionAttrStr titleLabel.attributedText = questionAttrStr
} }
messageTextField.placeholder = dataSource.prompts
messageTextField.text = dataSource.message
if dataSource.isUserKeyBoard ?? false { if dataSource.isUserKeyBoard ?? false {
nextStepImageView.isHidden = true nextStepImageView.isHidden = true
centerButton.isHidden = true centerButton.isHidden = true
} else { } else {
if let type = dataSource.type {
switch type {
case .normal: break
case .address: break
case .time: break
case .image: break
case .id:
messageTextField.text = YHFormPickerViewSubType.certificate(YHPickerViewCertificateType(rawValue: dataSource.message?.int ?? 0) ?? .chineseStatelessTravelPassport).title
case .country: break
case .sex:
messageTextField.text = YHFormPickerViewSubType.gender(YHPickerViewGenderType(rawValue: dataSource.message?.int ?? 0) ?? .female).title
case .marry:
messageTextField.text = YHFormPickerViewSubType.marriage(YHPickerViewMarriageType(rawValue: dataSource.message?.int ?? 0) ?? .unmarriage).title
}
}
nextStepImageView.isHidden = false nextStepImageView.isHidden = false
centerButton.isHidden = false centerButton.isHidden = false
} }
messageTextField.placeholder = dataSource.prompts
messageTextField.text = dataSource.message
if (dataSource.leftButtonString != nil) { if (dataSource.leftButtonString != nil) {
leftButton.isHidden = false leftButton.isHidden = false
leftButton.setTitle(dataSource.leftButtonString, for: .normal) leftButton.setTitle(dataSource.leftButtonString, for: .normal)
...@@ -234,6 +249,9 @@ class YHItemView: UIView { ...@@ -234,6 +249,9 @@ class YHItemView: UIView {
self.dataSource?.message = address self.dataSource?.message = address
self.dataSource?.value = [province, city, area] self.dataSource?.value = [province, city, area]
self.updateAllViews() self.updateAllViews()
if let block = self.block {
block(self.dataSource ?? YHItemModel())
}
} }
UIViewController.current?.present(addressPicker, animated: true, completion: nil) UIViewController.current?.present(addressPicker, animated: true, completion: nil)
case .time: case .time:
...@@ -242,12 +260,18 @@ class YHItemView: UIView { ...@@ -242,12 +260,18 @@ class YHItemView: UIView {
// [yyyy, mm, dd] eg ["2024", "01", "20"] // [yyyy, mm, dd] eg ["2024", "01", "20"]
self.dataSource?.message = date self.dataSource?.message = date
self.updateAllViews() self.updateAllViews()
if let block = self.block {
block(self.dataSource ?? YHItemModel())
}
} }
case .image: case .image:
let view = YHImagePickerView(frame: CGRect(x: 0, y: 0, width: KScreenWidth, height: KScreenHeight)) let view = YHImagePickerView(frame: CGRect(x: 0, y: 0, width: KScreenWidth, height: KScreenHeight))
view.backImage = { [weak self] image in view.backImage = { [weak self] image in
guard let self = self else { return } guard let self = self else { return }
self.updateAllViews() self.updateAllViews()
if let block = block {
block(dataSource ?? YHItemModel())
}
} }
let window = UIApplication.shared.yhKeyWindow() let window = UIApplication.shared.yhKeyWindow()
window?.addSubview(view) window?.addSubview(view)
...@@ -255,26 +279,41 @@ class YHItemView: UIView { ...@@ -255,26 +279,41 @@ class YHItemView: UIView {
YHFormPickerView.show(type: .certificate, selectTitle: "公务通行证") { selectType in YHFormPickerView.show(type: .certificate, selectTitle: "公务通行证") { selectType in
// 选择类型的标题 // 选择类型的标题
self.dataSource?.message = selectType.title self.dataSource?.message = selectType.title
self.dataSource?.value = ["\(selectType.index)"]
self.updateAllViews() self.updateAllViews()
if let block = self.block {
block(self.dataSource ?? YHItemModel())
}
} }
case .country: case .country:
let vc = YHSelectCountryViewController() let vc = YHSelectCountryViewController()
vc.backLocationStringController = { (country) in vc.backLocationStringController = { (country) in
self.dataSource?.message = country self.dataSource?.message = country
self.updateAllViews() self.updateAllViews()
if let block = self.block {
block(self.dataSource ?? YHItemModel())
}
} }
UIViewController.current?.navigationController?.pushViewController(vc) UIViewController.current?.navigationController?.pushViewController(vc)
case .sex: case .sex:
YHFormPickerView.show(type: .gender, selectType: .gender(.female)) { selectType in YHFormPickerView.show(type: .gender, selectType: .gender(.female)) { selectType in
// 选择类型的标题 // 选择类型的标题
self.dataSource?.message = selectType.title self.dataSource?.message = selectType.title
self.dataSource?.value = ["\(selectType.index)"]
self.updateAllViews() self.updateAllViews()
if let block = self.block {
block(self.dataSource ?? YHItemModel())
}
} }
case .marry: case .marry:
YHFormPickerView.show(type: .marriage, selectType: .marriage(.divorced)) { selectType in YHFormPickerView.show(type: .marriage, selectType: .marriage(.divorced)) { selectType in
// 选择类型的标题 // 选择类型的标题
self.dataSource?.message = selectType.title self.dataSource?.message = selectType.title
self.dataSource?.value = ["\(selectType.index)"]
self.updateAllViews() self.updateAllViews()
if let block = self.block {
block(self.dataSource ?? YHItemModel())
}
} }
} }
} }
......
...@@ -9,6 +9,8 @@ ...@@ -9,6 +9,8 @@
import UIKit import UIKit
class YHMainInformationTableViewCell: UITableViewCell { class YHMainInformationTableViewCell: UITableViewCell {
typealias InformationBlock = (_ model: YHItemModel) -> ()
var informationBlock: InformationBlock?
var centerView: UIView! var centerView: UIView!
var titleLabel: UILabel! var titleLabel: UILabel!
var mainItemView: UIView! var mainItemView: UIView!
...@@ -96,6 +98,12 @@ class YHMainInformationTableViewCell: UITableViewCell { ...@@ -96,6 +98,12 @@ class YHMainInformationTableViewCell: UITableViewCell {
} }
let itemView = YHItemView() let itemView = YHItemView()
itemView.dataSource = dataSource?.models?[i] itemView.dataSource = dataSource?.models?[i]
itemView.block = {[weak self] model in
guard let self = self else { return }
if let block = self.informationBlock {
block(model)
}
}
mainItemView.addSubview(itemView) mainItemView.addSubview(itemView)
itemView.snp.makeConstraints { make in itemView.snp.makeConstraints { make in
make.left.equalTo(18) make.left.equalTo(18)
......
...@@ -8,6 +8,12 @@ ...@@ -8,6 +8,12 @@
import UIKit import UIKit
enum YHSaveType: Int {
case save = 0
case submit = 1
}
class YHMainApplicantInformationViewModel: YHBaseViewModel { class YHMainApplicantInformationViewModel: YHBaseViewModel {
var mainModel: YHMainInformationModel = YHMainInformationModel() var mainModel: YHMainInformationModel = YHMainInformationModel()
...@@ -93,6 +99,76 @@ class YHMainApplicantInformationViewModel: YHBaseViewModel { ...@@ -93,6 +99,76 @@ class YHMainApplicantInformationViewModel: YHBaseViewModel {
return [section, section1] return [section, section1]
} }
func updateModel(_ item: YHItemModel) {
guard let type = item.id else { return }
switch type {
case .id1:
mainModel.nationality = item.message
case .id2:
mainModel.address?.country = item.message
case .id3:
mainModel.address?.area = item.value
case .id4:
mainModel.address?.details = item.message
case .id5:
mainModel.has_hk_id = item.value?.first?.int
case .id6:
printLog("1")
case .id7:
printLog("1")
case .id8:
mainModel.certificates?.cn_identity_card?.number = item.message
case .id9:
mainModel.certificates?.cn_identity_card?.issue_at = item.message
case .id10:
mainModel.certificates?.cn_identity_card?.issue_date_start_at = item.message
case .id11:
mainModel.certificates?.cn_identity_card?.issue_date_end_at = item.message
case .id12:
mainModel.certificates?.hk_macao_pass?.number = item.message
case .id13:
mainModel.certificates?.hk_macao_pass?.issue_at = item.message
case .id14:
mainModel.certificates?.hk_macao_pass?.issue_date_start_at = item.message
case .id15:
mainModel.certificates?.hk_macao_pass?.issue_date_end_at = item.message
case .id16:
mainModel.certificates?.passport?.passport_type = item.value?.first
case .id17:
mainModel.certificates?.passport?.number = item.message
case .id18:
mainModel.certificates?.passport?.issue_at = item.message
case .id19:
mainModel.certificates?.passport?.issue_date_start_at = item.message
case .id20:
mainModel.certificates?.passport?.issue_date_end_at = item.message
case .id21:
mainModel.username = item.message
case .id22:
mainModel.used_name = item.message
case .id23:
mainModel.surname = item.message
case .id24:
mainModel.birthday = item.message
case .id25:
printLog("1")
case .id26:
mainModel.birth_place?.area = item.value
case .id27:
mainModel.sex = item.value?.first
case .id28:
mainModel.married = item.value?.first
case .id29:
mainModel.mobile = item.message
case .id30:
mainModel.email = item.message
case .id31:
mainModel.has_hk_id = item.value?.first?.int
}
}
func requestMainInformation(_ orderID: String, callBackBlock:@escaping (_ success: YHMainInformationModel?, _ error:YHErrorModel?)->()) { func requestMainInformation(_ orderID: String, callBackBlock:@escaping (_ success: YHMainInformationModel?, _ error:YHErrorModel?)->()) {
let strUrl = YHBaseUrlManager.shared.curURL() + "frontend/order-information/get_information?order_id=\(orderID)" let strUrl = YHBaseUrlManager.shared.curURL() + "frontend/order-information/get_information?order_id=\(orderID)"
let _ = YHNetRequest.getRequest(url: strUrl) { [weak self] json, code in let _ = YHNetRequest.getRequest(url: strUrl) { [weak self] json, code in
...@@ -115,4 +191,77 @@ class YHMainApplicantInformationViewModel: YHBaseViewModel { ...@@ -115,4 +191,77 @@ class YHMainApplicantInformationViewModel: YHBaseViewModel {
callBackBlock(nil,err) callBackBlock(nil,err)
} }
} }
func updateMainInformation(_ saveType: YHSaveType, callBackBlock:@escaping (_ success: Bool)->()) {
var type = ""
if saveType == .save {
type = "save"
} else {
type = "submit"
}
let area: [String] = mainModel.address?.area ?? []
let birthArea: [String] = mainModel.birth_place?.area ?? []
let address = ["area": area,
"country": mainModel.address?.country ?? "",
"details": mainModel.address?.details ?? "",
"foreign": mainModel.address?.foreign ?? ""] as [String : Any]
let birthPlace = ["area": birthArea,
"country": mainModel.birth_place?.country ?? "",
"details": mainModel.birth_place?.details ?? "",
"foreign": mainModel.birth_place?.foreign ?? ""] as [String : Any]
let cnID = ["img_back": mainModel.certificates?.cn_identity_card?.img_back ?? "",
"img_front": mainModel.certificates?.cn_identity_card?.img_front ?? "",
"issue_at": mainModel.certificates?.cn_identity_card?.issue_at ?? "",
"issue_date_end_at": mainModel.certificates?.cn_identity_card?.issue_date_end_at ?? "",
"issue_date_start_at": mainModel.certificates?.cn_identity_card?.issue_date_start_at ?? "",
"number": mainModel.certificates?.cn_identity_card?.number ?? ""] as [String : Any]
let hkID = ["img_back": mainModel.certificates?.hk_macao_pass?.img_back ?? "",
"img_front": mainModel.certificates?.hk_macao_pass?.img_front ?? "",
"issue_at": mainModel.certificates?.hk_macao_pass?.issue_at ?? "",
"issue_date_end_at": mainModel.certificates?.hk_macao_pass?.issue_date_end_at ?? "",
"issue_date_start_at": mainModel.certificates?.hk_macao_pass?.issue_date_start_at ?? "",
"number": mainModel.certificates?.hk_macao_pass?.number ?? ""] as [String : Any]
let passport = ["img_back": mainModel.certificates?.passport?.img_back ?? "",
"img_front": mainModel.certificates?.passport?.img_front ?? "",
"issue_at": mainModel.certificates?.passport?.issue_at ?? "",
"issue_date_end_at": mainModel.certificates?.passport?.issue_date_end_at ?? "",
"issue_date_start_at": mainModel.certificates?.passport?.issue_date_start_at ?? "",
"number": mainModel.certificates?.passport?.number ?? "",
"passport_type": mainModel.certificates?.passport?.passport_type ?? 0] as [String : Any]
let params: [String : Any] = ["address": address,
"address_aboard": mainModel.address_aboard ?? 0,
"age":mainModel.age ?? "",
"birth_place": birthPlace,
"birth_place_aboard": mainModel.birth_place_aboard ?? 0,
"birthday": mainModel.birthday ?? "",
"email": mainModel.email ?? "",
"has_hk_id": mainModel.has_hk_id ?? 0,
"hk_id_number": mainModel.hk_id_number ?? "",
"id": mainModel.id ?? 0,
"is_handled": mainModel.is_handled ?? "",
"is_live_oversea_year": mainModel.is_live_oversea_year ?? 0,
"married": mainModel.married ?? 0,
"mobile": mainModel.mobile ?? "",
"nationality": mainModel.nationality ?? "",
"order_id": mainModel.order_id ?? "",
"sex": mainModel.sex ?? 0,
"step": mainModel.step ?? 0,
"surname": mainModel.surname ?? "",
"used_name": mainModel.used_name ?? "",
"username": mainModel.username ?? "",
"save_type": type,
"username_pinyin": ["family_name": mainModel.username_pinyin?.family_name ?? "",
"given_name": mainModel.username_pinyin?.given_name ?? ""],
"certificates":["cn_identity_card": cnID,
"hk_macao_pass": hkID,
"passport": passport]
]
let strUrl = YHBaseUrlManager.shared.curURL() + "frontend/order-information/update_information"
let _ = YHNetRequest.postRequest(url: strUrl, params: params) { [weak self] json, code in
guard let self = self else { return }
callBackBlock(true)
} failBlock: { err in
callBackBlock(false)
}
}
} }
...@@ -18,7 +18,6 @@ import CryptoSwift ...@@ -18,7 +18,6 @@ import CryptoSwift
// var responseErrorType: NetResponseErrorType = .failType // var responseErrorType: NetResponseErrorType = .failType
//} //}
//定义客户端通用的错误码 //定义客户端通用的错误码
public enum YHErrorCode : Int32 { public enum YHErrorCode : Int32 {
case success = 0 case success = 0
...@@ -93,10 +92,7 @@ class YHNetRequest: NSObject { ...@@ -93,10 +92,7 @@ class YHNetRequest: NSObject {
print("sign = \(sign)") print("sign = \(sign)")
requestHeader.add(name:"sign",value:sign) requestHeader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kMDRiNTRhIn0=")
headers = requestHeader headers = requestHeader
} }
......
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