From af00e89990ae9757cc9261cbe560873c2066b69c Mon Sep 17 00:00:00 2001
From: jiangping <jp@doumee.com>
Date: 星期五, 18 八月 2023 14:34:11 +0800
Subject: [PATCH] 大屏统计

---
 server/src/main/resources/mappers/PlansExtMapper.xml |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/server/src/main/resources/mappers/PlansExtMapper.xml b/server/src/main/resources/mappers/PlansExtMapper.xml
index ddff456..c0d7430 100644
--- a/server/src/main/resources/mappers/PlansExtMapper.xml
+++ b/server/src/main/resources/mappers/PlansExtMapper.xml
@@ -123,7 +123,7 @@
   <select id="selectByModel" parameterType="doumeemes.dao.ext.dto.QueryPlansExtDTO" resultMap="PlansExtListVO">
   SELECT
   `a`.*
-    ,ifnull((  SELECT sum( b.PLAN_NUM ) FROM  workorder b  WHERE b.deleted = 0 AND b.PLAN_ID = a.id and b.status not in (7,8) ),0) AS workorderDistributNum
+    ,ifnull((  SELECT sum( b.PLAN_NUM ) FROM  workorder b  WHERE b.deleted = 0 AND b.PLAN_ID = a.id and b.status = 4 ),0) AS workorderDistributNum
     from plans a
     <where>
     <if test="id != null">
@@ -370,7 +370,6 @@
       w.START_DATE as workPlanStartDate  , w.PLAN_DATE as workPlanEndDate,
       w.`PLAN_DATE` as workPlanPlanDate,
       ifnull((select  sum(worder.PLAN_NUM) from workorder worder where worder.PLAN_ID = a.id and worder.STATUS not in (7,8)  ),0) as produceNum
-
     FROM `plans` `a`
     LEFT JOIN `department` `dmodel` ON a.DEPART_ID=dmodel.ID
     LEFT JOIN `material_distribute` `mdmodel` ON a.MATERIAL_ID=mdmodel.ID

--
Gitblit v1.9.3