修复bug

This commit is contained in:
18942506660
2023-12-18 09:55:19 +08:00
parent 1060c964d3
commit c35351bfb9
2 changed files with 4 additions and 0 deletions

View File

@@ -65,6 +65,9 @@ namespace WMS.Web.Domain.Services
public async Task<Result> Save(List<SaveTakeStockRequest> dto, LoginInDto loginInfo)
{
_logger.LogInformation($"盘点保存:{JsonConvert.SerializeObject(dto)} 盘点人:{loginInfo.UserInfo.StaffId}");
if(dto.GroupBy(g=>g.BoxId).Count()>1)
return Result.ReFailure(ResultCodes.TakeStockBoxError);
List<TakeStock> list = new List<TakeStock>();
var profitList = dto.Where(w => w.AfterQty >= w.BeforeQty).ToList();//盘盈
var lossList = dto.Where(w => w.AfterQty < w.BeforeQty).ToList();//盘亏