I share the following case, I am trying to make the reordering work to products that have no reordering rule outside of WH/1 and WH/2.
If I make a sale in WH/3 there is no reordering in the Inventory operations. From inventory I can activate the reordering and generate a partially blank rule.
For this I did this server action to generate them, however the error appears:
Validation error:
The operation cannot be completed: another template needs the record to be deleted. If possible, better file it.
Template: Minimum Inventory Rule (stock.warehouse.orderpoint)
Constraint: stock_warehouse_orderpoint_product_id_fkey
____________________________________________________________
Is there any way to make it so that if the product has no reorder rule it is put in Replenishment automatically?
Server action:
Model: Product
Action To Do: Create New Record
Target Model: Minimum Inventory rule
Field:
Min Qty - Value - 0
Max Qty - Value - 0
Warehouse - Reference - WH/3
Product - Python - record.id