From 4acde4468fa6574dfeb6ca786fe4b8796a5969eb Mon Sep 17 00:00:00 2001 From: "mergify[bot]" <37929162+mergify[bot]@users.noreply.github.com> Date: Mon, 20 Mar 2023 14:27:34 +0530 Subject: [PATCH] fix: patch depends on Currency Exchange Settings (#34494) fix: patch depends on Currency Exchange Settings (#34494) (cherry picked from commit d791dc11a3eea4445e2e772125260923c43c3f9e) Co-authored-by: Raffael Meyer <14891507+barredterra@users.noreply.github.com> --- erpnext/patches/v14_0/update_opportunity_currency_fields.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/erpnext/patches/v14_0/update_opportunity_currency_fields.py b/erpnext/patches/v14_0/update_opportunity_currency_fields.py index b803e9fa2dd..af736919d83 100644 --- a/erpnext/patches/v14_0/update_opportunity_currency_fields.py +++ b/erpnext/patches/v14_0/update_opportunity_currency_fields.py @@ -7,6 +7,9 @@ from erpnext.setup.utils import get_exchange_rate def execute(): + frappe.reload_doc( + "accounts", "doctype", "currency_exchange_settings" + ) # get_exchange_rate depends on Currency Exchange Settings frappe.reload_doctype("Opportunity") opportunities = frappe.db.get_list( "Opportunity",