Skip to content
Snippets Groups Projects
Commit 1327022f authored by Stephane Mangin's avatar Stephane Mangin
Browse files

[FIX] stock: Add readonly constraint on product template in models stock quant/move


Avoid unwanted update of product_tmpl_id on product.product

Somehow, the field product_tmpl_id on product.product could be updated
to an unrelated product template, if the context key `default_product_tmpl_id`
is set when an inventory move is created through an update of
stock.quant.inventory_quantity.

Setting readonly to True on both stock.quant and stock.move product_tmpl_id
field prevents this unwanted update.

closes odoo/odoo#104602

Signed-off-by: default avatarWilliam Henrotin (whe) <whe@odoo.com>
parent ca3d6e09
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment