[FIX] mrp_multi_level: ariable 'move' referenced before assignment

This commit is contained in:
Lois Rilo
2024-01-25 18:31:05 -07:00
committed by BernatPForgeFlow
parent 9d0b11ddbe
commit 11b3f934e7

View File

@@ -697,9 +697,7 @@ class MultiLevelMrp(models.TransientModel):
onhand += move.mrp_qty
if onhand < product_mrp_area.mrp_minimum_stock:
mrp_date = self._get_safety_stock_target_date(product_mrp_area)
qtytoorder = self._get_qty_to_order(
product_mrp_area, move.mrp_date, 0, onhand
)
qtytoorder = self._get_qty_to_order(product_mrp_area, mrp_date, 0, onhand)
name = _("Safety Stock")
cm = self.create_action(
product_mrp_area_id=product_mrp_area,