Commit 4d598174 authored by cq990612's avatar cq990612

优化代码结构


parent c3d32cb9
...@@ -264,13 +264,13 @@ public class WorkTimeOrderServiceImpl implements WorkTimeOrderService { ...@@ -264,13 +264,13 @@ public class WorkTimeOrderServiceImpl implements WorkTimeOrderService {
dto.setStatus(RE_SUBMIT); dto.setStatus(RE_SUBMIT);
Date rejectTime = DateUtil.convertStrToDate(DateUtil.convertDateToStr(rejectTime1, "yyyy-MM-dd"), "yyyy-MM-dd"); Date rejectTime = DateUtil.convertStrToDate(DateUtil.convertDateToStr(rejectTime1, "yyyy-MM-dd"), "yyyy-MM-dd");
if (date.getTime() - rejectTime.getTime() > submitTime * 24 * 60 * 60 * 1000) { if (date.getTime() - rejectTime.getTime() > submitTime * 24 * 60 * 60 * 1000) {
throw new BaseCustomException(BASE_RESP_CODE_ENUM.WORK_DAY_THAN_DATE); throw new BaseCustomException("627","超过"+submitTime+"天的工单不能补报");
} }
} }
// 4、默认设置超过系统默认3天(包括驳回3天)未填报的工时将不能填报 // 4、默认设置超过系统默认3天(包括驳回3天)未填报的工时将不能填报
if (!REJECTED.equals(dto.getStatus()) && !RE_SUBMIT.equals(dto.getStatus())) { if (!REJECTED.equals(dto.getStatus()) && !RE_SUBMIT.equals(dto.getStatus())) {
if (date.getTime() - dto.getWorkDay().getTime() > submitTime * 24 * 60 * 60 * 1000) { if (date.getTime() - dto.getWorkDay().getTime() > submitTime * 24 * 60 * 60 * 1000) {
throw new BaseCustomException(BASE_RESP_CODE_ENUM.WORK_DAY_THAN_DATE); throw new BaseCustomException("627","超过"+submitTime+"天的工单不能补报");
} }
} }
......
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