Commit 1556b209 authored by Steven杜宇's avatar Steven杜宇

// 高才

parent 98aaa7e9
...@@ -492,63 +492,85 @@ private extension YHGCPreviewViewModel { ...@@ -492,63 +492,85 @@ private extension YHGCPreviewViewModel {
if let arr0 = model0.edu_list { if let arr0 = model0.edu_list {
for(index,model) in arr0.enumerated() { for(index,model) in arr0.enumerated() {
//主申请人学历 //主申请人学历
let tmp5 = YHPreviewQuestionAndAnswerModel(question: "学位:", answer: model.background)
let tmp0 = YHPreviewQuestionAndAnswerModel(question: "学校全称:", answer:model.college) let tmp0 = YHPreviewQuestionAndAnswerModel(question: "学校全称:", answer:model.college)
let tmp1 = YHPreviewQuestionAndAnswerModel(question: "授课形式:", answer:model.type) let tmp1 = YHPreviewQuestionAndAnswerModel(question: "毕业年月:", answer: model.graduate_time)
let tmp2 = YHPreviewQuestionAndAnswerModel(question: "入学年月:", answer:model.admission_time) var major = model.professional
let tmp3 = YHPreviewQuestionAndAnswerModel(question: "毕业年月:", answer: model.graduate_time) if model.professional == "其他" {
let tmp4 = YHPreviewQuestionAndAnswerModel(question: "专业:", answer: model.professional) major = model.major_other
// let tmp6 = YHPreviewQuestionAndAnswerModel(question: "学位类型:", answer: model.degree_type)
var title = "--"
if let item = model.school_address {
if !item.country.isEmpty {
title = item.country
} }
} let tmp2 = YHPreviewQuestionAndAnswerModel(question: "专业:", answer: major)
let tmp7 = YHPreviewQuestionAndAnswerModel(question: "上课城市:", answer:title)
let arr = [tmp5,tmp0,tmp1,tmp2,tmp3,tmp4,tmp7]
let addationIndex = arr0.count > 1 ? String(index + 1) : "" var degree = "--"
let model2 = YHPreviewInfoSessionModel(cellType: .countryInfoType, cellTitle: "主申请人学历" + addationIndex, cellData0: arr) if model.has_bachelor_degree == 1 {
arrDataForAcademicInfo.append(model2) degree = "学士学位"
}
} }
if model.has_bachelor_degree == 2 {
degree = "无学位"
} }
do { let tmp3 = YHPreviewQuestionAndAnswerModel(question: "学位:", answer: degree)
//主申请人专业资格及会员资格 // let tmp1 = YHPreviewQuestionAndAnswerModel(question: "授课形式:", answer:model.type)
if let arr = model0.qla_list { // let tmp2 = YHPreviewQuestionAndAnswerModel(question: "入学年月:", answer:model.admission_time)
for(index,model) in arr.enumerated() { // let tmp6 = YHPreviewQuestionAndAnswerModel(question: "学位类型:", answer: model.degree_type)
let tmp0 = YHPreviewQuestionAndAnswerModel(question: "资格证书名称:",answer:model.qualification)
let tmp1 = YHPreviewQuestionAndAnswerModel(question: "颁授机构全称:", answer:model.college)
let tmp2 = YHPreviewQuestionAndAnswerModel(question: "颁授年份:", answer:String(model.promulgation))
var title = "" var schoolAddressBoard = model.school_address_aboard == 1 ? "国外" : "国内"
if let item = model.college_address { var schoolCountry = model.school_address?.country ?? ""
if item.country.contains("中国") { var address = ""
title = "国内 " if model.school_address_aboard == 1 {
if item.area.count > 1 { if let foreign = model.school_address?.foreign, !foreign.isEmpty {
title = title + item.area[0] + "/" + item.area[1] address = foreign
} }
} else { } else {
title = "国外 " + item.country + "-" + item.foreign if let schoolAddress = model.school_address {
if schoolAddress.area.count > 1 {
address = schoolAddress.area[1]
}
} }
} else {
title = "--"
} }
let tmp3 = YHPreviewQuestionAndAnswerModel(question: "颁授城市:", answer:title) var classAddress = "\(schoolAddressBoard)-\(schoolCountry)/\(address)"
let arr000 = [tmp0,tmp1,tmp2,tmp3]
let tmp4 = YHPreviewQuestionAndAnswerModel(question: "上课地点:", answer:classAddress)
let arr = [tmp0, tmp1, tmp2, tmp3, tmp4]
let addationIndex = arr.count > 1 ? String(index + 1) : "" let addationIndex = arr0.count > 1 ? String(index + 1) : ""
let model2 = YHPreviewInfoSessionModel(cellType: .countryInfoType, cellTitle: "主申请人专业资格及会员资格" + addationIndex, cellData0: arr000) let model2 = YHPreviewInfoSessionModel(cellType: .countryInfoType, cellTitle: "主申请人学历" + addationIndex, cellData0: arr)
arrDataForAcademicInfo.append(model2) arrDataForAcademicInfo.append(model2)
} }
} }
} }
// do {
// //主申请人专业资格及会员资格
// if let arr = model0.qla_list {
// for(index,model) in arr.enumerated() {
// let tmp0 = YHPreviewQuestionAndAnswerModel(question: "资格证书名称:",answer:model.qualification)
// let tmp1 = YHPreviewQuestionAndAnswerModel(question: "颁授机构全称:", answer:model.college)
// let tmp2 = YHPreviewQuestionAndAnswerModel(question: "颁授年份:", answer:String(model.promulgation))
//
// var title = ""
// if let item = model.college_address {
// if item.country.contains("中国") {
// title = "国内 "
// if item.area.count > 1 {
// title = title + item.area[0] + "/" + item.area[1]
// }
// } else {
// title = "国外 " + item.country + "-" + item.foreign
// }
// } else {
// title = "--"
// }
// let tmp3 = YHPreviewQuestionAndAnswerModel(question: "颁授城市:", answer:title)
// let arr000 = [tmp0,tmp1,tmp2,tmp3]
//
//
// let addationIndex = arr.count > 1 ? String(index + 1) : ""
// let model2 = YHPreviewInfoSessionModel(cellType: .countryInfoType, cellTitle: "主申请人专业资格及会员资格" + addationIndex, cellData0: arr000)
// arrDataForAcademicInfo.append(model2)
// }
// }
// }
do { do {
//主申请人 //主申请人
let title = model0.qla_correct == 1 ? "是" : "否" let title = model0.qla_correct == 1 ? "是" : "否"
......
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