From 79aaa561766d08eb31078f2c09fcd99f026f2b46 Mon Sep 17 00:00:00 2001 From: qian Date: Thu, 23 May 2024 09:38:07 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=B1=BB=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Models/UniApiEntity/xxDiMaxes_Order.cs | 2 +- UniApiGroup/Controller/OdbcApiQadController.cs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Models/UniApiEntity/xxDiMaxes_Order.cs b/Models/UniApiEntity/xxDiMaxes_Order.cs index 518c23b..6e325d6 100644 --- a/Models/UniApiEntity/xxDiMaxes_Order.cs +++ b/Models/UniApiEntity/xxDiMaxes_Order.cs @@ -5,7 +5,7 @@ namespace CK.SCP.Models.UniApiEntity public partial class xxDiMaxes_Order { [Key] - public int UID { get; set; } + public long UID { get; set; } public string PURDOCNO { get; set; } public int DI_BATCHNO { get; set; } public string PURDOCITEMNO { get; set; } diff --git a/UniApiGroup/Controller/OdbcApiQadController.cs b/UniApiGroup/Controller/OdbcApiQadController.cs index 6a56753..97ae661 100644 --- a/UniApiGroup/Controller/OdbcApiQadController.cs +++ b/UniApiGroup/Controller/OdbcApiQadController.cs @@ -1637,12 +1637,12 @@ namespace CK.SCP.GrupUniApi.Controller { try { + DateTime time = DateTime.Now.AddYears(-1); + var hisList = idb.xxDiMaxes_Order.Where(q => q.CREATEDDATE > time).ToList(); // 读取一年内 所有审批完的一般材料订单 DataTable b = GetGeneralMaterialOrder(); List orderlist = ChangKeTec.Utils.ListHelper.DataTableToList(b); Listmaxes_Orders = ChangKeTec.Utils.ListHelper.DataTableToList(b); - DateTime time = DateTime.Now.AddYears(-1); - var hisList = idb.xxDiMaxes_Order.Where(q=>q.CREATEDDATE> time).ToList(); // 取历史表不存在的数据 var expectedList = maxes_Orders.Where(x=> !hisList.Any(e=>e.DI_BATCHNO == x.DI_BATCHNO && e.PURDOCNO == x.PURDOCNO && e.PURDOCITEMNO ==x.PURDOCITEMNO)).ToList(); if (expectedList.Count() == 0)