From 1b2cf66f6e12ae35471b1aba623a2007a10fb17f Mon Sep 17 00:00:00 2001 From: "Ahmed Khalaf (ahkh)" Date: Thu, 19 May 2022 13:08:49 +0000 Subject: [PATCH] [FIX] mrp: skip archived operations in bom Part-of: odoo/odoo#91879 --- addons/mrp/models/mrp_routing.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/addons/mrp/models/mrp_routing.py b/addons/mrp/models/mrp_routing.py index 157a6066ca1..77376ab0372 100644 --- a/addons/mrp/models/mrp_routing.py +++ b/addons/mrp/models/mrp_routing.py @@ -107,6 +107,9 @@ class MrpRoutingWorkcenter(models.Model): custom control. """ self.ensure_one() + # skip operation line if archived + if not self.active: + return True if product._name == 'product.template': return False return not product._match_all_variant_values(self.bom_product_template_attribute_value_ids)