From 2e37035392c187b26a09a2c2edcc6133e96532cc Mon Sep 17 00:00:00 2001
From: kyy <3283105747@qq.com>
Date: 星期四, 04 九月 2025 15:57:15 +0800
Subject: [PATCH] 1、收料通知单接口 2、采购订单接口加委外订单分录内码

---
 MES.Service/service/BasicData/MesRohInManager.cs |   32 ++++----------------------------
 1 files changed, 4 insertions(+), 28 deletions(-)

diff --git a/MES.Service/service/BasicData/MesRohInManager.cs b/MES.Service/service/BasicData/MesRohInManager.cs
index 217fa4c..b6a6442 100644
--- a/MES.Service/service/BasicData/MesRohInManager.cs
+++ b/MES.Service/service/BasicData/MesRohInManager.cs
@@ -90,21 +90,16 @@
     {
         var eid = long.Parse(rohIn.id);
         var mesRohIn = new MesRohIn();
-
-
         var single = base.GetSingle(it => it.EbelnK3id == eid);
         if (single != null) mesRohIn.Guid = single.Guid;
-
         mesRohIn.EbelnK3id = eid;
         mesRohIn.BillNo = rohIn.FBillNo;
         mesRohIn.DocumentStatus = rohIn.FDocumentStatus;
         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.Supplier = rohIn.FSupplierId;
         mesRohIn.CloseStatus = rohIn.FCloseStatus;
         mesRohIn.PurchaseOrg = rohIn.FPurchaseOrgId;
@@ -117,25 +112,19 @@
         mesRohIn.Remarks = rohIn.Remarks;
         mesRohIn.CancellationStatus = rohIn.FCancelStatus;
         mesRohIn.CancellationPerson = rohIn.FCancellerId;
-
         if (rohIn.FCancelDate != null)
             if (!mesRohIn.CancellationPerson.IsNullOrEmpty())
                 mesRohIn.CancellationDate =
                     DateTime.ParseExact(rohIn.FCancelDate,
                         "yyyy-MM-dd HH:mm:ss", null);
-
         mesRohIn.CreateBy = rohIn.FCreatorId;
-
         if (rohIn.FCreateDate != null)
             mesRohIn.CreateDate = DateTime.ParseExact(rohIn.FCreateDate,
                 "yyyy-MM-dd HH:mm:ss", null);
-
         mesRohIn.LastupdateBy = rohIn.FModifierId;
-
         if (rohIn.FModifyDate != null)
             mesRohIn.LastupdateDate = DateTime.ParseExact(rohIn.FModifyDate,
                 "yyyy-MM-dd HH:mm:ss", null);
-
         mesRohIn.ErpCheckBy = rohIn.FApproverId;
         mesRohIn.ErpCheckDate = rohIn.FApproveDate;
         mesRohIn.Changereason = rohIn.FChangeReason;
@@ -143,10 +132,8 @@
             ? DateTime.ParseExact(rohIn.Prearrivaldate,
                 "yyyy-MM-dd HH:mm:ss", null)
             : null;
-
         mesRohIn.ReceiveOrgId = rohIn.FReceiveOrgId;
         mesRohIn.ProviderId = rohIn.FProviderId;
-
         mesRohIn.Anred = rohIn.FTContact;
         mesRohIn.Telf1 = rohIn.Fmobilephone;
         mesRohIn.FixedTelephone = rohIn.FixedTelephone;
@@ -195,21 +182,8 @@
                 BusinessClose = s.FMRPCloseStatus,
                 BusinessFreeze = s.FMRPFreezeStatus,
                 Freezer = s.FFreezerId,
-                //FreezeTime = !string.IsNullOrEmpty(s.FFreezeDate)
-                //            && DateTime.TryParseExact(s.FFreezeDate,
-                //                new[] { "yyyy-MM-dd HH:mm:ss", "yyyy-MM-dd" },  // 鏀寔澶氱鏍煎紡
-                //                CultureInfo.InvariantCulture,
-                //                DateTimeStyles.None,
-                //                out var parsedDate)
-                //            && parsedDate > new DateTime(1900, 1, 1)
-                //                ? parsedDate
-                //                : (DateTime?)null,
                 BusinessTerminate = s.FMRPTerminateStatus,
                 Terminator = s.FTerminaterId,
-                //TerminateTime = s.FTerminateDate != null
-                //    ? DateTime.ParseExact(s.FTerminateDate,
-                //        "yyyy-MM-dd HH:mm:ss", null)
-                //    : null,
                 TotalReceivedQty = Convert.ToDecimal(s.FReceiveQty), //绱鏀舵枡鏁�
                 RemainingReceivedQty =
                     Convert.ToDecimal(s.FRemainReceiveQty),
@@ -237,7 +211,9 @@
                 DemandDepartment = s.FRequireDeptId,
                 ReceivingDepartment = s.FReceiveDeptId,
                 SalesOrderId = s.SalesOrderId,
-                OrderLineId = s.OrderLineId
+                OrderLineId = s.OrderLineId,
+                FSUBREQENTRYID = s.FSUBREQENTRYID
+               
             };
 
             if (s.FFreezeDate != null)
@@ -255,7 +231,7 @@
             var single = rohInDataManager.GetSingle(it =>
                 it.EbelnK3id == entity.EbelnK3id);
             if (single != null) entity.Guid = single.Guid;
-
+           
             return entity;
         }).ToList();
     }

--
Gitblit v1.9.3