From e5211965063b5bbd1cfcf2b9ae91e18cc9b0e3ae Mon Sep 17 00:00:00 2001
From: 廖井涛 <2265517004@qq.com>
Date: 星期一, 19 八月 2024 14:14:31 +0800
Subject: [PATCH] 修改工程钢化标签打印

---
 north-glass-erp/src/main/resources/mapper/pp/ReportingWork.xml |   16 ++++++++--------
 1 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/north-glass-erp/src/main/resources/mapper/pp/ReportingWork.xml b/north-glass-erp/src/main/resources/mapper/pp/ReportingWork.xml
index 76714ad..fdc9834 100644
--- a/north-glass-erp/src/main/resources/mapper/pp/ReportingWork.xml
+++ b/north-glass-erp/src/main/resources/mapper/pp/ReportingWork.xml
@@ -106,11 +106,11 @@
 
     <!--    鏌ヨ娴佺▼鍗″伐鑹烘祦绋�-->
     <select id="SelectTechnologicalProcess">
-        select ogd.process
-        from sd.order_glass_detail as ogd
-        where ogd.production_id = LEFT(#{processIdStr}, 11)
-          and ogd.technology_number=#{technologyStr}
-        limit 1
+        select ifnull((select ogd.process
+                       from sd.order_glass_detail as ogd
+                       where ogd.production_id = LEFT(#{processIdStr}, 11)
+                         and ogd.technology_number=#{technologyStr}
+                       limit 1),'') as  process
 
     </select>
 
@@ -206,7 +206,7 @@
         LEFT JOIN sd.order_glass_detail AS ogd
                 ON od.order_id = ogd.order_id
                 AND od.order_number = ogd.order_number
-        <if test="process == '澶硅兌'">
+        <if test="process == '澶硅兌' or (process == '鎵撹兌鍜岀矘妗�' and previousProcess=='澶硅兌')">
             AND ogd.`group` = (select `group`
                                from sd.order_glass_detail
                                where order_id = ogd.order_id
@@ -248,7 +248,7 @@
 
         WHERE
             fc.process_id = #{processIdStr}
-        <if test="process != '涓┖' and process != '澶硅兌' and process != '鍖呰'">
+        <if test="process != '涓┖' and process != '澶硅兌' and process != '鍖呰' and process != '鎵撹兌鍜岀矘妗�' ">
            AND fc.technology_number = #{technologyStr}
         </if>
         AND odpd.process = #{process}
@@ -501,7 +501,7 @@
         select rw.reporting_work_id,
                (rw.reporting_work_time) as reporting_work_time,
                o.order_id,
-               rw.process_id,
+               CONCAT(rw.process_id,'/',GROUP_CONCAT(distinct rwd.technology_number SEPARATOR '')) as process_id,
                o.project,
                o.batch,
                rw.this_process,

--
Gitblit v1.8.0