From c4d2bab5b32c70bd40350acd231f1bb61b50bfbb Mon Sep 17 00:00:00 2001 From: ahmadRagheb Date: Thu, 1 Jun 2017 16:36:00 +0300 Subject: [PATCH] Arabic language shows Errors onSubmit in maintenance_schedule (#9082) * Arabic language shows Errors onSubmit in maintenance_schedule when trying to submit using arabic language error show up , i replace this way of formating arguments description = frappe._("Reference: %s, Item Code: %s and Customer: %s") % \ (self.name, d.item_code, self.customer) to new one :description = frappe._("Reference: %s, Item Code: %s and Customer: %s").format(self.name, d.item_code, self.customer) and it solve the problem on my local * Arabic language shows Errors onSubmit in maintenance_schedule * Arabic language shows Errors onSubmit in maintenance_schedule --- .../doctype/maintenance_schedule/maintenance_schedule.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/erpnext/maintenance/doctype/maintenance_schedule/maintenance_schedule.py b/erpnext/maintenance/doctype/maintenance_schedule/maintenance_schedule.py index 36e375ded3..fa3bcf5b2a 100644 --- a/erpnext/maintenance/doctype/maintenance_schedule/maintenance_schedule.py +++ b/erpnext/maintenance/doctype/maintenance_schedule/maintenance_schedule.py @@ -66,8 +66,7 @@ class MaintenanceSchedule(TransactionBase): parent=%s""", (d.sales_person, d.item_code, self.name), as_dict=1) for key in scheduled_date: - description = frappe._("Reference: %s, Item Code: %s and Customer: %s") % \ - (self.name, d.item_code, self.customer) + description =frappe._("Reference: {0}, Item Code: {1} and Customer: {2}").format(self.name, d.item_code, self.customer) frappe.get_doc({ "doctype": "Event", "owner": email_map.get(d.sales_person, self.owner),