From dd930102c5f6832e8ed52aa76645bd46c38d2f32 Mon Sep 17 00:00:00 2001
From: 云 <2163098428@qq.com>
Date: 星期二, 30 六月 2026 13:43:56 +0800
Subject: [PATCH] 修改bug

---
 src/main/resources/mapper/production/ProductionProductOutputMapper.xml |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/main/resources/mapper/production/ProductionProductOutputMapper.xml b/src/main/resources/mapper/production/ProductionProductOutputMapper.xml
index 6dc9682..eedcd04 100644
--- a/src/main/resources/mapper/production/ProductionProductOutputMapper.xml
+++ b/src/main/resources/mapper/production/ProductionProductOutputMapper.xml
@@ -23,7 +23,7 @@
                  left join production_product_main ppm on ppo.production_product_main_id = ppm.id
                  left join production_operation_task pot on ppm.production_operation_task_id = pot.id
                  left join production_order po on pot.production_order_id = po.id
-                 left join product_model pm on po.product_model_id = pm.id
+                 left join product_model pm on ppo.product_model_id = pm.id
         <where>
             <if test="c.productNo != null and c.productNo != ''">
                 and ppm.product_no like concat('%', #{c.productNo}, '%')
@@ -48,14 +48,14 @@
     </select>
 
     <select id="selectDailyOutputStats" resultType="java.util.Map">
-        select date(create_time) as statDate,
+        select date(create_time) as date,
                sum(ifnull(quantity, 0)) as quantity,
                sum(ifnull(scrap_qty, 0)) as scrapQty
         from production_product_output
         where create_time &gt;= #{startDate}
           and create_time &lt;= #{endDate}
         group by date(create_time)
-        order by statDate asc
+        order by date asc
     </select>
 
 </mapper>

--
Gitblit v1.9.3