Commit c3955047 authored by Steven杜宇's avatar Steven杜宇

// 确认

parent 2e8c9e7a
......@@ -62,14 +62,18 @@ class YHResignAppointGroup: SmartCodable {
let nowDateString = dateFormatter.string(from: Date())
var confirmStatus = YHResignConfirmHKStatus.waitConfirmHK
if self.determine_hk_at.isEmpty {
// 是否到了预约递交时间
let isArriveSubmitTime = compareDates(self.ready_to_submit_at, nowDateString)
if !isArriveSubmitTime {
// 待确认在港
if isArriveSubmitTime {
confirmStatus = .waitConfirmHK
} else {
confirmStatus = !self.determine_hk_at.isEmpty ? .haveConfirmHK : .canConfirmHK
confirmStatus = .canConfirmHK
}
} else { // 有确认在港日期
confirmStatus = .haveConfirmHK
}
return confirmStatus
}
......@@ -94,7 +98,7 @@ class YHResignAppointGroup: SmartCodable {
guard let date1 = dateFormatter.date(from: dateString1),
let date2 = dateFormatter.date(from: dateString2) else {
print("日期格式错误")
return false
return true
}
// 比较日期
......
......@@ -92,7 +92,6 @@ class YHResignConfirmInfoListViewController: YHBaseViewController {
override func viewWillAppear(_ animated: Bool) {
super.viewWillAppear(animated)
showRiskAlertView()
requestList()
}
......@@ -218,6 +217,9 @@ extension YHResignConfirmInfoListViewController {
func requestList() {
YHHUD.show(.progress(message: "加载中..."))
self.viewModel.getList(id: stepId) { success, error in
if success {
self.showRiskAlertView()
}
YHHUD.hide()
self.familyArr.removeAll()
self.familyArr.append(contentsOf: self.viewModel.getList())
......
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