diff --git a/folio.py b/folio.py index f01ccfe..887e50e 100644 --- a/folio.py +++ b/folio.py @@ -1750,11 +1750,11 @@ class FolioCharge(Workflow, ModelSQL, ModelView): def set_unit_price_w_tax(cls, charges, name, value): Tax = Pool().get('account.tax') to_write = [] - rvalue = Decimal(value).quantize('0.01') + rvalue = Decimal(value).quantize(Decimal('0.01')) for charge in charges: taxes = charge.product.customer_taxes_used unit_price = Tax.reverse_compute(rvalue, taxes) - unit_price = Decimal(unit_price).quantize('0.01') + unit_price = Decimal(unit_price).quantize(Decimal('0.01')) to_write.extend([[charge], { 'unit_price': unit_price, }])