|
|
@ -138,6 +138,8 @@ namespace Win.Sfs.SettleAccount.Entities.Prices |
|
|
|
else |
|
|
|
{ |
|
|
|
hasRepeat.IsCancel = false; |
|
|
|
|
|
|
|
checkList.Add(new ErrorExportDto(string.Empty, string.Empty, string.Empty, string.Empty, item.LU, string.Empty, $"零件号:{item.LU},与已存在合同签订时间、价格重复", string.Empty)); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
@ -147,6 +149,12 @@ namespace Win.Sfs.SettleAccount.Entities.Prices |
|
|
|
await _settleAccountDbContext.BulkUpdateAsync<PriceListYinDu>(oldPrices).ConfigureAwait(false); |
|
|
|
await _settleAccountDbContext.BulkInsertAsync<PriceListYinDu>(newPriceNoRepeat).ConfigureAwait(false); |
|
|
|
await transaction.CommitAsync().ConfigureAwait(false); |
|
|
|
|
|
|
|
if (checkList.Count > 0) |
|
|
|
{ |
|
|
|
var fileName = await ExportErrorReportAsync(checkList).ConfigureAwait(false); |
|
|
|
return new JsonResult(new { code = ApplicationConsts.ImportFailCode, message = "导入失败", fileName }); |
|
|
|
} |
|
|
|
} |
|
|
|
catch (Exception) |
|
|
|
{ |
|
|
|