Commit 0a5f6de2 authored by huyuchen's avatar huyuchen

huyc 项目档案代码提交

parent 10bb04ed
...@@ -121,21 +121,17 @@ public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper, ...@@ -121,21 +121,17 @@ public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper,
TEmpChangeInfoVO excel = excelVOList.get(i); TEmpChangeInfoVO excel = excelVOList.get(i);
if (Common.isNotNull(excel.getChangeStartMonth()) && excel.getChangeStartMonth().length() > CommonConstants.dingleDigitIntArray[6]) { if (Common.isNotNull(excel.getChangeStartMonth()) && excel.getChangeStartMonth().length() > CommonConstants.dingleDigitIntArray[6]) {
errorMsg.add("第" + (i + 2) + "行划转起始月长度不能超过6位"); errorMsg.add("划转起始月长度不能超过6位");
errorMsgMap.put((i + 2L), new ErrorMessage("第" + (i + 2) + "行划转起始月长度不能超过6位"));
} }
if (!Common.isEmpty(excel.getChangeStartMonth()) && !PATTERN.matcher(excel.getChangeStartMonth()).matches()) { if (!Common.isEmpty(excel.getChangeStartMonth()) && !PATTERN.matcher(excel.getChangeStartMonth()).matches()) {
errorMsg.add("第" + (i + 2) + "行划转起始月格式错误"); errorMsg.add("划转起始月格式错误");
errorMsgMap.put((i + 2L), new ErrorMessage("第" + (i + 2) + "行划转起始月格式错误"));
} }
if (excel.getUnsettleDeal().equals(CommonConstants.IS_CHANGE)) { if (excel.getUnsettleDeal().equals(CommonConstants.IS_CHANGE)) {
if (Common.isEmpty(excel.getChangeStartMonth())) { if (Common.isEmpty(excel.getChangeStartMonth())) {
errorMsg.add("第" + (i + 2) + "行划转起始月不能为空"); errorMsg.add("划转起始月不能为空");
errorMsgMap.put((i + 2L), new ErrorMessage("第" + (i + 2) + "行划转起始月不能为空"));
} else if (PATTERN.matcher(excel.getChangeStartMonth()).matches()) { } else if (PATTERN.matcher(excel.getChangeStartMonth()).matches()) {
if (Integer.parseInt(excel.getChangeStartMonth()) > Integer.parseInt(DateUtil.getThisMonth())) { if (Integer.parseInt(excel.getChangeStartMonth()) > Integer.parseInt(DateUtil.getThisMonth())) {
errorMsg.add("第" + (i + 2) + "行划转起始月要小于等于当前月"); errorMsg.add("划转起始月要小于等于当前月");
errorMsgMap.put((i + 2L), new ErrorMessage("第" + (i + 2) + "行划转起始月要小于等于当前月"));
} }
} }
} }
......
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