From bf780b6c83012b5beb3d7515b8fb61753c5fb736 Mon Sep 17 00:00:00 2001 From: sjz <1240968267@qq.com> Date: 星期四, 26 六月 2025 08:48:37 +0800 Subject: [PATCH] 采购承诺交期改string类型 --- MES.Service/service/BasicData/MesRohInManager.cs | 48 +++--------------------------------------------- 1 files changed, 3 insertions(+), 45 deletions(-) diff --git a/MES.Service/service/BasicData/MesRohInManager.cs b/MES.Service/service/BasicData/MesRohInManager.cs index 9589ed2..737ae4c 100644 --- a/MES.Service/service/BasicData/MesRohInManager.cs +++ b/MES.Service/service/BasicData/MesRohInManager.cs @@ -37,50 +37,6 @@ }) > 0; } - // 鎻掑叆鏁版嵁鐨勬柟娉� - private bool InsertData(SqlSugarScope db, MesRohIn mesRohIn, - List<MesRohInData> mesRohInDatas, string FBILLTYPE) - { - switch (FBILLTYPE) - { - case "A": - { - var decimals = mesRohInDatas.Select(s => s.Id).ToArray(); - - if (mesRohIn.Id != null) base.DeleteById(mesRohIn.Id); - - if (decimals.Length > 0) - db.Deleteable<MesRohInData>().In(decimals).ExecuteCommand(); - - var insert = base.Insert(mesRohIn); - var insertRange = - rohInDataManager.InsertRange(mesRohInDatas); - - if (insert && insertRange) return true; - throw new NotImplementedException("鎻掑叆澶辫触"); - } - case "B": - { - var decimals = mesRohInDatas.Select(s => s.Id).ToArray(); - if (base.DeleteById(mesRohIn.Id) && db - .Deleteable<MesRohInData>().In(decimals) - .ExecuteCommand() > 0) - { - var insert = base.Insert(mesRohIn); - var insertRange = - rohInDataManager.InsertRange(mesRohInDatas); - - if (insert && insertRange) return true; - throw new NotImplementedException("鎻掑叆澶辫触"); - } - - break; - } - } - - throw new NotImplementedException("閲囪喘璁㈠崟绫诲瀷閿欒"); - } - // 鏇存柊鏁版嵁鐨勬柟娉� private bool UpdateData(SqlSugarScope db, MesRohIn mesRohIn, List<MesRohInData> mesRohInDatas) @@ -225,7 +181,9 @@ Settlement = s.FEntrySettleOrgId, SettlementOrg = s.FEntrySettleOrgId, DemandDept = s.FRequireDeptId, - ReceivingDept = s.FReceiveDeptId + ReceivingDept = s.FReceiveDeptId, + IsNew = Convert.ToDecimal(s.IsNewProduct), + PromiseDate = s.PromiseDate }; var single = rohInDataManager.GetSingle(it => -- Gitblit v1.9.3