From 3648bda8b9f33d44ccc88a8c2893bdd30c0acbf3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E5=AD=A6=20=E8=B5=B5?= <89237069@qq.com>
Date: Mon, 29 Apr 2024 11:09:37 +0800
Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E7=89=88=E6=9C=AC?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../Entities/BQ/VmiAppService.cs | 22 +++++++++++++++++++
1 file changed, 22 insertions(+)
diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/VmiAppService.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/VmiAppService.cs
index cf31d603..1492bfe8 100644
--- a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/VmiAppService.cs
+++ b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/VmiAppService.cs
@@ -269,6 +269,28 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
return fileName;
}
+ ///
+ /// 1.1库存余额导出
+ ///
+ [HttpPost]
+ public async Task BalanceExportDiff()
+ {
+ var entities = await _vmiBalanceSumDetailRepository.Where(p=>p.SumQty!=p.ShippingQty).ToListAsync().ConfigureAwait(false);
+ // var entities = await _vmiBalanceSumDetailRepository.GetListByFilterAsync(input.Filters, input.Sorting, int.MaxValue, input.SkipCount, true).ConfigureAwait(false);
+ var dtos = _maper.Map, List>(entities);
+ dtos = dtos.OrderByDescending(p => p.BillTime).ToList();
+ var fileName = $"库存余额差异_{DateTime.Now.ToString("yyyy-MM-dd_HH-mm-ss")}.xlsx";
+ ExportImporter _exportImporter = new ExportImporter();
+ var result = await _exportImporter.ExcelExporter(dtos).ConfigureAwait(false);
+ result.ShouldNotBeNull();
+ await _excelImportService.SaveBlobAsync(new SaveExcelImportInputDto { Name = fileName, Content = result }).ConfigureAwait(false);
+ return fileName;
+ }
+
+
+
+
+
///
/// 1.2库存余额汇总查询
///