From 2075957d9c0c87e66b0392fdc0a2d5b9290dfee5 Mon Sep 17 00:00:00 2001
From: 南骏 池 <chiffly@163.com>
Date: 星期五, 14 二月 2025 08:22:54 +0800
Subject: [PATCH] 1.成品入库后台完成 2.报工后台优化

---
 service/Wom/MesWorkProdManager.cs |   15 ++++++++-------
 1 files changed, 8 insertions(+), 7 deletions(-)

diff --git a/service/Wom/MesWorkProdManager.cs b/service/Wom/MesWorkProdManager.cs
index 3d88cb7..75aa089 100644
--- a/service/Wom/MesWorkProdManager.cs
+++ b/service/Wom/MesWorkProdManager.cs
@@ -137,7 +137,7 @@
                         Quantity = reportQty
                     })
                     .Where(x => x.Guid == barcode.Guid)
-                    .ExecuteCommandAsync();
+                    .ExecuteCommand();
 
                 // 11. 鑾峰彇鎴栧垱寤烘姤宸ュ崟
                 var workProd = db.Queryable<MesWorkProd>()
@@ -199,11 +199,12 @@
 
                 // 13. 鏇存柊宸ュ崟宸叉姤宸ユ暟閲�
                 db.Updateable<Womdaa>()
-                    .SetColumns(x =>
-                        x.Daa011 == (x.Daa011 ?? 0) + (int)barcode.Quantity
-                    )
-                    .Where(x => x.Daa001 == barcode.BillNo)
-                    .ExecuteCommandAsync();
+                        .SetColumns(x => new Womdaa
+                        {
+                            Daa011 = (x.Daa011 ?? 0) + (int)barcode.Quantity
+                        })
+                        .Where(x => x.Daa001 == barcode.BillNo)
+                        .ExecuteCommand();
 
                 // 14. 閲嶆柊鑾峰彇鏈�鏂板凡鎶ュ伐鏁伴噺
                 reportedQty = db.Queryable<MesWorkProd, MesWorkProdCDetails>(
@@ -222,7 +223,7 @@
         // 15. 杩斿洖澶勭悊缁撴灉
         return new ScanWorkResult
         {
-            TaskNo = barcode.TaskNo,
+            TaskNo = barcode.BillNo,
             ItemNo = item.ItemNo,
             PlanQty = planQty ?? 0,
             ReportedQty = reportedQty ?? 0,

--
Gitblit v1.9.3