From 1cd4e66b490e4b6cc3368771cdff164990e152e7 Mon Sep 17 00:00:00 2001
From: cdk <2441919651@qq.com>
Date: 星期一, 22 十二月 2025 17:35:57 +0800
Subject: [PATCH] 接口增加单位换算,dab增加两个字段
---
MES.Service/Modes/Womcab.cs | 13 +++++++++++++
MES.Service/service/BasicData/MesRohInManager.cs | 9 ++++++++-
MES.Service/service/WomcaaManager.cs | 11 ++++++++++-
MES.Service/service/BasicData/SalesOrderManager.cs | 8 +++++++-
MES.Service/service/BasicData/ProductionOrderManager.cs | 9 +++++++--
5 files changed, 45 insertions(+), 5 deletions(-)
diff --git a/MES.Service/Modes/Womcab.cs b/MES.Service/Modes/Womcab.cs
index 87dd908..7d0e202 100644
--- a/MES.Service/Modes/Womcab.cs
+++ b/MES.Service/Modes/Womcab.cs
@@ -258,4 +258,17 @@
/// </summary>
[SugarColumn(ColumnName = "F_UNW_QTY_YFSL")]
public string? F_UNW_QTY_YFSL { get; set; }
+
+ /// <summary>
+ /// 鏄惁鍔犻攣erp涓嶈兘杩涜鐢ㄦ枡娓呭崟鍙樻洿
+ /// </summary>
+ [SugarColumn(ColumnName = "IS_LOCK")]
+ public bool? IS_LOCK { get; set; }
+
+ /// <summary>
+ /// 鍔犻攣鏃堕棿
+ /// </summary>
+ [SugarColumn(ColumnName = "IS_LOCK_DATE")]
+ public DateTime? IS_LOCK_DATE { get; set; }
+
}
\ No newline at end of file
diff --git a/MES.Service/service/BasicData/MesRohInManager.cs b/MES.Service/service/BasicData/MesRohInManager.cs
index 758b087..574ab09 100644
--- a/MES.Service/service/BasicData/MesRohInManager.cs
+++ b/MES.Service/service/BasicData/MesRohInManager.cs
@@ -83,7 +83,14 @@
.IgnoreColumnsNull()
.ExecuteCommand() > 0;
- if (orUpdate && baOrUpdate) return true;
+ if (orUpdate && baOrUpdate)
+ {
+ if (!string.IsNullOrEmpty(mesRohIn.BillNo))
+ {
+ db.Ado.ExecuteCommand("exec [dbo].[prc_unit_check] @BillNo, '閲囪喘'", new { BillNo = mesRohIn.BillNo });
+ }
+ return true;
+ }
throw new NotImplementedException("鎻掑叆鎴栨洿鏂板け璐�");
}
diff --git a/MES.Service/service/BasicData/ProductionOrderManager.cs b/MES.Service/service/BasicData/ProductionOrderManager.cs
index 412bbf0..c0e43e8 100644
--- a/MES.Service/service/BasicData/ProductionOrderManager.cs
+++ b/MES.Service/service/BasicData/ProductionOrderManager.cs
@@ -96,9 +96,14 @@
var baOrUpdate = db.Insertable(mesRohInDatas).PageSize(1)
.IgnoreColumnsNull()
.ExecuteCommand() > 0;
-
- if (orUpdate && baOrUpdate) return true;
+ if (orUpdate && baOrUpdate)
+ {
+ db.Ado.ExecuteCommand("exec [dbo].[prc_unit_check] @billno, @ModuleType",
+ new { billno = mesRohIn.OrderNo, ModuleType = "濮斿宸ュ崟" });
+
+ return true;
+ }
throw new NotImplementedException("鎻掑叆鎴栨洿鏂板け璐�");
}
diff --git a/MES.Service/service/BasicData/SalesOrderManager.cs b/MES.Service/service/BasicData/SalesOrderManager.cs
index 9b31168..08c4e2e 100644
--- a/MES.Service/service/BasicData/SalesOrderManager.cs
+++ b/MES.Service/service/BasicData/SalesOrderManager.cs
@@ -112,7 +112,13 @@
var baOrUpdate = db.Insertable(mesSalesOrderDatas).PageSize(1)
.IgnoreColumnsNull()
.ExecuteCommand() > 0;
- if (orUpdate && baOrUpdate) return true;
+ if (orUpdate && baOrUpdate)
+ {
+ db.Ado.ExecuteCommand("exec [dbo].[prc_unit_check] @billno, @ModuleType",
+ new { billno = mesSalesOrder.BillNo, ModuleType = "閿�鍞鍗�" });
+
+ return true;
+ }
throw new NotImplementedException("鎻掑叆鎴栨洿鏂板け璐�");
}
diff --git a/MES.Service/service/WomcaaManager.cs b/MES.Service/service/WomcaaManager.cs
index 9f9a6e6..f0369f4 100644
--- a/MES.Service/service/WomcaaManager.cs
+++ b/MES.Service/service/WomcaaManager.cs
@@ -84,6 +84,10 @@
if (orUpdate && baOrUpdate)
{
+ db.Ado.ExecuteCommand("exec [dbo].[prc_unit_check] @billno, @ModuleType",
+ new { billno = mesWomcaa.Caa001, ModuleType = "鐢熶骇宸ュ崟" });
+
+
// 璋冪敤瀛樺偍杩囩▼鏇存柊鐢ㄦ枡娓呭崟
db.Ado.ExecuteCommand("exec [dbo].[prc_update_womdab] @outMsg output,@outSum output,@inEdtUserGuid,@inCaaGuid",
new {
@@ -246,7 +250,12 @@
var entity = Db.Queryable<Womcab>()
.Where(s => s.Eid == womcab.Eid).Single();
- if (entity != null) womcab.Guid = entity.Guid;
+ if (entity != null) {
+ womcab.Guid = entity.Guid;
+ womcab.IS_LOCK = entity.IS_LOCK;
+ womcab.IS_LOCK_DATE = entity.IS_LOCK_DATE;
+
+ }
womcabList.Add(womcab);
}
--
Gitblit v1.9.3