fix: use party account currency when party account is specified

(cherry picked from commit c7b961ffa27c611a1e0a45750b38f1f23b0b0c7f)
This commit is contained in:
Devin Slauenwhite 2023-12-18 18:03:53 +00:00 committed by Mergify
parent d75ac136d7
commit 32d3d4e571

View File

@ -225,7 +225,7 @@ class ReceivablePayableReport(object):
if not row:
return
if self.filters.get("in_party_currency"):
if self.filters.get("in_party_currency") or self.filters.get("party_account"):
amount = ple.amount_in_account_currency
else:
amount = ple.amount
@ -455,7 +455,7 @@ class ReceivablePayableReport(object):
party_details = self.get_party_details(row.party) or {}
row.update(party_details)
if self.filters.get("in_party_currency"):
if self.filters.get("in_party_currency") or self.filters.get("party_account"):
row.currency = row.account_currency
else:
row.currency = self.company_currency