优化接口
This commit is contained in:
@@ -653,6 +653,14 @@ namespace WMS.Web.Domain.Services
|
||||
if (boxs == null || boxs.Count == 0)
|
||||
return Result<ContrastMaterialsResponse>.ReFailure(ResultCodes.BoxNoData);
|
||||
|
||||
//判断箱不存在所选的物料
|
||||
foreach (var item in boxs)
|
||||
{
|
||||
var isAnyHave= item.Details.Any(x => x.MaterialNumber == dto.MaterialNumber);
|
||||
if(!isAnyHave)
|
||||
return Result<ContrastMaterialsResponse>.ReFailure(item.BoxBillNo+ResultCodes.BoxNoMaterialError.Item2, ResultCodes.BoxNoMaterialError.Item1);
|
||||
}
|
||||
|
||||
//3.判断箱里面对应的物料是否存在;不存在就报错
|
||||
foreach (var item in boxs)
|
||||
{
|
||||
|
||||
@@ -46,6 +46,7 @@ namespace WMS.Web.Domain.Values
|
||||
public static ValueTuple<int, string> BoxNoData = (80000, "系统找不到该箱号");
|
||||
public static ValueTuple<int, string> InStockTaskBoxIsHaveData = (80000, "该箱已收货");
|
||||
public static ValueTuple<int, string> BoxBillNoError = (80000, "请扫描箱码作为箱号");
|
||||
public static ValueTuple<int, string> BoxNoMaterialError = (80000, "该箱不存在对应所需的物料");
|
||||
public static ValueTuple<int, string> BoxMateriaNoData = (800010, "箱对应物料信息不存在");
|
||||
public static ValueTuple<int, string> MateriaNoData = (800011, "产品信息不存在");
|
||||
public static ValueTuple<int, string> BoxInventorySerialNumbersNoData = (800012, "序列号不存在于箱库存数据中");
|
||||
|
||||
Reference in New Issue
Block a user