From a7d5b34a0fa720e5fd3dce1975e9dee94774a78e Mon Sep 17 00:00:00 2001
From: guoyujie <guoyujie@ng.com>
Date: 星期一, 01 九月 2025 09:31:40 +0800
Subject: [PATCH] Merge branch 'master' of http://10.153.19.25:10101/r/ERP_override
---
north-glass-erp/src/main/resources/mapper/mm/FinishedOperateLog.xml | 35 +++++++++++++++++++++++++----------
1 files changed, 25 insertions(+), 10 deletions(-)
diff --git a/north-glass-erp/src/main/resources/mapper/mm/FinishedOperateLog.xml b/north-glass-erp/src/main/resources/mapper/mm/FinishedOperateLog.xml
index edd636b..6bc501b 100644
--- a/north-glass-erp/src/main/resources/mapper/mm/FinishedOperateLog.xml
+++ b/north-glass-erp/src/main/resources/mapper/mm/FinishedOperateLog.xml
@@ -35,6 +35,7 @@
<result column="delivery_address" property="order.deliveryAddress"/>
<result column="project" property="order.project"/>
<result column="customer_name" property="order.customerName"/>
+ <result column="customer_Id" property="order.customerId"/>
</resultMap>
@@ -621,7 +622,15 @@
)
values (
#{oddNumber} ,#{flowCard.order.orderId},#{flowCard.processId},#{flowCard.orderNumber},"鍏ュ簱",#{userName},
- #{flowCard.inventoryQuantity},now(),"鏈鏍�",#{container},#{deliveryDetailMoney},#{deliveryDetailArea}
+ #{flowCard.inventoryQuantity},
+ <if test="createTime != null">
+ #{createTime}
+ </if>
+ <if test="createTime == null">
+ now()
+ </if>
+ ,"鏈鏍�",#{container},#{deliveryDetailMoney},#{deliveryDetailArea}
+
)
</insert>
@@ -633,11 +642,12 @@
operator,
quantity,
operate_time,
- status
+ status,
+ remarks
)
values (
#{orderDetail.deliveryDetail.deliveryId} ,#{orderDetail.deliveryDetail.orderId},#{orderDetail.deliveryDetail.orderNumber}
- ,"鍑哄簱",#{userName},#{orderDetail.deliveryDetail.quantity},now(),"鏈鏍�"
+ ,"鍑哄簱",#{userName},#{orderDetail.deliveryDetail.quantity},now(),"鏈鏍�",#{boxNo}
)
</insert>
@@ -759,6 +769,7 @@
od.height,
o.project,
o.customer_name,
+ o.customer_Id,
o.delivery_address,
fol.operate_time,
fol.`status`,
@@ -853,7 +864,9 @@
and fol.remarks regexp #{finishedOperateLog.remarks}
</if>
</where>
- group by fol.remarks,od.order_id,fol.process_id) as zu
+ group by fol.remarks,od.order_id
+ -- ,fol.process_id
+ ) as zu
</select>
@@ -882,6 +895,7 @@
select kkk.*,rw.teams_groups_name as teams_groups_name2 from(select o.order_id,
o.customer_name,
+ o.customer_id,
o.project,
o.batch,
fol.remarks,
@@ -902,13 +916,13 @@
where
- o.customer_name=#{customerName} and fol.remarks=#{remarks} and o.project=#{project}
+ o.customer_id=#{customerId} and fol.remarks=#{remarks} and o.project=#{project}
and (fol.remarks is not null and fol.remarks !="") and (fol.process_id !="" and fol.process_id is not null)
group by fol.remarks,o.customer_name,o.project
) as kkk
left join pp.reporting_work rw on rw.process_id=kkk.process_id and rw.this_process=kkk.previous_process
- group by kkk.remarks,kkk.customer_name,kkk.project
+ group by kkk.remarks,kkk.customer_id,kkk.project
</select>
@@ -936,11 +950,11 @@
ifnull(od.building_number,ifnull(JSON_UNQUOTE(JSON_EXTRACT(od.other_columns, '$.S01')),'')) as building_number,
od.width,
od.height,
- fol.quantity,
+ sum(fol.quantity) as quantity,
od.product_name,
od.product_id,
- ROUND( od.width * od.height * fol.quantity / 1000000, 2 ) as area,
- ROUND( od.width * od.height * fol.quantity / 1000000, 2 )*#{thickness}*2.5 as weight
+ ROUND(sum(od.width * od.height * fol.quantity / 1000000) , 2 ) as area,
+ ROUND(sum(od.width * od.height * fol.quantity / 1000000) , 2 )*#{thickness}*2.5 as weight
FROM
( SELECT * FROM mm.finished_operate_log aa WHERE aa.operate_type = '鍏ュ簱' AND aa.STATUS != '宸蹭綔搴�' ) fol
LEFT JOIN sd.order_detail od ON fol.order_id = od.order_id
@@ -948,8 +962,9 @@
LEFT JOIN sd.`order` o ON o.order_id = fol.order_id
WHERE
o.order_id=#{orderId} and fol.remarks=#{remarks} and od.product_id=#{productId}
+ group by od.order_id,od.order_number
ORDER BY
- fol.operate_time DESC
+ od.order_number
</select>
--
Gitblit v1.8.0