From 9ff3e8c43d01f758381b4925cff44502f1241750 Mon Sep 17 00:00:00 2001 From: 이민희 <mhlee@maprex.co.kr> Date: 수, 22 12월 2021 14:26:36 +0900 Subject: [PATCH] - 일반 사용자로 검색 기능 제대로 동작안되는 문제 해결 - 이슈 유형에서 사용중인 프로젝트는 삭제 불가 - 이슈 유형에서 프로젝트 검색 시 워크스페이스 관리자는 모든 프로젝트 검색 가능(기존엔 참여하고있는 프로젝트만 검색가능하게되어있었음) --- src/main/resources/mybatis/query-template/issueType-template.xml | 11 ++++++++++- 1 files changed, 10 insertions(+), 1 deletions(-) diff --git a/src/main/resources/mybatis/query-template/issueType-template.xml b/src/main/resources/mybatis/query-template/issueType-template.xml index 8beb810..598fed2 100644 --- a/src/main/resources/mybatis/query-template/issueType-template.xml +++ b/src/main/resources/mybatis/query-template/issueType-template.xml @@ -8,7 +8,9 @@ DISTINCT it.id as id, it.name as name, it.description as description, - it.color as color + it.color as color, + it.project_id as projectId, + it.complete_issue_status_id as completeIssueStatusId FROM issue_type it INNER JOIN workspace ws on it.workspace_id = ws.id @@ -16,7 +18,14 @@ <if test="name != '' and name != null"> AND it.name like CONCAT('%',#{name},'%') </if> + <if test="projectId != '' and projectId != null"> + AND it.project_id like CONCAT('%',#{projectId},'%') + </if> + <if test="useProject != '' and useProject != null and useProject == true"> + AND it.project_id IS NOT NULL + </if> AND ws.id = #{workspaceId} + ORDER BY it.id DESC <if test="page != null and !page.equals('')"> limit #{pageSize} offset #{page}; </if> -- Gitblit v1.8.0