Skip to content

Commit

Permalink
[FIX] l10n_do_accounting: fix when computing l10n_do_itbis_amount (#1119
Browse files Browse the repository at this point in the history
)
  • Loading branch information
daniel-pcg committed Nov 20, 2023
1 parent 392c2b5 commit c3a4e5b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion l10n_do_accounting/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"category": "Localization",
"license": "LGPL-3",
"website": "https://github.com/odoo-dominicana",
"version": "14.0.2.18.0",
"version": "14.0.2.18.1",
# any module necessary for this one to work correctly
"depends": ["l10n_latam_invoice_document", "l10n_do"],
# always loaded
Expand Down
5 changes: 4 additions & 1 deletion l10n_do_accounting/models/account_move_line.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,11 @@ def _get_price_total_and_subtotal(
line_itbis_taxes = self.tax_ids.filtered(
lambda t: t.tax_group_id == self.env.ref("l10n_do.group_itbis")
)
price_unit = self.price_unit
if self.discount:
price_unit = price_unit - (price_unit * (self.discount / 100))
itbis_taxes_data = line_itbis_taxes.compute_all(
price_unit=self.price_unit,
price_unit=price_unit,
quantity=self.quantity,
)
res["l10n_do_itbis_amount"] = sum(
Expand Down

0 comments on commit c3a4e5b

Please sign in to comment.