From fbb71a2611d7373ea17227f8bea76735311fcbcd Mon Sep 17 00:00:00 2001 From: hrzzz Date: Thu, 30 Jun 2022 16:14:51 -0300 Subject: [PATCH 1/2] fix: translated message for credit limit blocking --- erpnext/selling/doctype/customer/customer.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/erpnext/selling/doctype/customer/customer.py b/erpnext/selling/doctype/customer/customer.py index 35e0b0de407..5f2c2641961 100644 --- a/erpnext/selling/doctype/customer/customer.py +++ b/erpnext/selling/doctype/customer/customer.py @@ -527,9 +527,9 @@ def check_credit_limit(customer, company, ignore_outstanding_sales_order=False, _("Please contact your administrator to extend the credit limits for {0}.").format(customer) ) - message = """Please contact any of the following users to extend the credit limits for {0}: -

""".format( - customer, "
  • ".join(credit_controller_users_formatted) + user_list = "

    ".format('
  • '.join(credit_controller_users_formatted)) + message = _("Please contact any of the following users to extend the credit limits for {0}: {1}").format( + customer, user_list ) # if the current user does not have permissions to override credit limit, From 8cd3eb5286b046aad4112d8914ce79cb41b54067 Mon Sep 17 00:00:00 2001 From: hrzzz Date: Mon, 4 Jul 2022 08:02:02 -0300 Subject: [PATCH 2/2] fix: translation / linters --- erpnext/selling/doctype/customer/customer.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/erpnext/selling/doctype/customer/customer.py b/erpnext/selling/doctype/customer/customer.py index 5f2c2641961..66056854728 100644 --- a/erpnext/selling/doctype/customer/customer.py +++ b/erpnext/selling/doctype/customer/customer.py @@ -527,11 +527,14 @@ def check_credit_limit(customer, company, ignore_outstanding_sales_order=False, _("Please contact your administrator to extend the credit limits for {0}.").format(customer) ) - user_list = "

    • {0}
    ".format('
  • '.join(credit_controller_users_formatted)) - message = _("Please contact any of the following users to extend the credit limits for {0}: {1}").format( - customer, user_list + user_list = "

    ".format( + "
  • ".join(credit_controller_users_formatted) ) + message = _( + "Please contact any of the following users to extend the credit limits for {0}: {1}" + ).format(customer, user_list) + # if the current user does not have permissions to override credit limit, # prompt them to send out an email to the controller users frappe.msgprint(