From d3efd2dbcb872c970192698a0bbfbfe6a4f8ebca Mon Sep 17 00:00:00 2001 From: Andreas Osim Date: Tue, 17 Apr 2018 14:00:52 +0200 Subject: [PATCH] =?UTF-8?q?Zus=C3=A4tzlich=20erlaubter=20Status=20'Fehler?= =?UTF-8?q?=20Freigabe'=20(so.assembly=5Fstate=20=3D=3D=20'created'=20or?= =?UTF-8?q?=20so.assembly=5Fstate=20=3D=3D=20'failed')?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dp_custom/wizards/wizard_confirm_production.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/custom-addons/dp_custom/wizards/wizard_confirm_production.py b/ext/custom-addons/dp_custom/wizards/wizard_confirm_production.py index 9ab109c1..64471afe 100644 --- a/ext/custom-addons/dp_custom/wizards/wizard_confirm_production.py +++ b/ext/custom-addons/dp_custom/wizards/wizard_confirm_production.py @@ -18,7 +18,7 @@ class WizardConfirmProduction(models.TransientModel): sale_orders = self.env['sale.order'].browse(active_ids) if sale_orders.exists(): for so in sale_orders: - if so.assembly_state == 'created' and so.state == 'sale': + if (so.assembly_state == 'created' or so.assembly_state == 'failed') and so.state == 'sale': so.assembly_state = 'approved' else: raise ValidationError(_('Auftrag %s: Bitte prüfen Sie den PG-Status und/oder Auftragsstatus.') % so.name)