出库增加箱信息填写
This commit is contained in:
@@ -359,5 +359,27 @@ namespace WMS.Web.Domain.Services
|
||||
_logger.LogInformation($"同步金蝶成功");
|
||||
return (Result.ReSuccess(), SyncStatus.Success, o_dto.Numbers.First());
|
||||
}
|
||||
/// <summary>
|
||||
/// 修改出库箱信息
|
||||
/// </summary>
|
||||
/// <param name="dto"></param>
|
||||
/// <param name="loginInfo"></param>
|
||||
/// <returns></returns>
|
||||
/// <exception cref="NotImplementedException"></exception>
|
||||
public async Task<Result> EditBoxInfo(List<EditBoxInfoRequest> dto, LoginInDto loginInfo)
|
||||
{
|
||||
var ids = dto.Select(s => s.OutStockId).ToList();
|
||||
var entityList = await _outStockRepositories.GetEntityList(ids);
|
||||
foreach (var d in dto)
|
||||
{
|
||||
var entity = entityList.FirstOrDefault(f => f.Id == d.OutStockId);
|
||||
if (entity == null) return Result.ReFailure(ResultCodes.NoDateError);
|
||||
var res = entity.EditBoxInfo(d.OutStockBoxDetailsId, d.BoxLength, d.BoxWide, d.BoxHigh, d.BoxWeight, loginInfo.UserInfo.StaffId);
|
||||
if (!res.IsSuccess) return res;
|
||||
}
|
||||
var isSuccess = await _outStockRepositories.EditEntityList(entityList);
|
||||
if (!isSuccess) return Result.ReFailure(ResultCodes.DateWriteError);
|
||||
return Result.ReSuccess();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user