From 6236389abe9bb2f7c1e82abbb3b124dab245524e Mon Sep 17 00:00:00 2001 From: Dominik George <dominik.george@teckids.org> Date: Sun, 6 Mar 2022 23:33:22 +0100 Subject: [PATCH] Fix iteration --- aleksis/apps/tezor/models/invoice.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/aleksis/apps/tezor/models/invoice.py b/aleksis/apps/tezor/models/invoice.py index 03f4fc9..448f470 100644 --- a/aleksis/apps/tezor/models/invoice.py +++ b/aleksis/apps/tezor/models/invoice.py @@ -59,12 +59,13 @@ class Invoice(BasePayment, PureDjangoModel): tax_amounts[item.tax_rate] += item.price / (item.tax_rate + 100) * item.tax_rate values = [] - for tax_rate, total in tax_amounts: + for tax_rate, total in tax_amounts.items(): values.append({ "name": _("Included VAT {} %").format(tax_rate), "value": total, "currency": self.currency, }) + values.append({ "name": _("Gross total"), "value": self.total, -- GitLab