From 84ad3e59e07069f043f1fe4d0849c1efc1beae60 Mon Sep 17 00:00:00 2001 From: "shiqian.wang" Date: Wed, 16 Oct 2024 16:48:45 +0800 Subject: [PATCH] =?UTF-8?q?sk=20=E6=89=A7=E8=A1=8C=E6=97=B6=E9=97=B4?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ICSSoft.FromERP/SK/YERP_008.cs | 6 +++--- ICSSoft.FromERP/SK/YERP_011.cs | 4 ++-- ICSSoft.FromERP/SK/YERP_012.cs | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/ICSSoft.FromERP/SK/YERP_008.cs b/ICSSoft.FromERP/SK/YERP_008.cs index 47853e3..d7375ed 100644 --- a/ICSSoft.FromERP/SK/YERP_008.cs +++ b/ICSSoft.FromERP/SK/YERP_008.cs @@ -66,9 +66,9 @@ namespace ICSSoft.FromERP // // // - // 过滤时间为上个月 - var beginPeriod = Dates.AddMonths(-1).AddDays(-Dates.Day + 1).ToString("yyyy-MM-dd");//"2023-06-01"; - var endPeriod = Dates.AddDays(-Dates.Day).ToString("yyyy-MM-dd");//"2023-07-01"; + // 过滤时间为昨天 + var beginPeriod = Dates.AddDays(-1).ToString("yyyy-MM-dd");//"2023-06-01"; + var endPeriod = Dates.ToString("yyyy-MM-dd");//"2023-06-30"; string sqls = @"select convert(nvarchar(10),getdate(),112) IF_STD_DATE, cInvCode ITEM_CD, d.cInvCName+' '+cInvName ITEM_NM, diff --git a/ICSSoft.FromERP/SK/YERP_011.cs b/ICSSoft.FromERP/SK/YERP_011.cs index a4abdf5..88780a0 100644 --- a/ICSSoft.FromERP/SK/YERP_011.cs +++ b/ICSSoft.FromERP/SK/YERP_011.cs @@ -60,8 +60,8 @@ namespace ICSSoft.FromERP // // // 过滤时间为上个月 - var beginPeriod = Dates.AddMonths(-1).AddDays(-Dates.Day + 1).ToString("yyyy-MM-dd");//"2023-06-01"; - var endPeriod = Dates.AddDays(-Dates.Day).ToString("yyyy-MM-dd");//"2023-06-30"; + var beginPeriod = Dates.AddDays(-1).ToString("yyyy-MM-dd");//"2023-06-01"; + var endPeriod = Dates.ToString("yyyy-MM-dd");//"2023-06-30"; string sqls = @"select convert(nvarchar(10),getdate(),112) IF_STD_DATE, cCusCode ACNT_CD, cCusName ACNT_NM, diff --git a/ICSSoft.FromERP/SK/YERP_012.cs b/ICSSoft.FromERP/SK/YERP_012.cs index 9306a7d..f46eb3b 100644 --- a/ICSSoft.FromERP/SK/YERP_012.cs +++ b/ICSSoft.FromERP/SK/YERP_012.cs @@ -68,8 +68,8 @@ namespace ICSSoft.FromERP // // 过滤时间为上个月 - var beginPeriod = Dates.AddMonths(-1).AddDays(-Dates.Day + 1).ToString("yyyy-MM-dd");//"2023-06-01"; - var endPeriod = Dates.AddDays(-Dates.Day).ToString("yyyy-MM-dd");//"2023-06-30"; + var beginPeriod = Dates.AddDays(-1).ToString("yyyy-MM-dd");//"2023-06-01"; + var endPeriod = Dates.ToString("yyyy-MM-dd");//"2023-06-30"; string sqls = @"select IF_STD_DATE,INVOICE_DATE,ITEM_CD,ITEM_NM,SKU_PAYMT_QTY_UOM,SALES_SITE_CD,SALES_SITE_NM,CREATE_BY,COUNT(*) OVER (PARTITION BY getdate()) GEN_ROW_CNT ,SUM(SKU_PAYMT_QTY) SKU_PAYMT_QTY,SUM(PAYMT_PRICE) PAYMT_PRICE