Commit f9d07f18 authored by 鲁鸿波's avatar 鲁鸿波

首页危险作业统计数据从系统中统计

parent b35436bc
......@@ -132,7 +132,7 @@
o.org_id id,
o.org_name name,
COALESCE(SUM(CASE WHEN h.work_status = '5' THEN 1 ELSE 0 END), 0) as done,
COALESCE(SUM(CASE WHEN h.work_status NOT IN ('0','6','12','5') THEN 1 ELSE 0 END), 0) as undone
COALESCE(SUM(CASE WHEN h.work_status NOT IN ('0','6','5') THEN 1 ELSE 0 END), 0) as undone
FROM t_sys_org o
LEFT JOIN t_hazard_work_plan h ON o.org_id = h.org_id
AND h.status = '0'
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment