Skip to content

Commit

Permalink
Merge pull request #32071 from frappe/mergify/bp/version-14-hotfix/pr…
Browse files Browse the repository at this point in the history
…-32053

fix: KSA VAT report multi currency amount issue (backport #32053)
  • Loading branch information
deepeshgarg007 authored Sep 4, 2022
2 parents dd2fd12 + b96526e commit d65d2f6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions erpnext/regional/report/ksa_vat/ksa_vat.py
Original file line number Diff line number Diff line change
Expand Up @@ -177,16 +177,16 @@ def get_tax_data_for_each_vat_setting(vat_setting, filters, doctype):
"parent": invoice.name,
"item_tax_template": vat_setting.item_tax_template,
},
fields=["item_code", "net_amount"],
fields=["item_code", "base_net_amount"],
)

for item in invoice_items:
# Summing up total taxable amount
if invoice.is_return == 0:
total_taxable_amount += item.net_amount
total_taxable_amount += item.base_net_amount

if invoice.is_return == 1:
total_taxable_adjustment_amount += item.net_amount
total_taxable_adjustment_amount += item.base_net_amount

# Summing up total tax
total_tax += get_tax_amount(item.item_code, vat_setting.account, doctype, invoice.name)
Expand Down

0 comments on commit d65d2f6

Please sign in to comment.