Commit 87b5cc37 authored by Steven杜宇's avatar Steven杜宇

// 删除学历和证书

parent 5d453a28
...@@ -318,11 +318,15 @@ extension YHEducationInfoListVC : UITableViewDelegate, UITableViewDataSource { ...@@ -318,11 +318,15 @@ extension YHEducationInfoListVC : UITableViewDelegate, UITableViewDataSource {
cell.isShowDeleteBtn = (isDegreeEditMode == .canCancel) cell.isShowDeleteBtn = (isDegreeEditMode == .canCancel)
cell.detailLabel.textColor = (isNeedShowError && eduInfo.vacantNum > 0 ? .failColor : .labelTextColor2) cell.detailLabel.textColor = (isNeedShowError && eduInfo.vacantNum > 0 ? .failColor : .labelTextColor2)
cell.deleteBlock = { cell.deleteBlock = {
[weak self] in var title = "确定要删除该学历吗?"
YHTwoOptionAlertView.showAlertView(message:title) {
[weak self] sure in
guard let self = self else { return } guard let self = self else { return }
if !sure { return }
isDegreeEditMode = .none isDegreeEditMode = .none
deleteEducationInfo(id:eduInfo.id) deleteEducationInfo(id:eduInfo.id)
} }
}
return cell return cell
} else { // 数据已填满 } else { // 数据已填满
...@@ -339,11 +343,15 @@ extension YHEducationInfoListVC : UITableViewDelegate, UITableViewDataSource { ...@@ -339,11 +343,15 @@ extension YHEducationInfoListVC : UITableViewDelegate, UITableViewDataSource {
} }
cell.isShowDeleteBtn = (isDegreeEditMode == .canCancel) cell.isShowDeleteBtn = (isDegreeEditMode == .canCancel)
cell.deleteBlock = { cell.deleteBlock = {
[weak self] in var title = "确定要删除该学历吗?"
YHTwoOptionAlertView.showAlertView(message:title) {
[weak self] sure in
guard let self = self else { return } guard let self = self else { return }
if !sure { return }
isDegreeEditMode = .none isDegreeEditMode = .none
deleteEducationInfo(id:eduInfo.id) deleteEducationInfo(id:eduInfo.id)
} }
}
return cell return cell
} }
} }
...@@ -366,11 +374,15 @@ extension YHEducationInfoListVC : UITableViewDelegate, UITableViewDataSource { ...@@ -366,11 +374,15 @@ extension YHEducationInfoListVC : UITableViewDelegate, UITableViewDataSource {
cell.detailLabel.textColor = (isNeedShowError && quaInfo.vacantNum > 0 ? .failColor : .labelTextColor2) cell.detailLabel.textColor = (isNeedShowError && quaInfo.vacantNum > 0 ? .failColor : .labelTextColor2)
cell.isShowDeleteBtn = (isQualificationEditMode == .canCancel) cell.isShowDeleteBtn = (isQualificationEditMode == .canCancel)
cell.deleteBlock = { cell.deleteBlock = {
[weak self] in var title = "确定要删除该证书吗?"
YHTwoOptionAlertView.showAlertView(message:title) {
[weak self] sure in
guard let self = self else { return } guard let self = self else { return }
if !sure { return }
isQualificationEditMode = .none isQualificationEditMode = .none
deleteQualificationInfo(id:quaInfo.id) deleteQualificationInfo(id:quaInfo.id)
} }
}
return cell return cell
} }
} }
......
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