Commit a4f6e254 authored by hongguangwu's avatar hongguangwu

MVP1.7.0 优化

parent 2312743e
......@@ -88,9 +88,9 @@ public class PreUploadEmpImportTwoVo implements Serializable {
private String isCollege;
@ExcelAttribute(name = "最高学历", isDataId = true, dataType = ExcelAttributeConstants.EDUCATION, maxLength = 32)
private String educationName;
@ExcelAttribute(name = "学校", maxLength = 64)
@ExcelAttribute(name = "学校", maxLength = 50)
private String school;
@ExcelAttribute(name = "专业", maxLength = 64)
@ExcelAttribute(name = "专业", maxLength = 50)
private String major;
@ExcelAttribute(name = "入学时间", isDate = true)
private String entryDate;
......
......@@ -103,9 +103,9 @@ public class PreUploadEmpImportVo implements Serializable {
// 学历 学校 专业 教育开始时间 教育结束时间 是否大专及以上 最高学历
@ExcelAttribute(name = "学历", isDataId = true, dataType = ExcelAttributeConstants.EDUCATION, isNotEmpty = true, maxLength = 32)
private String educationName;
@ExcelAttribute(name = "学校", maxLength = 64)
@ExcelAttribute(name = "学校", maxLength = 50)
private String school;
@ExcelAttribute(name = "专业", maxLength = 64)
@ExcelAttribute(name = "专业", maxLength = 50)
private String major;
@ExcelAttribute(name = "教育开始时间", isDate = true)
private String entryDate;
......
......@@ -3610,26 +3610,33 @@ public class TPreEmpMainServiceImpl extends ServiceImpl<TPreEmpMainMapper, TPreE
}
private void judgeDisability(PreUploadEmpImportVo detail, StringBuilder errorMust) {
if (Common.isNotNull(detail.getOccupationalDiseaseFlag())
&& detail.getOccupationalDiseaseFlag().contains("是")
&& Common.isEmpty(detail.getOccupationalDisease())) {
errorMust.append("是否有职业病为是则必填:职业病名称;");
}
if (Common.isNotNull(detail.getInfectiousDiseaseFlag())
&& detail.getInfectiousDiseaseFlag().contains("是")
&& Common.isEmpty(detail.getInfectiousName())) {
errorMust.append("是否有传染性疾病为是则必填:传染病名称;");
}
if (Common.isNotNull(detail.getDisabilityFlag())
&& detail.getDisabilityFlag().contains("是")
&& (Common.isEmpty(detail.getDisabilityName())
|| Common.isEmpty(detail.getDisabilityLevel()))) {
errorMust.append("是否被劳动能力鉴定委员会鉴定为具有伤残等级为是则必填:");
if (Common.isEmpty(detail.getDisabilityName())) {
errorMust.append("伤残病名称;");
}
if (Common.isEmpty(detail.getDisabilityLevel())) {
errorMust.append("伤残等级;");
if (Common.isNotNull(detail.getOccupationalDiseaseFlag())) {
if (detail.getOccupationalDiseaseFlag().contains("是") && Common.isEmpty(detail.getOccupationalDisease())) {
errorMust.append("是否有职业病为是则必填:职业病名称;");
} else if (detail.getOccupationalDiseaseFlag().contains("否")) {
detail.setOccupationalDisease(null);
}
}
if (Common.isNotNull(detail.getInfectiousDiseaseFlag())) {
if (detail.getInfectiousDiseaseFlag().contains("是") && Common.isEmpty(detail.getInfectiousName())) {
errorMust.append("是否有传染性疾病为是则必填:传染病名称;");
} else if (detail.getInfectiousDiseaseFlag().contains("否")) {
detail.setInfectiousName(null);
}
}
if (Common.isNotNull(detail.getDisabilityFlag())) {
if (detail.getDisabilityFlag().contains("是") && (Common.isEmpty(detail.getDisabilityName()) || Common.isEmpty(detail.getDisabilityLevel()))) {
errorMust.append("是否被劳动能力鉴定委员会鉴定为具有伤残等级为是则必填:");
if (Common.isEmpty(detail.getDisabilityName())) {
errorMust.append("伤残病名称;");
}
if (Common.isEmpty(detail.getDisabilityLevel())) {
errorMust.append("伤残等级;");
}
} else if (detail.getDisabilityFlag().contains("否")) {
detail.setDisabilityName(null);
detail.setDisabilityLevel(null);
detail.setDisabilityLevelValue(null);
}
}
}
......
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