Commit c1c468366869249f0a5861eb19716f93b6d193a6
1 parent
d6e770ad
工单重新发起 报错修订
Showing
1 changed file
with
7 additions
and
1 deletions
urbanops-module-workorder/src/main/java/com/zteits/urbanops/module/workorder/controller/app/garden/aop/BuzStatusUpdateAspect.java
| @@ -26,8 +26,10 @@ import org.springframework.stereotype.Component; | @@ -26,8 +26,10 @@ import org.springframework.stereotype.Component; | ||
| 26 | import java.time.LocalDateTime; | 26 | import java.time.LocalDateTime; |
| 27 | import java.util.List; | 27 | import java.util.List; |
| 28 | 28 | ||
| 29 | +import static com.zteits.urbanops.framework.common.exception.util.ServiceExceptionUtil.exception; | ||
| 29 | import static com.zteits.urbanops.module.workorder.api.constant.BpmCommonConstant.CONSERVE_LEVEL; | 30 | import static com.zteits.urbanops.module.workorder.api.constant.BpmCommonConstant.CONSERVE_LEVEL; |
| 30 | import static com.zteits.urbanops.module.workorder.api.constant.BpmCommonConstant.ORDER_STATUS_INIT; | 31 | import static com.zteits.urbanops.module.workorder.api.constant.BpmCommonConstant.ORDER_STATUS_INIT; |
| 32 | +import static com.zteits.urbanops.module.workorder.enums.ErrorCodeConstants.APP_WORKER_LEVEL_ID_NOT_EXISTS; | ||
| 31 | 33 | ||
| 32 | /** | 34 | /** |
| 33 | * 类描述:切面更新工单表业务状态 | 35 | * 类描述:切面更新工单表业务状态 |
| @@ -94,7 +96,10 @@ public class BuzStatusUpdateAspect { | @@ -94,7 +96,10 @@ public class BuzStatusUpdateAspect { | ||
| 94 | 96 | ||
| 95 | targeVO.setStreetId(roadStreetRespDTO.getStreetId()); | 97 | targeVO.setStreetId(roadStreetRespDTO.getStreetId()); |
| 96 | targeVO.setStreetName(roadStreetRespDTO.getStreetName()); | 98 | targeVO.setStreetName(roadStreetRespDTO.getStreetName()); |
| 97 | - DictDataRespDTO dictData = dictDataCommonApi.getDictData(CONSERVE_LEVEL, reqVO.getPressingType().toString()); | 99 | + DictDataRespDTO dictData = dictDataCommonApi.getDictData(CONSERVE_LEVEL, roadStreetRespDTO.getLevelId().toString()); |
| 100 | + if(null == dictData){ | ||
| 101 | + throw exception(APP_WORKER_LEVEL_ID_NOT_EXISTS); | ||
| 102 | + } | ||
| 98 | targeVO.setCuringLevelId(Integer.valueOf(dictData.getValue())); | 103 | targeVO.setCuringLevelId(Integer.valueOf(dictData.getValue())); |
| 99 | targeVO.setCuringLevelName(dictData.getLabel()); | 104 | targeVO.setCuringLevelName(dictData.getLabel()); |
| 100 | targeVO.setCommitDate(LocalDateTime.now()); | 105 | targeVO.setCommitDate(LocalDateTime.now()); |
| @@ -102,6 +107,7 @@ public class BuzStatusUpdateAspect { | @@ -102,6 +107,7 @@ public class BuzStatusUpdateAspect { | ||
| 102 | targeVO.setBusiLine(SecurityFrameworkUtils.getBusiLine()); | 107 | targeVO.setBusiLine(SecurityFrameworkUtils.getBusiLine()); |
| 103 | targeVO.setUserId(SecurityFrameworkUtils.getLoginUserId()); | 108 | targeVO.setUserId(SecurityFrameworkUtils.getLoginUserId()); |
| 104 | targeVO.setUserName(SecurityFrameworkUtils.getLoginUserNickname()); | 109 | targeVO.setUserName(SecurityFrameworkUtils.getLoginUserNickname()); |
| 110 | + targeVO.setFinishDate(reqVO.getFinishDate()); | ||
| 105 | List<String> problemsImgs = reqVO.getProblemsImgs(); | 111 | List<String> problemsImgs = reqVO.getProblemsImgs(); |
| 106 | if(ObjectUtils.isNotAllEmpty(problemsImgs) && problemsImgs.size()>0){ | 112 | if(ObjectUtils.isNotAllEmpty(problemsImgs) && problemsImgs.size()>0){ |
| 107 | gardenService.attachmentInsertOrUpdate(problemsImgs,BpmCommonConstant.PROBLEM_IMG_GROUP,targeVO); | 113 | gardenService.attachmentInsertOrUpdate(problemsImgs,BpmCommonConstant.PROBLEM_IMG_GROUP,targeVO); |