Commit 6c7e0872 authored by David黄金龙's avatar David黄金龙

Merge commit '9fd764fd' into davidhuang

* commit '9fd764fd':
  // 兄弟姐妹信息填写
  // 选择器
parents 91c3d6e7 9fd764fd
......@@ -29,6 +29,7 @@
042FBBC92B64DC8900F9DE23 /* YHFormItemExpireDateCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 042FBBC82B64DC8900F9DE23 /* YHFormItemExpireDateCell.swift */; };
042FBBCB2B65058000F9DE23 /* YHChildBasicInfoVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 042FBBCA2B65058000F9DE23 /* YHChildBasicInfoVC.swift */; };
042FBBD42B67A2FE00F9DE23 /* YHFormPickerView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 042FBBD32B67A2F900F9DE23 /* YHFormPickerView.swift */; };
042FBBD62B67BDD500F9DE23 /* YHBrotherInfoVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 042FBBD52B67BDD500F9DE23 /* YHBrotherInfoVC.swift */; };
0468D4202B49320900CFB916 /* YHVerificationCodeLoginController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0468D41F2B49320900CFB916 /* YHVerificationCodeLoginController.swift */; };
0468D4222B493A5E00CFB916 /* YHPhoneMessageView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0468D4212B493A5E00CFB916 /* YHPhoneMessageView.swift */; };
0468D4242B494BEA00CFB916 /* YHCodeResultViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0468D4232B494BEA00CFB916 /* YHCodeResultViewController.swift */; };
......@@ -213,6 +214,7 @@
042FBBC82B64DC8900F9DE23 /* YHFormItemExpireDateCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHFormItemExpireDateCell.swift; sourceTree = "<group>"; };
042FBBCA2B65058000F9DE23 /* YHChildBasicInfoVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHChildBasicInfoVC.swift; sourceTree = "<group>"; };
042FBBD32B67A2F900F9DE23 /* YHFormPickerView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = YHFormPickerView.swift; sourceTree = "<group>"; };
042FBBD52B67BDD500F9DE23 /* YHBrotherInfoVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHBrotherInfoVC.swift; sourceTree = "<group>"; };
0468D41F2B49320900CFB916 /* YHVerificationCodeLoginController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVerificationCodeLoginController.swift; sourceTree = "<group>"; };
0468D4212B493A5E00CFB916 /* YHPhoneMessageView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHPhoneMessageView.swift; sourceTree = "<group>"; };
0468D4232B494BEA00CFB916 /* YHCodeResultViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHCodeResultViewController.swift; sourceTree = "<group>"; };
......@@ -425,6 +427,7 @@
042FBBC22B63DA4C00F9DE23 /* YHParentInfoVC.swift */,
042FBBC62B64CFBF00F9DE23 /* YHChildInitialInfoVC.swift */,
042FBBCA2B65058000F9DE23 /* YHChildBasicInfoVC.swift */,
042FBBD52B67BDD500F9DE23 /* YHBrotherInfoVC.swift */,
);
path = C;
sourceTree = "<group>";
......@@ -1244,6 +1247,7 @@
042FBBB92B627C0F00F9DE23 /* YHCertificateInfo.swift in Sources */,
A5ACE93F2B4564F7002C94D2 /* UIViewController+Extension.swift in Sources */,
A5FD63E12B66592300D1D9DA /* YHScoreItemCellForAge.swift in Sources */,
042FBBD62B67BDD500F9DE23 /* YHBrotherInfoVC.swift in Sources */,
A5ACE9472B4564F7002C94D2 /* YHHUD.swift in Sources */,
A5ACE9412B4564F7002C94D2 /* Dictionary+Extension.swift in Sources */,
A5C5B3102B57677300A7C5D1 /* YHGestureTableView.swift in Sources */,
......
......@@ -7,6 +7,7 @@
//
import UIKit
import IQKeyboardManagerSwift
enum YHFormTitleItemEditType:Int {
case none = 1
......@@ -628,11 +629,11 @@ extension YHFamilyMemberFormVC : UITableViewDelegate, UITableViewDataSource {
func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
let picker = YHFormPickerView(type: .marriage)
picker.selectTitle = "女"
picker.selectType = .marriage(.separated)
picker.show()
return
IQKeyboardManager.shared.enable = true
let caseList = YHFormTitleItemType.allCases.map({ "\($0)" }).joined(separator: ", ")
print(caseList)
let arr = items[indexPath.section]
let item:YHFormItemProtocol = arr[indexPath.row]
......@@ -677,6 +678,15 @@ extension YHFamilyMemberFormVC : UITableViewDelegate, UITableViewDataSource {
self.navigationController?.pushViewController(vc)
return
}
// 兄弟姐妹
if item is YHBrother {
let brother = item as! YHBrother
let vc = YHBrotherInfoVC()
vc.brotherInfo = brother
self.navigationController?.pushViewController(vc)
return
}
}
func createCorner(cell:UITableViewCell, arr:Array<Any>, indexPath:IndexPath) {
......
......@@ -16,52 +16,54 @@ protocol YHFormItemProtocol {
}
// 表单标题类型
enum YHFormTitleItemType:Int {
enum YHFormTitleItemType:Int, CaseIterable {
// 配偶
case sponse = 1
// 父母
case parent = 2
case parent
// 子女
case child = 3
case child
// 兄弟姐妹
case brother = 4
case brother
// 随行
case accompany = 5
case accompany
// 国籍
case country = 6
case country
// 居住信息
case liveInfo = 7
case liveInfo
// 港澳通信证
case hkAndMacaoPassport = 8
case hkAndMacaoPassport
// 中国身份证
case chinaIdCardInfo = 9
case chinaIdCardInfo
// 护照
case passPortInfo = 10
case passPortInfo
// 配偶信息
case spouseInfo = 11
case spouseInfo
// 职业信息
case occupationInfo = 12
case occupationInfo
// 学历学位信息
case degreeInfo = 13
case degreeInfo
// 在港信息
case inHongKongInfo = 14
case inHongKongInfo
// 香港身份证
case hkIdentityCardInfo = 15
case hkIdentityCardInfo
// 父亲信息
case fatherInfo = 16
case fatherInfo
// 母亲信息
case motherInfo = 17
case motherInfo
// 基本信息
case basicInfo = 18
case basicInfo
// 子女信息
case childInfo = 19
case childInfo
// 是否前次婚姻子女
case isPreviousMarriageChild = 20
case isPreviousMarriageChild
// 兄弟姐妹信息
case brotherInfo
}
......@@ -69,8 +71,8 @@ enum YHFormTitleItemType:Int {
enum YHFormAddItemType:Int {
case addChild = 1
case addBrother = 2
case addDegree = 3
case addBrother
case addDegree
}
// 表单具体条目类型
......@@ -79,76 +81,78 @@ enum YHFormDetailItemType:Int {
// 是否随行至香港
case isAccompanyToHK = 1
// 是否与主申请人同住
case isLiveTother = 3
case isLiveTother
// 国家/地区
case nationOrArea = 4
case nationOrArea
// 现居住城市
case liveCity = 5
case liveCity
// 详细地址
case detailAddress = 6
case detailAddress
// 是否办理
case isHandleHKPassPort = 7
case isHandleHKPassPort
// 证件类别
case cetificateType = 8
case cetificateType
// 证件号码
case certificateNumber = 9
case certificateNumber
// 签发日期
case certificateSignDate = 10
case certificateSignDate
// 届满日期
case certificateValidDate = 11
case certificateValidDate
// 签发地
case certificateSignPlace = 12
case certificateSignPlace
// 配偶姓名
case spouseName = 13
case spouseName
// 曾用名
case everName = 14
case everName
// 婚前姓氏
case befourMarryFirstName = 15
case befourMarryFirstName
// 出生日期
case birthday = 16
case birthday
// 出生国家/地区
case birthNation = 17
case birthNation
// 出生城市
case birthCity = 18
case birthCity
// 职业
case occupation = 19
case occupation
// 职业名称
case occupationName = 20
case occupationName
// 是否拥有学位
case ownDegree = 21
case ownDegree
// 目前是否在港
case isNowInHK = 22
case isNowInHK
// 获准逗留至
case stayHKDate = 23
case stayHKDate
// 在港身份
case roleInHK = 24
case roleInHK
// 是否办理过(香港身份证)
case isHaveHkIdentityCard = 25
case isHaveHkIdentityCard
// 香港身份证号码
case hkIdentityCardNumber = 26
case hkIdentityCardNumber
// 学位信息X
case degreeDetailInfo = 27
case degreeDetailInfo
// 父亲姓名
case fatherName = 28
case fatherName
// 母亲姓名
case motherName = 29
case motherName
// 婚姻状况
case marriageState = 30
case marriageState
// 现居住国家/地区
case liveNationOrArea = 31
case liveNationOrArea
// 仅有两个按钮 标题数组有外部提供
case onlyDoubleChoice = 32
case onlyDoubleChoice
// 主申请人和现配偶是否拥有孩子抚养权
case ownCustody = 33
case ownCustody
// 子女姓名
case childName = 34
case childName
// 性别
case gender = 35
case gender
// 是否为前次婚姻子女
case isPreviousMarriageChild = 36
case isPreviousMarriageChild
// 兄弟姐妹姓名
case brotherName
}
......@@ -230,6 +234,8 @@ class YHFormTitleItem : YHFormItemProtocol {
return "子女信息".local
case .isPreviousMarriageChild:
return "是否前次婚姻子女".local
case .brotherInfo:
return "兄弟姐妹信息".local
}
}
......@@ -276,6 +282,8 @@ class YHFormTitleItem : YHFormItemProtocol {
return "".local
case .childInfo:
return "".local
case .brotherInfo:
return "".local
}
......@@ -402,6 +410,8 @@ class YHFormDetailItem : YHFormItemProtocol {
return "性别".local
case .isPreviousMarriageChild:
return "是否前次婚姻子女".local
case .brotherName:
return "兄弟姐妹姓名".local
case .onlyDoubleChoice:
return "".local
......
......@@ -493,7 +493,7 @@ extension YHFormPickerView: UIPickerViewDelegate, UIPickerViewDataSource {
}
}
// 选中背景色
if #available(iOS 14.0, *), self.subviews.count > 1 {
if #available(iOS 14.0, *), pickerView.subviews.count > 1 {
pickerView.subviews[1].backgroundColor = UIColor(hex: 0x4487F9, alpha: 0.06)
}
return label
......
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