diff --git a/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Repository/SettleAccountJob/Report/SettleKBWithCodeDapperReportRepository.cs b/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Repository/SettleAccountJob/Report/SettleKBWithCodeDapperReportRepository.cs index 8af3cb0f..4a4f914a 100644 --- a/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Repository/SettleAccountJob/Report/SettleKBWithCodeDapperReportRepository.cs +++ b/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Repository/SettleAccountJob/Report/SettleKBWithCodeDapperReportRepository.cs @@ -55,8 +55,8 @@ namespace Win.Sfs.SettleAccount.Repository.SettleAccountJob.Report " a.SettleDate,--结算日期\n" + " a.Qty,--用于计算\n" + " ( a.Qty- c.WMSDeliveryQty ) AS SettleWMSDiffQty,--结算与发货差异\n" + - " ( a.Qty- a.Qty ) AS SettleInvoiceDiffQty,--结算与发货差异\n" + - " 0 AS InvoiceDiffQty,--开票数量,默认0,后续拿算法动态算\n" + + " 0 AS SettleInvoiceDiffQty,--结算与发货差异\n" + + " a.Qty AS InvoiceDiffQty,--开票数量,默认0,后续拿算法动态算\n" + " d.InvoicePrice,--开票单价\n" + " 0 AS InvoiceMoney,--开票金额\n" + " '' DeliveryOrderNo --出库单号\n" + diff --git a/src/Modules/SettleAccount/src/SettleAccount.Job/Services/Report/SettleKBWithCodeExportService.cs b/src/Modules/SettleAccount/src/SettleAccount.Job/Services/Report/SettleKBWithCodeExportService.cs index 730c84ff..c01411b0 100644 --- a/src/Modules/SettleAccount/src/SettleAccount.Job/Services/Report/SettleKBWithCodeExportService.cs +++ b/src/Modules/SettleAccount/src/SettleAccount.Job/Services/Report/SettleKBWithCodeExportService.cs @@ -53,6 +53,7 @@ namespace SettleAccount.Job.Services.Report _first.InvoiceDiffQty = _first.SettleNumber + itm.DiffQty;//开票数量(结算数量+差异) _first.InvoiceMoney = _first.InvoiceDiffQty * _first.InvoicePrice;//开票总金额(开票数量*开票单价) _first.SumDiffMoney = (_first.SettleNumber * _first.Price) - _first.InvoiceMoney;//总金额差异(结算金额-开票金额) + _first.SettleInvoiceDiffQty = itm.DiffQty; } } }