fix(系统设置): 组织列表查询项目数量有误

This commit is contained in:
song-cc-rock 2023-08-23 19:05:26 +08:00 committed by 刘瑞斌
parent 7cb734b733
commit c513b730df
1 changed files with 1 additions and 1 deletions

View File

@ -4,7 +4,7 @@
<select id="list" resultType="io.metersphere.system.dto.OrganizationDTO"> <select id="list" resultType="io.metersphere.system.dto.OrganizationDTO">
select o.id, o.num, o.name, o.description, o.create_time, select o.id, o.num, o.name, o.description, o.create_time,
o.update_time, o.create_user, o.deleted, o.delete_user, o.delete_time, o.enable, o.update_time, o.create_user, o.deleted, o.delete_user, o.delete_time, o.enable,
count(distinct ur.user_id) as memberCount, count(p.id) as projectCount count(distinct ur.user_id) as memberCount, count(distinct p.id) as projectCount
from organization o left join user_role_relation ur on ur.source_id = o.id from organization o left join user_role_relation ur on ur.source_id = o.id
left join project p on p.organization_id = o.id left join project p on p.organization_id = o.id
<include refid="queryWhereCondition"/> <include refid="queryWhereCondition"/>