From d9e2a50bfc3adf5014ccbb6209884b44cf785b2b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dar=C3=ADo=20Lodeiros?= Date: Fri, 30 Dec 2022 17:44:34 +0100 Subject: [PATCH] [FIX]pms_l10n_es: ine report total group division cero --- pms_l10n_es/wizards/wizard_ine.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pms_l10n_es/wizards/wizard_ine.py b/pms_l10n_es/wizards/wizard_ine.py index 321f29e40..21dc49f83 100644 --- a/pms_l10n_es/wizards/wizard_ine.py +++ b/pms_l10n_es/wizards/wizard_ine.py @@ -739,7 +739,7 @@ class WizardIne(models.TransientModel): total_percent = sum([val for val in percents.values()]) for group in total_groups_domains.keys(): - percents[group] = round(percents[group] * 100 / total_percent, 2) + percents[group] = round(percents[group] * 100 / (total_percent or 1), 2) ET.SubElement(prices_tag, "ADR_TOUROPERADOR_TRADICIONAL").text = str( adrs["tour_operator_offline"]