From 56c724e8d090edfbf9d0ade1886a49c4d41ae7c9 Mon Sep 17 00:00:00 2001 From: polyfloyd Date: Mon, 22 Jan 2024 21:17:17 +0100 Subject: [PATCH] Wups, Sligro is excl. VAT --- inflatinator/scrapers.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/inflatinator/scrapers.py b/inflatinator/scrapers.py index 8972534..d4f2335 100644 --- a/inflatinator/scrapers.py +++ b/inflatinator/scrapers.py @@ -9,6 +9,9 @@ import subprocess import logging +vat = Decimal('1.09') + + class Product: def __init__(self, *, name, price, gtin, units, aliases=[]): self.name = name @@ -128,7 +131,7 @@ def sligro_get_by_gtin(gtin13): return Product( name=f'{product["brandName"]} {product["name"]} ({volume})', - price=Decimal(price_obj['value']), + price=Decimal(price_obj['value']) * vat, gtin=gtin13, units=units, aliases=[sub_gtin] if sub_gtin else [],