refactor: 组织或项目禁用后不能再操作里面的资源

This commit is contained in:
CaptainB 2024-01-31 17:29:23 +08:00 committed by 刘瑞斌
parent 8837bd20d3
commit 1b6fb95123
1 changed files with 2 additions and 2 deletions

View File

@ -4,7 +4,7 @@
<select id="checkoutOwner" resultType="boolean">
SELECT count(id) = ${ids.size()}
FROM ${table}
WHERE project_id = #{projectId}
WHERE project_id = #{projectId} and (select 1 from project where id = #{projectId} and enable = TRUE)
and id in
<foreach collection="ids" item="id" separator="," open="(" close=")">
#{id}
@ -14,7 +14,7 @@
<select id="checkoutOrganizationOwner" resultType="boolean">
SELECT count(id) = ${ids.size()}
FROM ${table}
WHERE organization_id = #{organizationId}
WHERE organization_id = #{organizationId} and (select 1 from organization where id = #{organizationId} and enable = TRUE)
and id in
<foreach collection="ids" item="id" separator="," open="(" close=")">
#{id}