Browse Source

modify:

1. 项目库移除变更通过的项目;
tags/24102401
WendyYang 1 month ago
parent
commit
58a13f5b2a
3 changed files with 10 additions and 0 deletions
  1. +1
    -0
      hz-pm-api/src/main/java/com/hz/pm/api/projectlib/manage/ProjectLibManage.java
  2. +6
    -0
      hz-pm-api/src/main/java/com/hz/pm/api/projectlib/mapper/ProjectMapper.xml
  3. +3
    -0
      hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/req/ProjectListReq.java

+ 1
- 0
hz-pm-api/src/main/java/com/hz/pm/api/projectlib/manage/ProjectLibManage.java View File

@@ -448,6 +448,7 @@ public class ProjectLibManage {
List<Long> viewUnitIds = mhUnitCache.getViewChildIdsRecursion(req.getDeclaredUnitId());
req.setDeclaredUnitIds(viewUnitIds);
}
req.setNotInStatusList(Collections.singletonList(ProjectStatus.CHANGE_APPLY_PASSED.getCode()));
Page<ProjectPO> page = projectService.pageLibWithPermission(req.page(), req);

if (CollUtil.isEmpty(page.getRecords())) {


+ 6
- 0
hz-pm-api/src/main/java/com/hz/pm/api/projectlib/mapper/ProjectMapper.xml View File

@@ -335,6 +335,12 @@
topped
FROM nd_project p
WHERE p.newest = 1
<if test="req.notInStatusList != null and req.notInStatusList.size > 0">
and p.status not in
<foreach close=")" collection="req.notInStatusList" item="notInStatus" open="(" separator=",">
#{notInStatus}
</foreach>
</if>
<if test="req.id != null">
and p.id = #{req.id}
</if>


+ 3
- 0
hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/req/ProjectListReq.java View File

@@ -135,6 +135,9 @@ public class ProjectListReq extends PagePo {
@ApiModelProperty("tab状态")
private Integer tabStatus;

@ApiModelProperty("不包含的状态")
private List<Integer> notInStatusList;

public Long clearBuildOrgCode() {
String tmpBuildOrgCode = this.getBuildOrgCode();
if (StrUtil.isNotBlank(tmpBuildOrgCode)) {


Loading…
Cancel
Save