fix(database): 修正八工作业状态统计查询逻辑

dev_visual_page
zhaokai 2026-07-28 11:46:16 +08:00
parent 2cff61eb31
commit dceda5ffcb
1 changed files with 2 additions and 2 deletions

View File

@ -149,8 +149,8 @@
<select id="screenStatusStatistics" resultType="com.zcloud.eightwork.persistence.dataobject.dto.ScreenStatusStatisticsDTO">
select
coalesce(sum(case when t.status != 0 then 1 else 0 end), 0) as appliedCount,
coalesce(sum(case when t.status = 1 then 1 else 0 end), 0) as approvingCount,
coalesce(sum(case when t.status = 999 then 1 else 0 end), 0) as archivedCount
coalesce(sum(case when t.status in (1,2) then 1 else 0 end), 0) as approvingCount,
coalesce(sum(case when t.status in (998,999) then 1 else 0 end), 0) as archivedCount
from eightwork_info t left join vi_corp_info c on t.corpinfo_id = c.id
where t.delete_enum = 'FALSE' and c.delete_enum='FALSE'
<if test="params.corpinfoId != null">