From a6ba7caeadaeabd0a6986ffcd4aa02cbe55fb838 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Sun, 1 Dec 2024 18:38:35 +0100 Subject: [PATCH] Enforce empty value for input and output production on stock move with id The domain for Many2One is based on the target not the field value. Closes #13721 --- modules/production/stock.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/production/stock.py b/modules/production/stock.py index 2b69221ece..38e316ec8a 100644 --- a/modules/production/stock.py +++ b/modules/production/stock.py @@ -50,7 +50,7 @@ class Move(metaclass=PoolMeta): domain=[ ('company', '=', Eval('company', -1)), If(Eval('production_output', None), - ('production_input', '=', None), + ('id', '=', None), ()), ], states={ @@ -61,7 +61,7 @@ class Move(metaclass=PoolMeta): domain=[ ('company', '=', Eval('company', -1)), If(Eval('production_input', None), - ('production_output', '=', None), + ('id', '=', None), ()), ], states={