Skip to content

Commit

Permalink
[16.0][FIX]l10n_es_aeat_mod369: decimal place vat and base
Browse files Browse the repository at this point in the history
  • Loading branch information
david-s73 committed Jan 30, 2025
1 parent 4f21adc commit 5e52e7c
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions l10n_es_aeat_mod369/models/mod369_line_grouped.py
Original file line number Diff line number Diff line change
Expand Up @@ -139,13 +139,15 @@ def _compute_totals(self):
def _compute_vat_type_str(self):
for line in self:
vat_type_split = str(line.vat_type).split(".")
line.vat_type_str = vat_type_split[0].zfill(3) + vat_type_split[1].zfill(2)
line.vat_type_str = vat_type_split[0].zfill(3) + vat_type_split[1].ljust(

Check warning on line 142 in l10n_es_aeat_mod369/models/mod369_line_grouped.py

View check run for this annotation

Codecov / codecov/patch

l10n_es_aeat_mod369/models/mod369_line_grouped.py#L142

Added line #L142 was not covered by tests
2, "0"
)

@api.depends("base")
def _compute_base_str(self):
for line in self:
base_split = str(line.base).split(".")
line.base_str = base_split[0].zfill(15) + base_split[1].zfill(2)
line.base_str = base_split[0].zfill(15) + base_split[1].ljust(2, "0")

Check warning on line 150 in l10n_es_aeat_mod369/models/mod369_line_grouped.py

View check run for this annotation

Codecov / codecov/patch

l10n_es_aeat_mod369/models/mod369_line_grouped.py#L150

Added line #L150 was not covered by tests

@api.depends("amount")
def _compute_amount_str(self):
Expand Down

0 comments on commit 5e52e7c

Please sign in to comment.