提示语
This commit is contained in:
@@ -490,7 +490,18 @@ namespace WMS.Web.Domain.Services
|
||||
//3.比对:false为比对失败;
|
||||
bool isRight = boxDetails.All(x => task_details.Any(t => t.MaterialId == x.MaterialId && t.AccruedQty >= x.Qty)) && boxDetails.Count <= task_details.Count;
|
||||
if (!isRight)
|
||||
{
|
||||
var qtyIsError= boxDetails.All(x => task_details.Any(t => t.MaterialId == x.MaterialId && t.AccruedQty < x.Qty));
|
||||
|
||||
if (boxDetails.Count> task_details.Count && qtyIsError)
|
||||
return Result<ContrastMaterialsResponse>.ReFailure(ResultCodes.ContrastError);
|
||||
else if(qtyIsError)
|
||||
return Result<ContrastMaterialsResponse>.ReFailure(ResultCodes.Contrast_Qty_Error);
|
||||
else
|
||||
return Result<ContrastMaterialsResponse>.ReFailure(ResultCodes.Contrast_Count_Error);
|
||||
|
||||
}
|
||||
|
||||
|
||||
//4.是否任务单存在绑定箱号判断:存在的话,就不能收货或者非采购上架
|
||||
bool isHave = task.Boxs.Where(x => dto.BoxBillNos.Contains(x.BoxBillNo)).Any();
|
||||
|
||||
@@ -43,7 +43,9 @@ namespace WMS.Web.Domain.Values
|
||||
public static ValueTuple<int, string> ErpStockNoData = (900000, "Erp仓库信息不完整");
|
||||
public static ValueTuple<int, string> Box_NoBind_Task_Data = (80001, "该箱号不在收货信息中,请核对再试!");
|
||||
public static ValueTuple<int, string> OrderNoData = (80002, "单据信息不存在,请核对后再试!");
|
||||
public static ValueTuple<int, string> ContrastError = (80003, "箱物料对应的采购订单匹配失败,请核对后再试!");
|
||||
public static ValueTuple<int, string> ContrastError = (80003, "箱内产品和数量与来源单不一致");
|
||||
public static ValueTuple<int, string> Contrast_Count_Error = (80003, "箱内产品和来源单不一致");
|
||||
public static ValueTuple<int, string> Contrast_Qty_Error = (80003, "箱内产品数量超过可入库数量");
|
||||
|
||||
public static ValueTuple<int, string> ErpOrgError = (80004, "获取Erp相关组织数据失败,请稍候再试!");
|
||||
public static ValueTuple<int, string> ErpSupplierError = (80005, "获取Erp相关供应商数据失败,请稍候再试!");
|
||||
|
||||
Reference in New Issue
Block a user