diff --git a/.vs/Pilot.Report/v16/.suo b/.vs/Pilot.Report/v16/.suo index 99ce42c..32de29e 100644 Binary files a/.vs/Pilot.Report/v16/.suo and b/.vs/Pilot.Report/v16/.suo differ diff --git a/Pilot.Report.Exploitation/ResultsKanbanSummary/ResultsKanbanSumReport.cs b/Pilot.Report.Exploitation/ResultsKanbanSummary/ResultsKanbanSumReport.cs index c5343f8..632cf1c 100644 --- a/Pilot.Report.Exploitation/ResultsKanbanSummary/ResultsKanbanSumReport.cs +++ b/Pilot.Report.Exploitation/ResultsKanbanSummary/ResultsKanbanSumReport.cs @@ -611,9 +611,6 @@ namespace Pilot.Report.Exploitation.ResultsKanbanSummary SUM(t1.ShippedReceivables), SUM(t1.ExpiredReceivables), '', - null, - null, - null, 0 Sort FROM #TempTable5 t1 GROUP BY t1.Area) t1 order by t1.Area,Sort;", tableName); diff --git a/Pilot.Report.Exploitation/SpecialDetails/SpecialDetailsReport.cs b/Pilot.Report.Exploitation/SpecialDetails/SpecialDetailsReport.cs index 4b6550f..72a9fb2 100644 --- a/Pilot.Report.Exploitation/SpecialDetails/SpecialDetailsReport.cs +++ b/Pilot.Report.Exploitation/SpecialDetails/SpecialDetailsReport.cs @@ -130,6 +130,36 @@ namespace Pilot.Report.Exploitation.SpecialDetails base.BuilderReportSqlAndTempTable(filter, tableName); string sql = string.Format(@"/*dialect*/ + SELECT A.FID AS FID + INTO #TEMP3 + FROM T_SAL_ORDER A + INNER JOIN T_BD_CUSTOMER_L C ON C.FCUSTID= A.FCUSTID AND C.FLOCALEID= 2052 + LEFT JOIN V_BD_SALESMAN_L L ON L.fid = A.FSALERID + left JOIN T_PerformanceSharing M ON M.FSOURCEBILLNO = A.FBILLNO AND M.FDOCUMENTSTATUS = 'C' + left JOIN T_PerformanceSharingEntry N ON N.FID=M.FID + LEFT JOIN V_BD_SALESMAN_L O ON O.fid= N.FSALEID + LEFT JOIN ERPTOHR.HYHRV3.dbo.v_erp_empinfo ACO ON ACO.名称=O.FNAME + LEFT JOIN ERPTOHR.HYHRV3.dbo.v_erp_empinfo ACL ON ACL.名称=L.FNAME + WHERE A.FSALEORGID = 100302 AND + ACO.区域 = '碳索智控' + OR ACL.区域 = '碳索智控' + OR C.FNAME IN ('派诺科技(香港)有限公司','武汉派诺科技发展有限公司','珠海华夏云联技术有限公司','广东碳索智控科技有限公司','武汉派诺科技发展有限公司','珠海兴诺能源技术有限公司') + OR L.FNAME = '兴诺总' + "); + + if (!string.IsNullOrEmpty(fDate)) + { + sql += string.Format(@" AND FORMAT(A.FApproveDate,'yyyy-MM-dd') >= '{0}'", fDate); + } + if (!string.IsNullOrEmpty(fEndDate)) + { + sql += string.Format(@" AND FORMAT(A.FApproveDate,'yyyy-MM-dd') <= '{0}'", fEndDate); + } + + sql += string.Format(@"/*dialect*/ + + + Select * INTO #TABLEXYX From (Select A.FID From View_Table_Temp2 A JOIN View_Table_Temp3 B on A.FCONTRACTNUMBER=B.FCONTRACTNUMBER AND A.FCREATEDATE = B.FCREATEDATE @@ -147,7 +177,7 @@ namespace Pilot.Report.Exploitation.SpecialDetails ISNULL(G.FSpecification,'') as 'SizeModel', --规格型号 B.FQty-ISNULL(B3.FRetNoticeQty,0) as 'Quantity', --数量 B2.FTaxPrice as 'TaxPrice', --实际含税单价 - B2.FAllAmount-ISNULL(ABS(B3.FALLAMOUNT),0) as 'AllAmount', --价税合计 + B2.FAllAmount_LC-ISNULL(ABS(B3.FAllAmount_LC),0) as 'AllAmount', --价税合计 ISNULL(H.FNAME,'') as 'ProjectName', --项目名称 ISNULL(H2.FNAME,'') as 'SalerName', --业务员 ISNULL(H3.FNAME,'') as 'SaleDeptName', --部门 @@ -168,13 +198,13 @@ namespace Pilot.Report.Exploitation.SpecialDetails --ES、W、SX、D、CY WHEN (D.FNUMBER = 'ES' or D.FNUMBER = 'W' or D.FNUMBER = 'SX' or D.FNUMBER = 'D' or D.FNUMBER = 'CY') AND ROW_NUMBER() OVER (PARTITION BY A.F_contractnumber ORDER BY B.FSEQ) = 1 - THEN C.FBILLALLAMOUNT - CAST(ISNULL(A.F_YKQC_Text_qtr,0) as FLOAT) + THEN C.FBillAllAmount_LC - CAST(ISNULL(A.F_YKQC_Text_qtr,0) as FLOAT) --CS、CW WHEN (D.FNUMBER = 'CS' or D.FNUMBER = 'CW') AND A.FSALEORGID = 100303 THEN ((B2.FTaxPrice - B.F_SettlementP)*B.FQty) WHEN (D.FNUMBER = 'CS' or D.FNUMBER = 'CW') AND A.FSALEORGID != 100303 AND ROW_NUMBER() OVER (PARTITION BY A.F_contractnumber ORDER BY B.FSEQ) = 1 - THEN C.FBILLALLAMOUNT - CAST(ISNULL(A.F_YKQC_Text_qtr,0) as FLOAT) + THEN C.FBillAllAmount_LC - CAST(ISNULL(A.F_YKQC_Text_qtr,0) as FLOAT) ELSE null END as 'TotalSpread', --总价差(终) C2.FNAME + ',' + TRY_CAST(FLOOR(C2.F_day) as nvarchar(MAX))+'天,' + TRY_CAST(FLOOR(C2.FRecAdvanceRate) as nvarchar(MAX))+'%' @@ -183,18 +213,18 @@ namespace Pilot.Report.Exploitation.SpecialDetails WHEN A.F_ORDERTYPE = 'XT' THEN --(系统) (CASE WHEN ISNULL(A.F_XMYSSJ,'')!='' THEN CONVERT(nvarchar, A.F_XMYSSJ, 23) - WHEN C.FBillAllAmount-ISNULL(ABS(B3.FBillAllAmount),0)-ISNULL(H6.FALLAMOUNT,0) <=0 THEN '发货完成' - WHEN C.FBillAllAmount-ISNULL(ABS(B3.FBillAllAmount),0)-ISNULL(H6.FALLAMOUNT,0) = C.FBillAllAmount-ISNULL(ABS(B3.FBillAllAmount),0) + WHEN C.FBillAllAmount_LC-ISNULL(ABS(B3.FBillAllAmount_LC),0)-ISNULL(H6.FAllAmount_LC,0) <=0 THEN '发货完成' + WHEN C.FBillAllAmount_LC-ISNULL(ABS(B3.FBillAllAmount_LC),0)-ISNULL(H6.FAllAmount_LC,0) = C.FBillAllAmount_LC-ISNULL(ABS(B3.FBillAllAmount_LC),0) THEN '未发货' ELSE '部分发货' END ) ELSE '' END as 'ProjectPhase', --项目阶段 CASE WHEN ROW_NUMBER() OVER (PARTITION BY A.F_contractnumber ORDER BY B.FSEQ) = 1 THEN - C.FBillAllAmount-ISNULL(ABS(B3.FBillAllAmount),0) ELSE null + C.FBillAllAmount_LC-ISNULL(ABS(B3.FBillAllAmount_LC),0) ELSE null END as 'OrderAllAmount', --订单总额 CASE WHEN ROW_NUMBER() OVER (PARTITION BY A.F_contractnumber ORDER BY B.FSEQ) = 1 THEN - C.FBillAllAmount-ISNULL(ABS(B3.FBillAllAmount),0)-ISNULL(H6.FALLAMOUNT,0) ELSE null + C.FBillAllAmount_LC-ISNULL(ABS(B3.FBillAllAmount_LC),0)-ISNULL(H6.FAllAmount_LC,0) ELSE null END as 'NotShipmentsAmount', --未发货金额 CASE WHEN Convert(nvarchar(10),dateadd(day,isnull(C2.f_day,0) ,C2.F_PMSDate),23) > Getdate() AND C2.FRECADVANCEAMOUNT > C2.FRECAMOUNT AND ROW_NUMBER() OVER (PARTITION BY A.F_contractnumber ORDER BY B.FSEQ) = 1 @@ -210,15 +240,15 @@ namespace Pilot.Report.Exploitation.SpecialDetails T_SAL_ORDERENTRY_F B2 --销售订单明细_F表 on B.FENTRYID = B2.FENTRYID LEFT JOIN - (SELECT Aq2.FBillAllAmount,Aq.* FROM - (SELECT W2.FSID,W2.FSBILLID,STRING_AGG(CONVERT(nvarchar,W1.FDATE, 23), ',') as 'FDate',SUM(W1.FPriceUnitQty) as 'FRETNOTICEQTY',SUM(W1.FALLAMOUNT) as 'FAllAmount' FROM - (Select q1.FDATE,q3.FSID,q2.FAllAmount,q2.FPriceUnitQty From T_SAL_RETURNNOTICE q1 JOIN T_SAL_RETURNNOTICEENTRY_F q2 + (SELECT Aq2.FBillAllAmount_LC,Aq.* FROM + (SELECT W2.FSID,W2.FSBILLID,STRING_AGG(CONVERT(nvarchar,W1.FDATE, 23), ',') as 'FDate',SUM(W1.FPriceUnitQty) as 'FRETNOTICEQTY',SUM(W1.FALLAMOUNT_LC) as 'FALLAMOUNT_LC' FROM + (Select q1.FDATE,q3.FSID,q2.FAllAmount_LC,q2.FPriceUnitQty From T_SAL_RETURNNOTICE q1 JOIN T_SAL_RETURNNOTICEENTRY_F q2 on q1.FID = q2.FID JOIN T_SAL_RETURNNOTICEENTRY_LK q3 on q2.FENTRYID = q3.FENTRYID Where q1.FDocumentStatus = 'C' AND q1.FCancelStatus = 'A' AND q3.FSTABLENAME = 'T_SAL_ORDERENTRY') W1 JOIN T_SAL_ORDERENTRY_LK W2 on W1.FSID = W2.FENTRYID GROUP BY W2.FSID,W2.FSBILLID) Aq JOIN - (SELECT W2.FSBILLID,STRING_AGG(CONVERT(nvarchar,W1.FDATE, 23), ',') as 'FDate',SUM(W1.FPriceUnitQty) as 'FRETNOTICEQTY',SUM(W1.FALLAMOUNT) as 'FBillAllAmount' FROM - (Select q1.FDATE,q3.FSID,q2.FAllAmount,q2.FPriceUnitQty From T_SAL_RETURNNOTICE q1 JOIN T_SAL_RETURNNOTICEENTRY_F q2 + (SELECT W2.FSBILLID,STRING_AGG(CONVERT(nvarchar,W1.FDATE, 23), ',') as 'FDate',SUM(W1.FPriceUnitQty) as 'FRETNOTICEQTY',SUM(W1.FALLAMOUNT_LC) as 'FBillAllAmount_LC' FROM + (Select q1.FDATE,q3.FSID,q2.FAllAmount_LC,q2.FPriceUnitQty From T_SAL_RETURNNOTICE q1 JOIN T_SAL_RETURNNOTICEENTRY_F q2 on q1.FID = q2.FID JOIN T_SAL_RETURNNOTICEENTRY_LK q3 on q2.FENTRYID = q3.FENTRYID Where q1.FDocumentStatus = 'C' AND q1.FCancelStatus = 'A' AND q3.FSTABLENAME = 'T_SAL_ORDERENTRY') W1 JOIN T_SAL_ORDERENTRY_LK W2 on W1.FSID = W2.FENTRYID GROUP BY W2.FSBILLID) Aq2 @@ -323,8 +353,8 @@ namespace Pilot.Report.Exploitation.SpecialDetails AND A.FForbidStatus = 'A') H5 on H5.FMASTERID = A.FSpecialReson LEFT JOIN - (SELECT W2.FSID,SUM(W1.FALLAMOUNT) as 'FALLAMOUNT' FROM - (Select q2.FAllAmount,q2.FENTRYID From T_SAL_DELIVERYNOTICE q1 + (SELECT W2.FSID,SUM(W1.FALLAMOUNT_LC) as 'FALLAMOUNT_LC' FROM + (Select q2.FAllAmount_LC,q2.FENTRYID From T_SAL_DELIVERYNOTICE q1 JOIN T_SAL_DELIVERYNOTICEENTRY_F q2 on q1.FID = q2.FID Where q1.FDocumentStatus = 'C' AND q1.FCancelStatus = 'A') W1 @@ -342,7 +372,14 @@ namespace Pilot.Report.Exploitation.SpecialDetails Where D.FNUMBER in ('P','E','C','S') AND B.F_SPECIALOFFER = '1' AND B.F_YKQC_CheckBox_qtr != '1' AND A.FDocumentStatus = 'C' AND A.FBusinessType = 'NORMAL' AND B.FQTY >= 0 AND A.FMANUALCLOSE = '0' - AND A.FID in (Select * From #TABLEXYX)"); + AND A.FID in (Select * From #TABLEXYX) + AND A.FManualClose <> '1' + AND B.FManualRowClose <> '1' + AND A.F_contractnumber NOT LIKE 'Z%' + AND A.FID NOT IN( + SELECT FID FROM #TEMP3 + ) + "); if (!string.IsNullOrEmpty(organization)) { @@ -366,11 +403,11 @@ namespace Pilot.Report.Exploitation.SpecialDetails } if (!string.IsNullOrEmpty(fDate)) { - sql += string.Format(@" AND A.FDate >= '{0}'", fDate); + sql += string.Format(@" AND FORMAT(A.FApproveDate,'yyyy-MM-dd') >= '{0}'", fDate); } if (!string.IsNullOrEmpty(fEndDate)) { - sql += string.Format(@" AND A.FDate <= '{0}'", fEndDate); + sql += string.Format(@" AND FORMAT(A.FApproveDate,'yyyy-MM-dd') <= '{0}'", fEndDate); } sql += string.Format(@";"); @@ -379,8 +416,8 @@ namespace Pilot.Report.Exploitation.SpecialDetails Select A.FBILLNO as 'AFBILLNO', A.F_ORDERTYPE, - CONVERT(nvarchar,A.FDate,23) as 'Date', --日期 - Month(A.FDATE) as 'Month', --月份 + CONVERT(nvarchar,A.FApproveDate,23) as 'Date', --日期 + Month(A.FApproveDate) as 'Month', --月份 E.FNAME as 'Client', --购货单位 F.FNAME as 'Currency', --币别 ISNULL(E.FDATAVALUE,'') as 'CreditType', --客户信用类型 @@ -388,7 +425,7 @@ namespace Pilot.Report.Exploitation.SpecialDetails ISNULL(G.FSpecification,'') as 'SizeModel', --规格型号 B.FQty-ISNULL(B3.FRetNoticeQty,0) as 'Quantity', --数量 B2.FTaxPrice as 'TaxPrice', --实际含税单价 - B2.FAllAmount-ISNULL(ABS(B3.FALLAMOUNT),0) as 'AllAmount', --价税合计 + B2.FAllAmount_LC-ISNULL(ABS(B3.FAllAmount_LC),0) as 'AllAmount', --价税合计 ISNULL(H.FNAME,'') as 'ProjectName', --项目名称 ISNULL(H2.FNAME,'') as 'SalerName', --业务员 ISNULL(H3.FNAME,'') as 'SaleDeptName', --部门 @@ -409,13 +446,13 @@ namespace Pilot.Report.Exploitation.SpecialDetails --ES、W、SX、D、CY WHEN (D.FNUMBER = 'ES' or D.FNUMBER = 'W' or D.FNUMBER = 'SX' or D.FNUMBER = 'D' or D.FNUMBER = 'CY') AND ROW_NUMBER() OVER (PARTITION BY A.F_contractnumber ORDER BY B.FSEQ) = 1 - THEN C.FBILLALLAMOUNT - CAST(ISNULL(A.F_YKQC_Text_qtr,0) as FLOAT) + THEN C.FBillAllAmount_LC - CAST(ISNULL(A.F_YKQC_Text_qtr,0) as FLOAT) --CS、CW WHEN (D.FNUMBER = 'CS' or D.FNUMBER = 'CW') AND A.FSALEORGID = 100303 THEN ((B2.FTaxPrice - B.F_SettlementP)*B.FQty) WHEN (D.FNUMBER = 'CS' or D.FNUMBER = 'CW') AND A.FSALEORGID != 100303 AND ROW_NUMBER() OVER (PARTITION BY A.F_contractnumber ORDER BY B.FSEQ) = 1 - THEN C.FBILLALLAMOUNT - CAST(ISNULL(A.F_YKQC_Text_qtr,0) as FLOAT) + THEN C.FBillAllAmount_LC - CAST(ISNULL(A.F_YKQC_Text_qtr,0) as FLOAT) ELSE null END as 'TotalSpread', --总价差(终) C2.FNAME + ',' + TRY_CAST(FLOOR(C2.F_day) as nvarchar(MAX))+'天,' + TRY_CAST(FLOOR(C2.FRecAdvanceRate) as nvarchar(MAX))+'%' @@ -424,18 +461,18 @@ namespace Pilot.Report.Exploitation.SpecialDetails WHEN A.F_ORDERTYPE = 'XT' THEN --(系统) (CASE WHEN ISNULL(A.F_XMYSSJ,'')!='' THEN CONVERT(nvarchar, A.F_XMYSSJ, 23) - WHEN C.FBillAllAmount-ISNULL(ABS(B3.FBillAllAmount),0)-ISNULL(H6.FALLAMOUNT,0) <=0 THEN '发货完成' - WHEN C.FBillAllAmount-ISNULL(ABS(B3.FBillAllAmount),0)-ISNULL(H6.FALLAMOUNT,0) = C.FBillAllAmount-ISNULL(ABS(B3.FBillAllAmount),0) + WHEN C.FBillAllAmount_LC-ISNULL(ABS(B3.FBillAllAmount_LC),0)-ISNULL(H6.FAllAmount_LC,0) <=0 THEN '发货完成' + WHEN C.FBillAllAmount_LC-ISNULL(ABS(B3.FBillAllAmount_LC),0)-ISNULL(H6.FAllAmount_LC,0) = C.FBillAllAmount_LC-ISNULL(ABS(B3.FBillAllAmount_LC),0) THEN '未发货' ELSE '部分发货' END ) ELSE '' END as 'ProjectPhase', --项目阶段 CASE WHEN ROW_NUMBER() OVER (PARTITION BY A.F_contractnumber ORDER BY B.FSEQ) = 1 THEN - C.FBillAllAmount-ISNULL(ABS(B3.FBillAllAmount),0) ELSE null + C.FBillAllAmount_LC-ISNULL(ABS(B3.FBillAllAmount_LC),0) ELSE null END as 'OrderAllAmount', --订单总额 CASE WHEN ROW_NUMBER() OVER (PARTITION BY A.F_contractnumber ORDER BY B.FSEQ) = 1 THEN - C.FBillAllAmount-ISNULL(ABS(B3.FBillAllAmount),0)-ISNULL(H6.FALLAMOUNT,0) ELSE null + C.FBillAllAmount_LC-ISNULL(ABS(B3.FBillAllAmount_LC),0)-ISNULL(H6.FALLAMOUNT_LC,0) ELSE null END as 'NotShipmentsAmount', --未发货金额 CASE WHEN Convert(nvarchar(10),dateadd(day,isnull(C2.f_day,0) ,C2.F_PMSDate),23) > Getdate() AND C2.FRECADVANCEAMOUNT > C2.FRECAMOUNT AND ROW_NUMBER() OVER (PARTITION BY A.F_contractnumber ORDER BY B.FSEQ) = 1 @@ -451,15 +488,15 @@ namespace Pilot.Report.Exploitation.SpecialDetails T_SAL_ORDERENTRY_F B2 --销售订单明细_F表 on B.FENTRYID = B2.FENTRYID LEFT JOIN - (SELECT Aq2.FBillAllAmount,Aq.* FROM - (SELECT W2.FSID,W2.FSBILLID,STRING_AGG(CONVERT(nvarchar,W1.FDATE, 23), ',') as 'FDate',SUM(W1.FPriceUnitQty) as 'FRETNOTICEQTY',SUM(W1.FALLAMOUNT) as 'FAllAmount' FROM - (Select q1.FDATE,q3.FSID,q2.FAllAmount,q2.FPriceUnitQty From T_SAL_RETURNNOTICE q1 JOIN T_SAL_RETURNNOTICEENTRY_F q2 + (SELECT Aq2.FBillAllAmount_LC,Aq.* FROM + (SELECT W2.FSID,W2.FSBILLID,STRING_AGG(CONVERT(nvarchar,W1.FDATE, 23), ',') as 'FDate',SUM(W1.FPriceUnitQty) as 'FRETNOTICEQTY',SUM(W1.FALLAMOUNT_LC) as 'FAllAmount_LC' FROM + (Select q1.FDATE,q3.FSID,q2.FAllAmount_LC,q2.FPriceUnitQty From T_SAL_RETURNNOTICE q1 JOIN T_SAL_RETURNNOTICEENTRY_F q2 on q1.FID = q2.FID JOIN T_SAL_RETURNNOTICEENTRY_LK q3 on q2.FENTRYID = q3.FENTRYID Where q1.FDocumentStatus = 'C' AND q1.FCancelStatus = 'A' AND q3.FSTABLENAME = 'T_SAL_ORDERENTRY') W1 JOIN T_SAL_ORDERENTRY_LK W2 on W1.FSID = W2.FENTRYID GROUP BY W2.FSID,W2.FSBILLID) Aq JOIN - (SELECT W2.FSBILLID,STRING_AGG(CONVERT(nvarchar,W1.FDATE, 23), ',') as 'FDate',SUM(W1.FPriceUnitQty) as 'FRETNOTICEQTY',SUM(W1.FALLAMOUNT) as 'FBillAllAmount' FROM - (Select q1.FDATE,q3.FSID,q2.FAllAmount,q2.FPriceUnitQty From T_SAL_RETURNNOTICE q1 JOIN T_SAL_RETURNNOTICEENTRY_F q2 + (SELECT W2.FSBILLID,STRING_AGG(CONVERT(nvarchar,W1.FDATE, 23), ',') as 'FDate',SUM(W1.FPriceUnitQty) as 'FRETNOTICEQTY',SUM(W1.FALLAMOUNT_LC) as 'FBillAllAmount_LC' FROM + (Select q1.FDATE,q3.FSID,q2.FAllAmount_LC,q2.FPriceUnitQty From T_SAL_RETURNNOTICE q1 JOIN T_SAL_RETURNNOTICEENTRY_F q2 on q1.FID = q2.FID JOIN T_SAL_RETURNNOTICEENTRY_LK q3 on q2.FENTRYID = q3.FENTRYID Where q1.FDocumentStatus = 'C' AND q1.FCancelStatus = 'A' AND q3.FSTABLENAME = 'T_SAL_ORDERENTRY') W1 JOIN T_SAL_ORDERENTRY_LK W2 on W1.FSID = W2.FENTRYID GROUP BY W2.FSBILLID) Aq2 @@ -564,8 +601,8 @@ namespace Pilot.Report.Exploitation.SpecialDetails AND A.FForbidStatus = 'A') H5 on H5.FMASTERID = A.FSpecialReson LEFT JOIN - (SELECT W2.FSID,SUM(W1.FALLAMOUNT) as 'FALLAMOUNT' FROM - (Select q2.FAllAmount,q2.FENTRYID From T_SAL_DELIVERYNOTICE q1 + (SELECT W2.FSID,SUM(W1.FALLAMOUNT_LC) as 'FALLAMOUNT_LC' FROM + (Select q2.FAllAmount_LC,q2.FENTRYID From T_SAL_DELIVERYNOTICE q1 JOIN T_SAL_DELIVERYNOTICEENTRY_F q2 on q1.FID = q2.FID Where q1.FDocumentStatus = 'C' AND q1.FCancelStatus = 'A') W1 @@ -584,7 +621,14 @@ namespace Pilot.Report.Exploitation.SpecialDetails Where D.FNUMBER not in ('P','E','C','S') AND A.F_YKQC_CheckBox_qtr1 = 1 AND B.FQTY >= 0 AND A.FDocumentStatus = 'C' AND A.FBusinessType = 'NORMAL' AND A.FMANUALCLOSE = '0' - AND A.FID in (Select * From #TABLEXYX)"); + AND A.FID in (Select * From #TABLEXYX) + AND A.F_contractnumber NOT LIKE 'Z%' + AND A.FMANUALCLOSE <> '1' + AND B.FManualRowClose <> '1' + AND A.FID NOT IN( + SELECT FID FROM #TEMP3 + ) + "); if (!string.IsNullOrEmpty(organization)) { @@ -608,11 +652,11 @@ namespace Pilot.Report.Exploitation.SpecialDetails } if (!string.IsNullOrEmpty(fDate)) { - sql += string.Format(@" AND A.FAPPROVEDATE >= '{0}'", fDate); + sql += string.Format(@" AND FORMAT(A.FApproveDate,'yyyy-MM-dd') >= '{0}'", fDate); } if (!string.IsNullOrEmpty(fEndDate)) { - sql += string.Format(@" AND A.FAPPROVEDATE <= '{0}'", fEndDate); + sql += string.Format(@"AND FORMAT(A.FApproveDate,'yyyy-MM-dd') <= '{0}'", fEndDate); } sql += string.Format(@";"); diff --git a/Pilot.Report.Exploitation/bin/Debug/Pilot.Report.Exploitation.dll b/Pilot.Report.Exploitation/bin/Debug/Pilot.Report.Exploitation.dll index 8e800f4..17b783d 100644 Binary files a/Pilot.Report.Exploitation/bin/Debug/Pilot.Report.Exploitation.dll and b/Pilot.Report.Exploitation/bin/Debug/Pilot.Report.Exploitation.dll differ diff --git a/Pilot.Report.Exploitation/bin/Debug/Pilot.Report.Exploitation.pdb b/Pilot.Report.Exploitation/bin/Debug/Pilot.Report.Exploitation.pdb index 5f56cc1..b8e42c7 100644 Binary files a/Pilot.Report.Exploitation/bin/Debug/Pilot.Report.Exploitation.pdb and b/Pilot.Report.Exploitation/bin/Debug/Pilot.Report.Exploitation.pdb differ diff --git a/Pilot.Report.Exploitation/obj/Debug/Pilot.Report.Exploitation.csproj.AssemblyReference.cache b/Pilot.Report.Exploitation/obj/Debug/Pilot.Report.Exploitation.csproj.AssemblyReference.cache deleted file mode 100644 index b905b37..0000000 Binary files a/Pilot.Report.Exploitation/obj/Debug/Pilot.Report.Exploitation.csproj.AssemblyReference.cache and /dev/null differ diff --git a/Pilot.Report.Exploitation/obj/Debug/Pilot.Report.Exploitation.csproj.FileListAbsolute.txt b/Pilot.Report.Exploitation/obj/Debug/Pilot.Report.Exploitation.csproj.FileListAbsolute.txt index 0002662..ba9a95b 100644 --- a/Pilot.Report.Exploitation/obj/Debug/Pilot.Report.Exploitation.csproj.FileListAbsolute.txt +++ b/Pilot.Report.Exploitation/obj/Debug/Pilot.Report.Exploitation.csproj.FileListAbsolute.txt @@ -119,4 +119,3 @@ E:\GZC#Code\派诺报表-裴豪\派诺报表\代码\Pilot.Report\Pilot.Report\Pi E:\GZC#Code\派诺报表-裴豪\派诺报表\代码\Pilot.Report\Pilot.Report\Pilot.Report.Exploitation\obj\Debug\Pilot.Report.Exploitation.csproj.CopyComplete E:\GZC#Code\派诺报表-裴豪\派诺报表\代码\Pilot.Report\Pilot.Report\Pilot.Report.Exploitation\obj\Debug\Pilot.Report.Exploitation.dll E:\GZC#Code\派诺报表-裴豪\派诺报表\代码\Pilot.Report\Pilot.Report\Pilot.Report.Exploitation\obj\Debug\Pilot.Report.Exploitation.pdb -E:\GZC#Code\派诺报表-裴豪\派诺报表\代码\Pilot.Report\Pilot.Report\Pilot.Report.Exploitation\obj\Debug\Pilot.Report.Exploitation.csproj.AssemblyReference.cache diff --git a/Pilot.Report.Exploitation/obj/Debug/Pilot.Report.Exploitation.dll b/Pilot.Report.Exploitation/obj/Debug/Pilot.Report.Exploitation.dll index 8e800f4..17b783d 100644 Binary files a/Pilot.Report.Exploitation/obj/Debug/Pilot.Report.Exploitation.dll and b/Pilot.Report.Exploitation/obj/Debug/Pilot.Report.Exploitation.dll differ diff --git a/Pilot.Report.Exploitation/obj/Debug/Pilot.Report.Exploitation.pdb b/Pilot.Report.Exploitation/obj/Debug/Pilot.Report.Exploitation.pdb index 5f56cc1..b8e42c7 100644 Binary files a/Pilot.Report.Exploitation/obj/Debug/Pilot.Report.Exploitation.pdb and b/Pilot.Report.Exploitation/obj/Debug/Pilot.Report.Exploitation.pdb differ