erp材料出库单同步接口,材料出库与抽检业务编写,采购收货收货质检逻辑、采购订单同步接口完善、erp成品调拨入库同步
This commit is contained in:
@@ -3717,6 +3717,14 @@ namespace Tnb.WarehouseMgr
|
||||
qty = wmsRawmatTransferoutstockD.qty - wmsRawmatTransferoutstockD.actual_qty;
|
||||
break;
|
||||
}
|
||||
case WmsWareHouseConst.BIZTYPE_WmsRawmatOutstock_ID:
|
||||
{
|
||||
WmsRawmatOutstockD wmsRawmatOutstockD = await _db.Queryable<WmsRawmatOutstockD>().Where(r => r.id == input.source_id).FirstAsync();
|
||||
if (wmsRawmatOutstockD == null)
|
||||
throw new AppFriendlyException($"来源单据{input.source_id}不存在", 500);
|
||||
qty = wmsRawmatOutstockD.qty - wmsRawmatOutstockD.actual_outstock_qty;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
switch (basWarehouse.id)
|
||||
@@ -3785,7 +3793,7 @@ namespace Tnb.WarehouseMgr
|
||||
decimal? remainQty = qty - sumqty;
|
||||
|
||||
// 首次小于0则需要分拣
|
||||
if (remainQty < 0 && !isFindSortCarry)
|
||||
if (qty > 0 && remainQty < 0 && !isFindSortCarry)
|
||||
isFindSortCarry = true;
|
||||
else
|
||||
isFindSortCarry = false;
|
||||
@@ -3801,7 +3809,8 @@ namespace Tnb.WarehouseMgr
|
||||
barcode = g.barcode,
|
||||
code_batch = g.code_batch,
|
||||
qty = sumqty,
|
||||
sign_qty = isFindSortCarry ? qty : sumqty,
|
||||
sign_qty = isFindSortCarry ? qty : // 签收数量
|
||||
(qty > 0 ? sumqty : 0), // qty > 0时签收数量就是载具物料数量
|
||||
isSortCarry = isFindSortCarry, // 是否为分拣载具
|
||||
isSelect = isFindSortCarry || remainQty > 0, // 是否勾选
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user