| | |
| | | using MES.Service.Dto.webApi; |
| | | using MES.Service.Modes; |
| | | using SqlSugar; |
| | | using System.Security.AccessControl; |
| | | |
| | | namespace MES.Service.service.BasicData; |
| | | |
| | |
| | | { |
| | | var rohInErpRohIn = rohIn.ErpRohIn; |
| | | var mesRohIn = GetMesRohIn(rohInErpRohIn); |
| | | var mesRohInDatas = GetMesRohInDatas(rohIn.ErpRohinDatas, rohInErpRohIn.Type); |
| | | var mesRohInDatas = |
| | | GetMesRohInDatas(rohIn.ErpRohinDatas, rohInErpRohIn.Type); |
| | | |
| | | return UseTransaction(db => |
| | | { |
| | |
| | | }; |
| | | }) > 0; |
| | | } |
| | | |
| | | |
| | | // 更新数据的方法 |
| | | private bool UpdateData(SqlSugarScope db, MesRohIn mesRohIn, |
| | | List<MesRohInData> mesRohInDatas) |
| | |
| | | //var orUpdate = base.Insert(mesRohIn); |
| | | //var baOrUpdate = rohInDataManager.InsertRange(mesRohInDatas); |
| | | var orUpdate = db.Insertable(mesRohIn) |
| | | .IgnoreColumns(true).ExecuteCommand() > 0; |
| | | .IgnoreColumns(true).ExecuteCommand() > 0; |
| | | |
| | | |
| | | var baOrUpdate = db.Insertable(mesRohInDatas).PageSize(1) |
| | |
| | | mesRohIn.DocumentType = rohIn.FBillTypeID; |
| | | mesRohIn.BusinessType = rohIn.FBusinessType; |
| | | if (rohIn.FDate != null) |
| | | mesRohIn.PurchaseDate = DateTime.ParseExact(rohIn.FDate,"yyyy-MM-dd HH:mm:ss", null); |
| | | mesRohIn.PurchaseDate = DateTime.ParseExact(rohIn.FDate, |
| | | "yyyy-MM-dd HH:mm:ss", null); |
| | | mesRohIn.Supplier = rohIn.FSupplierId; |
| | | mesRohIn.CloseStatus = rohIn.FCloseStatus; |
| | | mesRohIn.PurchaseOrg = rohIn.FPurchaseOrgId; |
| | |
| | | FCGDDSctzda = s.F_CGDD_SCTZDA, |
| | | FCGDDXHA = s.F_CGDD_XHA, |
| | | FXifgTextApv = s.F_XIFG_Text_apv |
| | | |
| | | }; |
| | | |
| | | var single = rohInDataManager.GetSingle(it => |