mirror of
https://github.com/NaN-tic/trytond-aeat_347.git
synced 2023-12-14 02:03:00 +01:00
FIX pass scenario test
This commit is contained in:
parent
b6967e1bc6
commit
ab1f882b8c
2 changed files with 4 additions and 1 deletions
|
@ -149,7 +149,8 @@ class Invoice(metaclass=PoolMeta):
|
|||
|
||||
amount = 0
|
||||
for tax in self.taxes:
|
||||
if tax.tax.include_347 and tax.tax.recargo_equivalencia:
|
||||
if tax.tax.include_347 and (hasattr(tax.tax, 'recargo_equivalencia')
|
||||
and tax.tax.recargo_equivalencia):
|
||||
amount += tax.amount
|
||||
elif tax.tax.include_347:
|
||||
amount += (tax.base + tax.amount)
|
||||
|
|
|
@ -46,8 +46,10 @@ Create chart of accounts::
|
|||
Create tax::
|
||||
|
||||
>>> tax = create_tax(Decimal('.10'))
|
||||
>>> tax.include_347 = True
|
||||
>>> tax.save()
|
||||
>>> tax2 = create_tax(Decimal('.10'))
|
||||
>>> tax2.include_347 = True
|
||||
>>> tax2.save()
|
||||
|
||||
Create party::
|
||||
|
|
Loading…
Reference in a new issue