From f4d4593a3db6eabaeb88a2d9f12653ff7bed6b60 Mon Sep 17 00:00:00 2001 From: PoffyZhang <99775271@qq.com> Date: Fri, 12 Jul 2024 12:35:49 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=B7=A5=E4=BD=9C=E6=B5=81?= =?UTF-8?q?=20=E5=AE=9E=E4=BE=8B=E7=9A=84=E6=97=B6=E9=97=B4=E7=AD=9B?= =?UTF-8?q?=E9=80=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pm/api/todocenter/manage/TodoCenterManage.java | 34 +++++++++++++++++----- 1 file changed, 26 insertions(+), 8 deletions(-) diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/todocenter/manage/TodoCenterManage.java b/hz-pm-api/src/main/java/com/hz/pm/api/todocenter/manage/TodoCenterManage.java index 7566cc2..ecca09a 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/todocenter/manage/TodoCenterManage.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/todocenter/manage/TodoCenterManage.java @@ -70,6 +70,7 @@ import com.ningdatech.basic.exception.BizException; import com.ningdatech.basic.function.VUtils; import com.ningdatech.basic.model.PageVo; import com.ningdatech.basic.util.CollUtils; +import com.ningdatech.basic.util.NdDateUtils; import com.ningdatech.basic.util.StrPool; import com.ningdatech.file.entity.File; import com.ningdatech.file.entity.vo.result.FileResultVO; @@ -249,8 +250,6 @@ public class TodoCenterManage { List xinchuangs = xinchuangService.list(Wrappers.lambdaQuery(Xinchuang.class) .like(StringUtils.isNotBlank(param.getProjectName()),Xinchuang::getProjectName, param.getProjectName()) .like(StringUtils.isNotBlank(param.getBuildOrgName()),Xinchuang::getBuildOrgName, param.getBuildOrgName()) - .ge(Objects.nonNull(param.getCreateOnMin()),Xinchuang::getCreateOn, param.getCreateOnMin()) - .le(Objects.nonNull(param.getCreateOnMax()),Xinchuang::getCreateOn, param.getCreateOnMax()) .isNotNull(Xinchuang::getInstCode)); if (CollUtil.isEmpty(xinchuangs)) { @@ -272,7 +271,14 @@ public class TodoCenterManage { Integer pageNumber = param.getPageNumber(); Integer pageSize = param.getPageSize(); req.setProcessDefId(param.getProcessDefId()); + if(Objects.nonNull(param.getCreateOnMin())){ + req.setStartTime(NdDateUtils.localDateTime2Date(param.getCreateOnMin())); + } + if(Objects.nonNull(param.getCreateOnMax())){ + req.setEndTime(NdDateUtils.localDateTime2Date(param.getCreateOnMax())); + } req.setEmployeeCode(userIdStr); + //有待办节点的(不包含退回) List todoList = processTaskService.getUserTodoList(req); //有退回待办的 @@ -942,8 +948,6 @@ public class TodoCenterManage { List xinchuangs = xinchuangService.list(Wrappers.lambdaQuery(Xinchuang.class) .like(StringUtils.isNotBlank(param.getProjectName()),Xinchuang::getProjectName, param.getProjectName()) .like(StringUtils.isNotBlank(param.getBuildOrgName()),Xinchuang::getBuildOrgName, param.getBuildOrgName()) - .ge(Objects.nonNull(param.getCreateOnMin()),Xinchuang::getCreateOn, param.getCreateOnMin()) - .le(Objects.nonNull(param.getCreateOnMax()),Xinchuang::getCreateOn, param.getCreateOnMax()) .isNotNull(Xinchuang::getInstCode)); if (CollUtil.isEmpty(xinchuangs)) { @@ -967,6 +971,12 @@ public class TodoCenterManage { req.setUserId(userIdStr); req.setEmployeeCode(userIdStr); req.setInstCodes(instCodes); + if(Objects.nonNull(param.getCreateOnMin())){ + req.setStartTime(NdDateUtils.localDateTime2Date(param.getCreateOnMin())); + } + if(Objects.nonNull(param.getCreateOnMax())){ + req.setEndTime(NdDateUtils.localDateTime2Date(param.getCreateOnMax())); + } List iDoList = processTaskService.getUserIdoList(req); if (CollUtil.isEmpty(iDoList)) { return PageVo.empty(); @@ -1148,8 +1158,6 @@ public class TodoCenterManage { List xinchuangs = xinchuangService.list(Wrappers.lambdaQuery(Xinchuang.class) .like(StringUtils.isNotBlank(param.getProjectName()),Xinchuang::getProjectName, param.getProjectName()) .like(StringUtils.isNotBlank(param.getBuildOrgName()),Xinchuang::getBuildOrgName, param.getBuildOrgName()) - .ge(Objects.nonNull(param.getCreateOnMin()),Xinchuang::getCreateOn, param.getCreateOnMin()) - .le(Objects.nonNull(param.getCreateOnMax()),Xinchuang::getCreateOn, param.getCreateOnMax()) .isNotNull(Xinchuang::getInstCode)); if (CollUtil.isEmpty(xinchuangs)) { @@ -1173,6 +1181,12 @@ public class TodoCenterManage { req.setUserId(userIdStr); req.setEmployeeCode(userIdStr); req.setInstCodes(instCodes); + if(Objects.nonNull(param.getCreateOnMin())){ + req.setStartTime(NdDateUtils.localDateTime2Date(param.getCreateOnMin())); + } + if(Objects.nonNull(param.getCreateOnMax())){ + req.setEndTime(NdDateUtils.localDateTime2Date(param.getCreateOnMax())); + } List submittedList = processInstanceService.getUserSubmittedList(req); if (CollUtil.isEmpty(submittedList)) { @@ -1353,8 +1367,6 @@ public class TodoCenterManage { List xinchuangs = xinchuangService.list(Wrappers.lambdaQuery(Xinchuang.class) .like(StringUtils.isNotBlank(param.getProjectName()),Xinchuang::getProjectName, param.getProjectName()) .like(StringUtils.isNotBlank(param.getBuildOrgName()),Xinchuang::getBuildOrgName, param.getBuildOrgName()) - .ge(Objects.nonNull(param.getCreateOnMin()),Xinchuang::getCreateOn, param.getCreateOnMin()) - .le(Objects.nonNull(param.getCreateOnMax()),Xinchuang::getCreateOn, param.getCreateOnMax()) .isNotNull(Xinchuang::getInstCode)); if (CollUtil.isEmpty(xinchuangs)) { @@ -1377,6 +1389,12 @@ public class TodoCenterManage { req.setUserId(userIdStr); req.setEmployeeCode(userIdStr); req.setInstCodes(instCodes); + if(Objects.nonNull(param.getCreateOnMin())){ + req.setStartTime(NdDateUtils.localDateTime2Date(param.getCreateOnMin())); + } + if(Objects.nonNull(param.getCreateOnMax())){ + req.setEndTime(NdDateUtils.localDateTime2Date(param.getCreateOnMax())); + } List ccMeList = processInstanceService.getCcMeList(req); if (CollUtil.isEmpty(ccMeList)) {