diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/organization/controller/GovBusinessStripController.java b/pmapi/src/main/java/com/ningdatech/pmapi/organization/controller/GovBusinessStripController.java index efaafd3..65c6e3c 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/organization/controller/GovBusinessStripController.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/organization/controller/GovBusinessStripController.java @@ -45,8 +45,8 @@ public class GovBusinessStripController { @GetMapping("/list") @ApiOperation("获取省局条线列表") - public List getProvincialGovBusinessStripList() { - return govBusinessStripManage.getProvincialGovBusinessStripList(); + public List getProvincialGovBusinessStripList(@RequestParam(value = "businessStripName", required = false) String businessStripName) { + return govBusinessStripManage.getProvincialGovBusinessStripList(businessStripName); } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/organization/manage/GovBusinessStripManage.java b/pmapi/src/main/java/com/ningdatech/pmapi/organization/manage/GovBusinessStripManage.java index 370d62c..9235fd7 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/organization/manage/GovBusinessStripManage.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/organization/manage/GovBusinessStripManage.java @@ -6,6 +6,7 @@ import com.ningdatech.pmapi.organization.model.vo.GovBusinessStripTreeVO; import com.ningdatech.pmapi.organization.model.vo.ProvincialGovBusinessStripVO; import com.ningdatech.pmapi.organization.service.IGovBusinessStripService; import lombok.RequiredArgsConstructor; +import org.apache.commons.lang3.StringUtils; import org.springframework.stereotype.Component; import java.util.ArrayList; @@ -42,12 +43,16 @@ public class GovBusinessStripManage { }).collect(Collectors.toList()); } - public List getProvincialGovBusinessStripList() { + public List getProvincialGovBusinessStripList(String businessStripName) { List provincialGovBusinessStripVOList = new ArrayList<>(); ProvincialGovBusinessStripVO provincialGovBusinessStripVO = new ProvincialGovBusinessStripVO(); provincialGovBusinessStripVO.setBusinessStripCode("test_provincial_manage_org_code"); provincialGovBusinessStripVO.setBusinessStripName("测试省局条线主管单位"); provincialGovBusinessStripVOList.add(provincialGovBusinessStripVO); + + provincialGovBusinessStripVOList = provincialGovBusinessStripVOList.stream() + .filter(b -> StringUtils.isBlank(businessStripName) || b.getBusinessStripName().contains(businessStripName)) + .collect(Collectors.toList()); return provincialGovBusinessStripVOList; } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/helper/ProjectHelper.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/helper/ProjectHelper.java index 363af55..c938cb0 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/helper/ProjectHelper.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/helper/ProjectHelper.java @@ -1,5 +1,6 @@ package com.ningdatech.pmapi.projectlib.helper; +import org.apache.commons.lang3.StringUtils; import org.springframework.beans.BeanUtils; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; @@ -47,6 +48,7 @@ public class ProjectHelper { .like(req.getBuildOrg() != null, Project::getBuildOrgName, req.getBuildOrg()) .eq(req.getBuildOrgCode() != null, Project::getBuildOrgCode, req.getBuildOrgCode()) + .like(StringUtils.isNotBlank(req.getBuildOrgName()), Project::getBuildOrgName, req.getBuildOrgName()) .eq(req.getSuperOrgCode() != null, Project::getSuperOrgCode, req.getSuperOrgCode()) .eq(req.getIsTemporaryAugment() != null, Project::getIsTemporaryAugment, req.getIsTemporaryAugment()) //状态 阶段 list diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/entity/Project.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/entity/Project.java index c1a853e..6bf6c60 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/entity/Project.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/entity/Project.java @@ -262,7 +262,7 @@ public class Project implements Serializable { private String approvedFile; @ApiModelProperty("立项批复时间") - private LocalDate approvalDate; + private LocalDateTime approvalDate; @ApiModelProperty("批复金额") private BigDecimal approvedTotalInvestmentIncrease; diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/req/ProjectApprovedReq.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/req/ProjectApprovedReq.java index 64708c3..04c8ad4 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/req/ProjectApprovedReq.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/req/ProjectApprovedReq.java @@ -1,5 +1,6 @@ package com.ningdatech.pmapi.projectlib.model.req; +import com.fasterxml.jackson.annotation.JsonFormat; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import lombok.Data; @@ -10,6 +11,7 @@ import javax.validation.constraints.DecimalMin; import javax.validation.constraints.NotNull; import java.math.BigDecimal; import java.time.LocalDate; +import java.time.LocalDateTime; /** *

@@ -34,8 +36,9 @@ public class ProjectApprovedReq { private BigDecimal approvedAmount; @NotNull(message = "批复时间不能为空") + @JsonFormat(pattern = "yyyy-MM-dd") @ApiModelProperty("批复时间") - private LocalDate approvedDate; + private LocalDateTime approvedDate; @ApiModelProperty("建设周期") @NotNull(message = "建设周期不能为空") diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/req/ProjectListReq.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/req/ProjectListReq.java index 7e37b67..1dae680 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/req/ProjectListReq.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/req/ProjectListReq.java @@ -36,9 +36,13 @@ public class ProjectListReq extends PagePo { @ApiModelProperty("申报单位") private String buildOrg; + @ApiModelProperty("申报单位code") private String buildOrgCode; + @ApiModelProperty("申报单位名") + private String buildOrgName; + @ApiModelProperty("主管单位code") private String superOrgCode; diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/vo/ProjectDetailVO.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/vo/ProjectDetailVO.java index 1e4e122..4377ffc 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/vo/ProjectDetailVO.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/vo/ProjectDetailVO.java @@ -269,7 +269,8 @@ public class ProjectDetailVO { private BigDecimal approvedTotalInvestmentIncrease; @ApiModelProperty("立项批复时间") - private LocalDate approvalDate; + @JSONField(format = "yyyy-MM-dd") + private LocalDateTime approvalDate; @ApiModelProperty("是否有上级条线主管部门 0没有 1有") private Integer isHigherSuperOrg; diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/vo/ProjectLibListItemVO.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/vo/ProjectLibListItemVO.java index 33c3e06..c9698aa 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/vo/ProjectLibListItemVO.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/vo/ProjectLibListItemVO.java @@ -49,7 +49,8 @@ public class ProjectLibListItemVO { private BigDecimal approvedAmount; @ApiModelProperty("立项批复时间") - private LocalDate approvalDate; + @JSONField(format = "yyyy-MM-dd") + private LocalDateTime approvalDate; @ApiModelProperty("项目类型") private Integer projectType; @@ -104,9 +105,10 @@ public class ProjectLibListItemVO { private Integer buildCycle; @ApiModelProperty("计划验收时间") - private LocalDate planAcceptanceTime; + @JSONField(format = "yyyy-MM-dd") + private LocalDateTime planAcceptanceTime; - public LocalDate getPlanAcceptanceTime(){ + public LocalDateTime getPlanAcceptanceTime(){ if (Objects.nonNull(this.approvalDate) && Objects.nonNull(this.buildCycle)) { planAcceptanceTime = this.approvalDate.plusMonths(buildCycle); } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/handle/WithDrawHandle.java b/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/handle/WithDrawHandle.java index 17e6b3d..5dca80d 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/handle/WithDrawHandle.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/handle/WithDrawHandle.java @@ -85,10 +85,12 @@ public class WithDrawHandle { return Boolean.FALSE; } + String taskId = param.getTaskId(); + //1.判断出 当前审批人和上一个审批人 如果传了taskid - ProgressNode progressNode = StringUtils.isBlank(param.getTaskId()) ? + ProgressNode progressNode = StringUtils.isBlank(taskId) ? currentProgressInfo.get(currentProgressInfo.size() - 1) - : findSubNodeByTaskId(param.getTaskId(),currentProgressInfo); + : findSubNodeByTaskId(taskId,currentProgressInfo); if (Objects.isNull(progressNode)){ return Boolean.FALSE; diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/manage/TodoCenterManage.java b/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/manage/TodoCenterManage.java index c65e4b8..fe16e32 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/manage/TodoCenterManage.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/manage/TodoCenterManage.java @@ -369,7 +369,7 @@ public class TodoCenterManage { //通过审核后 所处理的逻辑 handlerManage.afterPassTodo(declaredProject,instance); - return findNextTaskId(instance,employeeCode,nodeId); + return findNextTaskId(instance,employeeCode,nodeId,param.getTaskId()); // 驳回 case REJECT: //前置判断前端传的taskId是否存在不存在的情况 有可能是 或签被别人审批掉了 @@ -425,7 +425,7 @@ public class TodoCenterManage { //上个审批人处理逻辑 processTaskService.lastWithdrawTask(param); - return findNextTaskId(instance,employeeCode,nodeId); + return findNextTaskId(instance,employeeCode,nodeId,param.getTaskId()); } break; default: @@ -1252,7 +1252,7 @@ public class TodoCenterManage { * @param instance * @return */ - private String findNextTaskId(HistoricProcessInstance instance,String employeeCode,String nodeId) { + private String findNextTaskId(HistoricProcessInstance instance,String employeeCode,String nodeId,String taskId) { BpmnModel bpmnModel = repositoryService.getBpmnModel(instance.getProcessDefinitionId()); Map subNodeMap = ProcessTaskUtils.getSubNodeMap(bpmnModel); String subProcessId = subNodeMap.get(nodeId); @@ -1267,7 +1267,7 @@ public class TodoCenterManage { .asc() .list(); if(CollUtil.isEmpty(tasks)){ - return "处理成功"; + return taskId; } return tasks.get(0).getId(); } diff --git a/pmapi/src/main/resources/application-prod.yml b/pmapi/src/main/resources/application-prod.yml index c590ca5..7b70a65 100644 --- a/pmapi/src/main/resources/application-prod.yml +++ b/pmapi/src/main/resources/application-prod.yml @@ -179,7 +179,7 @@ sa-token: #浙政钉公司顶级organizationCode organization: dept-visible-scopes: - - GO_ff70e47bae684fdba0d64f4acab85661 + - GO_c1a6f8d5338e4a468337b08da76e2e31 yxt: #wsdl-url: http://115.239.137.23:9501/ws/v1?wsdl