Commit 7f9db158 authored by Steven杜宇's avatar Steven杜宇

// 赴港预约

parent 629f2a29
...@@ -826,6 +826,7 @@ extension YHCertificateAppointViewController { ...@@ -826,6 +826,7 @@ extension YHCertificateAppointViewController {
let batch: [String: Any] = ["start_time": start_time, let batch: [String: Any] = ["start_time": start_time,
"end_time": end_time, "end_time": end_time,
"migration_office": model.hkPlace.name, "migration_office": model.hkPlace.name,
"is_will_visit_hk_galaxy_bay": model.isWillVisitHkGalaxyBay,
"users": users] "users": users]
batchs.append(batch) batchs.append(batch)
} }
......
...@@ -252,6 +252,7 @@ extension YHReAppointViewController { ...@@ -252,6 +252,7 @@ extension YHReAppointViewController {
let batch: [String: Any] = ["start_time": start_time, let batch: [String: Any] = ["start_time": start_time,
"end_time": end_time, "end_time": end_time,
"migration_office": model.hkPlace.name, "migration_office": model.hkPlace.name,
"is_will_visit_hk_galaxy_bay": model.isWillVisitHkGalaxyBay,
"users": users] "users": users]
batchs.append(batch) batchs.append(batch)
} }
......
...@@ -41,7 +41,8 @@ class YHAppointMemberGroupModel: SmartCodable { ...@@ -41,7 +41,8 @@ class YHAppointMemberGroupModel: SmartCodable {
// 此处是私链URL数组 // 此处是私链URL数组
var receipts: [String] = [] var receipts: [String] = []
var submitTime: String = "" var submitTime: String = ""
var isWillVisitHkGalaxyBay: Int = 0 // 0没有选择1是2否
// 自定义 // 自定义
// 私链反馈回执对应的公链 // 私链反馈回执对应的公链
var publicReceipts: [String] = [] var publicReceipts: [String] = []
...@@ -65,6 +66,7 @@ class YHAppointMemberGroupModel: SmartCodable { ...@@ -65,6 +66,7 @@ class YHAppointMemberGroupModel: SmartCodable {
case goTime = "go_time" case goTime = "go_time"
case receipts = "receipts" case receipts = "receipts"
case submitTime = "submit_time" case submitTime = "submit_time"
case isWillVisitHkGalaxyBay = "is_will_visit_hk_galaxy_bay"
} }
required init() { required init() {
......
...@@ -71,4 +71,8 @@ class YHSelectGroupMemberModel { ...@@ -71,4 +71,8 @@ class YHSelectGroupMemberModel {
// 是否显示重新预约人员名单 // 是否显示重新预约人员名单
var isShowReAppointView: Bool = false var isShowReAppointView: Bool = false
//
var isWillVisitHkGalaxyBay: Int = 0 // 0没有选择1是2否
} }
...@@ -41,9 +41,10 @@ class YHGrabingNumberListCell: UITableViewCell { ...@@ -41,9 +41,10 @@ class YHGrabingNumberListCell: UITableViewCell {
if group.wantMinTime == group.wantMaxTime { if group.wantMinTime == group.wantMaxTime {
wantTimeText = group.wantMinTime wantTimeText = group.wantMinTime
} }
let visitOption = group.isWillVisitHkGalaxyBay == 1 ? "是" : "否"
let items2 = [YHGrabItem(type: .info, title: "期望赴港时间:", detail: wantTimeText, isSingleLine: true), let items2 = [YHGrabItem(type: .info, title: "期望赴港时间:", detail: wantTimeText, isSingleLine: true),
YHGrabItem(type: .info, title: "期望香港办证点:", detail: group.wantImmigrationOffice, isSingleLine: false), YHGrabItem(type: .info, title: "期望香港办证点:", detail: group.wantImmigrationOffice, isSingleLine: false),
YHGrabItem(type: .visit, title: "到访香港体验中心:香港华润大厦 (湾仔入境处旁)", detail: "是", isSingleLine: false)] YHGrabItem(type: .visit, title: "到访香港体验中心:香港华润大厦 (湾仔入境处旁)", detail: visitOption, isSingleLine: false)]
listView.intentionInfoView.updateItems(items2) listView.intentionInfoView.updateItems(items2)
......
...@@ -34,9 +34,10 @@ class YHHaveGrabbedNumberListCell: UITableViewCell { ...@@ -34,9 +34,10 @@ class YHHaveGrabbedNumberListCell: UITableViewCell {
if group.wantMinTime == group.wantMaxTime { if group.wantMinTime == group.wantMaxTime {
wantTimeText = group.wantMinTime wantTimeText = group.wantMinTime
} }
let visitOption = group.isWillVisitHkGalaxyBay == 1 ? "是" : "否"
let items2 = [YHGrabItem(type: .info, title: "期望赴港时间:", detail: wantTimeText, isSingleLine: true), let items2 = [YHGrabItem(type: .info, title: "期望赴港时间:", detail: wantTimeText, isSingleLine: true),
YHGrabItem(type: .info, title: "期望香港办证点:", detail: group.wantImmigrationOffice, isSingleLine: false), YHGrabItem(type: .info, title: "期望香港办证点:", detail: group.wantImmigrationOffice, isSingleLine: false),
YHGrabItem(type: .visit, title: "到访香港体验中心:香港华润大厦 (湾仔入境处旁)", detail: "是", isSingleLine: false)] YHGrabItem(type: .visit, title: "到访香港体验中心:香港华润大厦 (湾仔入境处旁)", detail: visitOption, isSingleLine: false)]
listView.intentionInfoView.updateItems(items2) listView.intentionInfoView.updateItems(items2)
listContainView.addSubview(listView) listContainView.addSubview(listView)
......
...@@ -311,11 +311,25 @@ class YHSelectApplicantGroupCell: UITableViewCell { ...@@ -311,11 +311,25 @@ class YHSelectApplicantGroupCell: UITableViewCell {
view.title = "到访香港体验中心:香港华润大厦 (湾仔入境处旁)" view.title = "到访香港体验中心:香港华润大厦 (湾仔入境处旁)"
view.options = ["是", "否"] view.options = ["是", "否"]
view.selectIndex = 0 view.selectIndex = 0
view.selectBlock = { view.selectBlock = { [weak self] index in
[weak self] _ in
guard let self = self else { return } guard let self = self else { return }
// let isAllGo = index == 0 ? true : false guard let model = dataModel?.model else { return }
// self.selectBlock?(isAllGo)
if index == 1 { // 点击否
refreshBlock?()
let view = YHVisitHKAlertView.alertView()
view.confirmBlock = { [weak self] isSure in
guard let self = self else { return }
model.isWillVisitHkGalaxyBay = (isSure ? 1 : 2)
refreshBlock?()
}
view.show()
} else { // 点击是
model.isWillVisitHkGalaxyBay = (index == 0 ? 1 : 2)
refreshBlock?()
}
} }
return view return view
}() }()
...@@ -512,7 +526,14 @@ private extension YHSelectApplicantGroupCell { ...@@ -512,7 +526,14 @@ private extension YHSelectApplicantGroupCell {
// 办证地点是否显示红色错误提示 // 办证地点是否显示红色错误提示
timeSelectView.isNeedShowErrorTips = (model.isNeedCheck && !isSelectDate) timeSelectView.isNeedShowErrorTips = (model.isNeedCheck && !isSelectDate)
visitOptionView.tips = "请选择" var selectIndex = -1
if model.isWillVisitHkGalaxyBay == 1 { // 是
selectIndex = 0
} else if model.isWillVisitHkGalaxyBay == 2 { // 否
selectIndex = 1
}
visitOptionView.selectIndex = selectIndex
visitOptionView.tips = (model.isNeedCheck && selectIndex == -1) ? "请选择" : ""
self.setNeedsLayout() self.setNeedsLayout()
self.layoutIfNeeded() self.layoutIfNeeded()
} }
......
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