|
@@ -15,6 +15,7 @@ import cn.com.ty.lift.business.project.dao.entity.model.response.ProjectUserResp
|
|
|
import cn.com.ty.lift.business.project.dao.mapper.ProjectMapper;
|
|
|
import cn.com.ty.lift.business.push.service.PushUserService;
|
|
|
import cn.com.ty.lift.common.base.ExportRequest;
|
|
|
+import cn.com.ty.lift.common.constants.CommonEnum;
|
|
|
import cn.com.ty.lift.common.constants.CommonEnum.ProjectStatus;
|
|
|
import cn.com.ty.lift.common.constants.WebSocketConstants;
|
|
|
import cn.com.ty.lift.common.model.PushMessage;
|
|
@@ -341,15 +342,15 @@ public class ProjectService extends ServiceImpl<ProjectMapper, Project> {
|
|
|
LocalDate tomorrow = now.plus(1, ChronoUnit.DAYS);
|
|
|
//如果项目开始时间在今天之后,项目状态设置成未开始
|
|
|
if (startDate.isAfter(now)) {
|
|
|
- project.setProjectStatus("1");
|
|
|
+ project.setProjectStatus(ProjectStatus.NOT_START.getCode());
|
|
|
}
|
|
|
//如果项目开始时间在明天之前,项目状态设置成服务中
|
|
|
if (startDate.isBefore(tomorrow)) {
|
|
|
- project.setProjectStatus("2");
|
|
|
+ project.setProjectStatus(ProjectStatus.IN_SERVICE.getCode());
|
|
|
}
|
|
|
//如果项目结束时间在今天之前,项目状态设置成逾期
|
|
|
- if (endDate.isAfter(now)) {
|
|
|
- project.setProjectStatus("3");
|
|
|
+ if (endDate.isBefore(now)) {
|
|
|
+ project.setProjectStatus(ProjectStatus.OVERDUE.getCode());
|
|
|
}
|
|
|
}
|
|
|
|