From 112cfe6dfac66fd2b1c57c51ff0dff83eba9274a Mon Sep 17 00:00:00 2001 From: Gursheen Anand Date: Thu, 31 Aug 2023 17:08:51 +0530 Subject: [PATCH] fix: fetch discount amount for gle in base currency --- erpnext/controllers/accounts_controller.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/erpnext/controllers/accounts_controller.py b/erpnext/controllers/accounts_controller.py index 1d506390438..bfaf6bb44c5 100644 --- a/erpnext/controllers/accounts_controller.py +++ b/erpnext/controllers/accounts_controller.py @@ -1381,7 +1381,7 @@ class AccountsController(TransactionBase): { "account": self.additional_discount_account, "against": supplier_or_customer, - dr_or_cr: self.discount_amount, + dr_or_cr: self.base_discount_amount, "cost_center": self.cost_center, }, item=self, @@ -1653,6 +1653,7 @@ class AccountsController(TransactionBase): and party_account_currency != self.company_currency and self.currency != party_account_currency ): + frappe.throw( _("Accounting Entry for {0}: {1} can only be made in currency: {2}").format( party_type, party, party_account_currency