From d026233f5a3346ef09d99e1e0525e1bdf7ddcddb Mon Sep 17 00:00:00 2001 From: jianghaiqing Date: Wed, 10 Apr 2024 23:05:27 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=89=8B=E5=B7=A5=E5=90=8C?= =?UTF-8?q?=E6=AD=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Entities/TaskBCEntity.cs | 5 +++ ServiceProjectSyncWin/Program.cs | 41 +++++++++++++++++++ 2 files changed, 46 insertions(+) diff --git a/ServiceProjectSyncWin/Entities/TaskBCEntity.cs b/ServiceProjectSyncWin/Entities/TaskBCEntity.cs index 24473c07..6c023bc1 100644 --- a/ServiceProjectSyncWin/Entities/TaskBCEntity.cs +++ b/ServiceProjectSyncWin/Entities/TaskBCEntity.cs @@ -57,6 +57,11 @@ namespace ServiceProjectSyncWin.Entities /// public Nullable CY_CUTOFF_TIME { get; set; } + /// + /// 客户样单截止日期 + /// + public Nullable CUSTOM_SI_CUT_DATE { get; set; } + public string TASK_ID { get; set; } public bool IsDeleted { get; set; } diff --git a/ServiceProjectSyncWin/Program.cs b/ServiceProjectSyncWin/Program.cs index a45e1b3c..b73150ce 100644 --- a/ServiceProjectSyncWin/Program.cs +++ b/ServiceProjectSyncWin/Program.cs @@ -580,9 +580,27 @@ public class SyncHisRecord: ISyncHisRecord,ITransient task.CLOSING_DATE = null; } + //CLOSING_DATE + if (BCReadInfo.CustomSICutDate.HasValue) + { + if (!task.CUSTOM_SI_CUT_DATE.HasValue || task.CUSTOM_SI_CUT_DATE.Value != BCReadInfo.CustomSICutDate.Value) + { + msgBuilder.Append($"CUSTOM_SI_CUT_DATE org={task.CUSTOM_SI_CUT_DATE} tar={BCReadInfo.CustomSICutDate.Value}##"); + + task.CUSTOM_SI_CUT_DATE = BCReadInfo.CustomSICutDate.Value; + } + } + else + { + msgBuilder.Append($"CUSTOM_SI_CUT_DATE org={task.CUSTOM_SI_CUT_DATE} tar=null##"); + + task.CUSTOM_SI_CUT_DATE = null; + } + _db.Updateable(task).UpdateColumns(it => new { it.SI_CUT_DATE, + it.CUSTOM_SI_CUT_DATE, it.VGM_CUTOFF_TIME, it.MANIFEST_CUT_DATE, it.CY_CUTOFF_TIME, @@ -718,9 +736,27 @@ public class SyncHisRecord: ISyncHisRecord,ITransient task.CLOSING_DATE = null; } + //CLOSING_DATE + if (BCReadInfo.CustomSICutDate.HasValue) + { + if (!task.CUSTOM_SI_CUT_DATE.HasValue || task.CUSTOM_SI_CUT_DATE.Value != BCReadInfo.CustomSICutDate.Value) + { + msgBuilder.Append($"CUSTOM_SI_CUT_DATE org={task.CUSTOM_SI_CUT_DATE} tar={BCReadInfo.CustomSICutDate.Value}##"); + + task.CUSTOM_SI_CUT_DATE = BCReadInfo.CustomSICutDate.Value; + } + } + else + { + msgBuilder.Append($"CUSTOM_SI_CUT_DATE org={task.CUSTOM_SI_CUT_DATE} tar=null##"); + + task.CUSTOM_SI_CUT_DATE = null; + } + _db.Updateable(task).UpdateColumns(it => new { it.SI_CUT_DATE, + it.CUSTOM_SI_CUT_DATE, it.VGM_CUTOFF_TIME, it.MANIFEST_CUT_DATE, it.CY_CUTOFF_TIME, @@ -1376,6 +1412,11 @@ public class TaskBCInfoReadDto /// 订舱确认时间 /// public Nullable BookingConfirmDate { get; set; } + + /// + /// 客户样单截止日期 + /// + public Nullable CustomSICutDate { get; set; } } ///