From 460ee5d542d619d5f6c96cf44a65d84bd538cc90 Mon Sep 17 00:00:00 2001 From: "mergify[bot]" <37929162+mergify[bot]@users.noreply.github.com> Date: Mon, 3 Jun 2024 18:38:25 +0530 Subject: [PATCH] fix(Company): Allow Equity type account in unrealised exchange gain/loss account (backport #41740) (#41747) fix(Company): Allow Equity type account in unrealised exchange gain/loss account (#41740) (cherry picked from commit d30c797d2432dafb881bfb9ebc2fbd9f37ff7366) Co-authored-by: Nabin Hait --- erpnext/setup/doctype/company/company.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/erpnext/setup/doctype/company/company.js b/erpnext/setup/doctype/company/company.js index 670d898b8df..2fc7a24c287 100644 --- a/erpnext/setup/doctype/company/company.js +++ b/erpnext/setup/doctype/company/company.js @@ -251,7 +251,10 @@ erpnext.company.setup_queries = function (frm) { ["discount_allowed_account", { root_type: "Expense" }], ["discount_received_account", { root_type: "Income" }], ["exchange_gain_loss_account", { root_type: ["in", ["Expense", "Income"]] }], - ["unrealized_exchange_gain_loss_account", { root_type: ["in", ["Expense", "Income"]] }], + [ + "unrealized_exchange_gain_loss_account", + { root_type: ["in", ["Expense", "Income", "Equity", "Liability"]] }, + ], [ "accumulated_depreciation_account", { root_type: "Asset", account_type: "Accumulated Depreciation" },