|
@@ -2769,7 +2769,7 @@ public class WmsDocOrderHeaderServiceImpl implements IWmsDocOrderHeaderService {
|
|
invLotAttService.insertInvLotAtt(buildInvLotAtt(lotNum, unbindWmsBoxDTO.getPalletFrom(), null, invLotAtt.getLotatt02()
|
|
invLotAttService.insertInvLotAtt(buildInvLotAtt(lotNum, unbindWmsBoxDTO.getPalletFrom(), null, invLotAtt.getLotatt02()
|
|
, unbindWmsBoxDTO.getSku(), StringUtils.isNotBlank(invLotAtt.getLotatt08()) ? invLotAtt.getLotatt08() : null));
|
|
, unbindWmsBoxDTO.getSku(), StringUtils.isNotBlank(invLotAtt.getLotatt08()) ? invLotAtt.getLotatt08() : null));
|
|
//修改库存
|
|
//修改库存
|
|
- invLotLocIdService.updateInvLotLocIdLotNum(invLotLocId.getLotnum(), lotNum, String.valueOf(locationId));
|
|
|
|
|
|
+ invLotLocIdService.updateInvLotLocIdLotNum(invLotLocId.getLotnum(), lotNum, String.valueOf(locationId), BigDecimal.ZERO);
|
|
if (StringUtils.isBlank(unbindWmsBoxDTO.getErpNo())) return AjaxResult.success("托盘:" + unbindWmsBoxDTO.getPalletTo() + "解绑成功!");
|
|
if (StringUtils.isBlank(unbindWmsBoxDTO.getErpNo())) return AjaxResult.success("托盘:" + unbindWmsBoxDTO.getPalletTo() + "解绑成功!");
|
|
|
|
|
|
WmsDocOrderHeader wmsDocOrderHeader = selectWmsDocOrderHeaderByErpNo(unbindWmsBoxDTO.getErpNo());
|
|
WmsDocOrderHeader wmsDocOrderHeader = selectWmsDocOrderHeaderByErpNo(unbindWmsBoxDTO.getErpNo());
|
|
@@ -2779,8 +2779,7 @@ public class WmsDocOrderHeaderServiceImpl implements IWmsDocOrderHeaderService {
|
|
if (CollectionUtil.isEmpty(wmsDocOrderDetailsList)) throw new BaseException("出库单明细为空!");
|
|
if (CollectionUtil.isEmpty(wmsDocOrderDetailsList)) throw new BaseException("出库单明细为空!");
|
|
wmsDocOrderDetailsList = ListUtil.reverse(wmsDocOrderDetailsList.stream().filter(item -> ObjectUtil.isNotNull(item.getQtyAllocated())
|
|
wmsDocOrderDetailsList = ListUtil.reverse(wmsDocOrderDetailsList.stream().filter(item -> ObjectUtil.isNotNull(item.getQtyAllocated())
|
|
|| !NumberUtil.equals(item.getQtyAllocated(), BigDecimal.ZERO)).collect(Collectors.toList()));
|
|
|| !NumberUtil.equals(item.getQtyAllocated(), BigDecimal.ZERO)).collect(Collectors.toList()));
|
|
- BigDecimal qtyAllocated = ObjectUtil.isNotNull(invLotLocId.getQtyallocated()) ? invLotLocId.getQtyallocated() : BigDecimal.ZERO;
|
|
|
|
- BigDecimal qty = invLotLocId.getQty().subtract(qtyAllocated);
|
|
|
|
|
|
+ BigDecimal qty = invLotLocId.getQty();
|
|
|
|
|
|
for (WmsDocOrderDetails wmsDocOrderDetails : wmsDocOrderDetailsList) {
|
|
for (WmsDocOrderDetails wmsDocOrderDetails : wmsDocOrderDetailsList) {
|
|
Boolean flag = CompareUtil.compare(qty, wmsDocOrderDetails.getQtyAllocated()) >= 0;
|
|
Boolean flag = CompareUtil.compare(qty, wmsDocOrderDetails.getQtyAllocated()) >= 0;
|