Browse Source

更新新版本

FoShanPG
Administrator 2 years ago
parent
commit
13aa767896
  1. 8
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/Prices/PriceListAppService.cs
  2. 9
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/Prices/PriceListAppServiceBJ.cs

8
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/Prices/PriceListAppService.cs

@ -206,6 +206,14 @@ namespace Win.Sfs.SettleAccount.Entities.Prices
var result = await _exportImporter.UploadExcelImport<PriceListImportDto>(files, _excelImportService);
List<string> _checkls = new List<string>();
_checkls.Add("100001");
_checkls.Add("100053");
_checkls.Add("100113");
result = result.Where(p => _checkls.Contains(p.CustomerCode)).ToList();
var entityList = ObjectMapper.Map<List<PriceListImportDto>, List<PriceList>>(result);
var _ls = entityList.Where(p=>p.EndDate.ToString().Contains("9999")).OrderByDescending(p => p.BeginDate).GroupBy(p => new { p.MaterialCode, p.CustomerCode,p.Type }).Select(p=>p.FirstOrDefault());

9
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/Prices/PriceListAppServiceBJ.cs

@ -159,18 +159,15 @@ namespace Win.Sfs.SettleAccount.Entities.Prices
virtual public async Task<string> ImportAsync([FromForm] IFormFileCollection files,string version)
{
ExportImporter _exportImporter = new ExportImporter();
var result = await _exportImporter.UploadExcelImport<PriceListBJImportDto>(files, _excelImportService);
List<string> _checkls = new List<string>();
_checkls.Add("100001");
_checkls.Add("100053");
_checkls.Add("100113");
// _checkls.Add("200067");
result = result.Where(p => _checkls.Contains(p.CustomerCode)).ToList();
var entityList = ObjectMapper.Map<List<PriceListBJImportDto>, List<PriceListBJ>>(result);
var _ls = entityList.Where(p=>p.EndDate.ToString().Contains("9999")).OrderByDescending(p => p.BeginDate).GroupBy(p => new { p.MaterialCode, p.CustomerCode,p.Type }).Select(p=>p.FirstOrDefault());

Loading…
Cancel
Save