From 2fba30088084b1e70709db1c3105064255718816 Mon Sep 17 00:00:00 2001 From: Dominik George <dominik.george@teckids.org> Date: Tue, 15 Mar 2022 23:10:13 +0100 Subject: [PATCH] Fix VAT in totals table --- CHANGELOG.rst | 9 +++++++++ aleksis/apps/tezor/models/invoice.py | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index dc6e4a7..c4e216a 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -6,6 +6,14 @@ All notable changes to this project will be documented in this file. The format is based on `Keep a Changelog`_, and this project adheres to `Semantic Versioning`_. +`1.0.4`_ - 2022-03-15 +--------------------- + +Fixed +~~~~~ + +* Fixed VAT display in totals table + `1.0.3`_ - 2022-03-15 --------------------- @@ -63,3 +71,4 @@ Added .. _1.0.1: https://edugit.org/AlekSIS/onboarding//AlekSIS-App-Tezor/-/tags/1.0.1 .. _1.0.2: https://edugit.org/AlekSIS/onboarding//AlekSIS-App-Tezor/-/tags/1.0.2 .. _1.0.3: https://edugit.org/AlekSIS/onboarding//AlekSIS-App-Tezor/-/tags/1.0.3 +.. _1.0.4: https://edugit.org/AlekSIS/onboarding//AlekSIS-App-Tezor/-/tags/1.0.4 diff --git a/aleksis/apps/tezor/models/invoice.py b/aleksis/apps/tezor/models/invoice.py index b870daf..08805fe 100644 --- a/aleksis/apps/tezor/models/invoice.py +++ b/aleksis/apps/tezor/models/invoice.py @@ -168,7 +168,7 @@ class Invoice(BasePayment, PureDjangoModel): tax_amounts = {} for item in self.get_purchased_items(): tax_amounts.setdefault(item.tax_rate, 0) - tax_amounts[item.tax_rate] += item.price * item.tax_rate + tax_amounts[item.tax_rate] += item.price * item.tax_rate / 100 values = [] for tax_rate, total in tax_amounts.items(): -- GitLab