style: Fix invalid translation syntax usages
diff --git a/erpnext/assets/doctype/asset/asset.py b/erpnext/assets/doctype/asset/asset.py
index 1793dad..e8e8ec6 100644
--- a/erpnext/assets/doctype/asset/asset.py
+++ b/erpnext/assets/doctype/asset/asset.py
@@ -133,9 +133,10 @@
if self.is_existing_asset: return
if self.gross_purchase_amount and self.gross_purchase_amount != self.purchase_receipt_amount:
- frappe.throw(_("Gross Purchase Amount should be {} to purchase amount of one single Asset. {}\
- Please do not book expense of multiple assets against one single Asset.")
- .format(frappe.bold("equal"), "<br>"), title=_("Invalid Gross Purchase Amount"))
+ error_message = _("Gross Purchase Amount should be <b>equal</b> to purchase amount of one single Asset.")
+ error_message += "<br>"
+ error_message += _("Please do not book expense of multiple assets against one single Asset.")
+ frappe.throw(error_message, title=_("Invalid Gross Purchase Amount"))
def make_asset_movement(self):
reference_doctype = 'Purchase Receipt' if self.purchase_receipt else 'Purchase Invoice'
diff --git a/erpnext/hr/doctype/employee_transfer/employee_transfer.py b/erpnext/hr/doctype/employee_transfer/employee_transfer.py
index 37d616f..3539970 100644
--- a/erpnext/hr/doctype/employee_transfer/employee_transfer.py
+++ b/erpnext/hr/doctype/employee_transfer/employee_transfer.py
@@ -50,8 +50,9 @@
employee = frappe.get_doc("Employee", self.employee)
if self.create_new_employee_id:
if self.new_employee_id:
- frappe.throw(_("Please delete the Employee <a href='/app/Form/Employee/{0}'>{0}</a>\
- to cancel this document").format(self.new_employee_id))
+ frappe.throw(_("Please delete the Employee {0} to cancel this document").format(
+ "<a href='/app/Form/Employee/{0}'>{0}</a>".format(self.new_employee_id)
+ ))
#mark the employee as active
employee.status = "Active"
employee.relieving_date = ''
diff --git a/erpnext/setup/doctype/company/company.py b/erpnext/setup/doctype/company/company.py
index dc45cc1..819ba78 100644
--- a/erpnext/setup/doctype/company/company.py
+++ b/erpnext/setup/doctype/company/company.py
@@ -89,8 +89,9 @@
frappe.throw(_("Account {0} does not belong to company: {1}").format(self.get(account[1]), self.name))
if get_account_currency(self.get(account[1])) != self.default_currency:
- frappe.throw(_("""{0} currency must be same as company's default currency.
- Please select another account""").format(frappe.bold(account[0])))
+ error_message = _("{0} currency must be same as company's default currency. Please select another account.") \
+ .format(frappe.bold(account[0]))
+ frappe.throw(error_message)
def validate_currency(self):
if self.is_new():