|
@@ -8,6 +8,7 @@ import com.ningdatech.pmapi.projectdeclared.model.dto.OperationDTO; |
|
|
import com.ningdatech.pmapi.projectdeclared.model.entity.Operation; |
|
|
import com.ningdatech.pmapi.projectdeclared.model.entity.Operation; |
|
|
import com.ningdatech.pmapi.projectdeclared.model.vo.OperationVO; |
|
|
import com.ningdatech.pmapi.projectdeclared.model.vo.OperationVO; |
|
|
import com.ningdatech.pmapi.projectdeclared.service.IOperationService; |
|
|
import com.ningdatech.pmapi.projectdeclared.service.IOperationService; |
|
|
|
|
|
import com.ningdatech.pmapi.projectlib.enumeration.ProjectStatusEnum; |
|
|
import com.ningdatech.pmapi.projectlib.model.entity.Project; |
|
|
import com.ningdatech.pmapi.projectlib.model.entity.Project; |
|
|
import com.ningdatech.pmapi.projectlib.service.IProjectService; |
|
|
import com.ningdatech.pmapi.projectlib.service.IProjectService; |
|
|
import com.ningdatech.pmapi.user.security.auth.model.UserInfoDetails; |
|
|
import com.ningdatech.pmapi.user.security.auth.model.UserInfoDetails; |
|
@@ -58,6 +59,11 @@ public class OperationManage { |
|
|
VUtils.isTrue(Objects.isNull(project)) |
|
|
VUtils.isTrue(Objects.isNull(project)) |
|
|
.throwMessage("项目不存在!"); |
|
|
.throwMessage("项目不存在!"); |
|
|
|
|
|
|
|
|
|
|
|
//首先要判断 项目当前状态 是不是 待开工状态 |
|
|
|
|
|
VUtils.isTrue(!ProjectStatusEnum.OPERATION.getCode().equals(project.getStatus()) || |
|
|
|
|
|
!ProjectStatusEnum.PROJECT_APPROVED.getCode().equals(project.getStage())) |
|
|
|
|
|
.throwMessage("提交失败 该项目不是 待开工或者已立项阶段"); |
|
|
|
|
|
|
|
|
Operation old = operationService.getOne(Wrappers.lambdaQuery(Operation.class) |
|
|
Operation old = operationService.getOne(Wrappers.lambdaQuery(Operation.class) |
|
|
.eq(Operation::getProjectId, project.getProjectCode()) |
|
|
.eq(Operation::getProjectId, project.getProjectCode()) |
|
|
.last(BizConst.LIMIT_1)); |
|
|
.last(BizConst.LIMIT_1)); |
|
|