移位库存调整记录 调整后可用数量=库存-移位
This commit is contained in:
+2
-2
@@ -776,7 +776,7 @@ public class ShiftMaterialDetailImpl extends ServiceImpl<ShiftMaterialDetailMapp
|
|||||||
inventoryAdjustmentRecord.setFreezeAfterQuantity(materialInventory1.getFreezeQuantity() == null ? BigDecimal.ZERO : materialInventory1.getFreezeQuantity());
|
inventoryAdjustmentRecord.setFreezeAfterQuantity(materialInventory1.getFreezeQuantity() == null ? BigDecimal.ZERO : materialInventory1.getFreezeQuantity());
|
||||||
inventoryAdjustmentRecord.setInventoryBeforeQuantity(shiftMaterialDetailDO.getInventoryQuantity());
|
inventoryAdjustmentRecord.setInventoryBeforeQuantity(shiftMaterialDetailDO.getInventoryQuantity());
|
||||||
inventoryAdjustmentRecord.setInventoryAfterQuantity(shiftMaterialDetailDO.getInventoryQuantity().subtract(shiftMaterialDetailDO.getShiftQuantity()));
|
inventoryAdjustmentRecord.setInventoryAfterQuantity(shiftMaterialDetailDO.getInventoryQuantity().subtract(shiftMaterialDetailDO.getShiftQuantity()));
|
||||||
inventoryAdjustmentRecord.setAllocationAfterQuantity(shiftMaterialDetailDO.getInventoryQuantity().subtract(shiftMaterialDetailDO.getShiftQuantity()));
|
inventoryAdjustmentRecord.setAllocationAfterQuantity(materialInventory1.getAllocationQuantity().subtract(shiftMaterialDetailDO.getShiftQuantity()));
|
||||||
inventoryAdjustmentRecordMapper.insert(inventoryAdjustmentRecord);//移位前物料记录
|
inventoryAdjustmentRecordMapper.insert(inventoryAdjustmentRecord);//移位前物料记录
|
||||||
InventoryAdjustmentRecord inventoryAdjustmentRecord2 = new InventoryAdjustmentRecord();
|
InventoryAdjustmentRecord inventoryAdjustmentRecord2 = new InventoryAdjustmentRecord();
|
||||||
BeanUtils.copyProperties(inventoryAdjustmentRecord, inventoryAdjustmentRecord2);
|
BeanUtils.copyProperties(inventoryAdjustmentRecord, inventoryAdjustmentRecord2);
|
||||||
@@ -824,7 +824,7 @@ public class ShiftMaterialDetailImpl extends ServiceImpl<ShiftMaterialDetailMapp
|
|||||||
inventoryAdjustmentRecord2.setFreezeBeforeQuantity(newFreezeBefore);
|
inventoryAdjustmentRecord2.setFreezeBeforeQuantity(newFreezeBefore);
|
||||||
inventoryAdjustmentRecord2.setFreezeAfterQuantity(newFreezeBefore);
|
inventoryAdjustmentRecord2.setFreezeAfterQuantity(newFreezeBefore);
|
||||||
inventoryAdjustmentRecord2.setInventoryAfterQuantity(newInvBefore.add(shiftQty));
|
inventoryAdjustmentRecord2.setInventoryAfterQuantity(newInvBefore.add(shiftQty));
|
||||||
inventoryAdjustmentRecord2.setAllocationAfterQuantity(newAllocBefore.add(shiftQty));
|
inventoryAdjustmentRecord2.setAllocationAfterQuantity(materialInventory1.getAllocationQuantity().subtract(shiftMaterialDetailDO.getShiftQuantity()));
|
||||||
inventoryAdjustmentRecordMapper.insert(inventoryAdjustmentRecord2);//移位后物料记录(新库位增加)
|
inventoryAdjustmentRecordMapper.insert(inventoryAdjustmentRecord2);//移位后物料记录(新库位增加)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user