From 51c4fc9dcc3f4c7a3478e9a55fff01d7bf93c2a3 Mon Sep 17 00:00:00 2001 From: Mihir Kandoi Date: Thu, 25 Jun 2026 17:26:54 +0530 Subject: [PATCH] chore: rewrite user-facing JS messages in Manufacturing module Conservative cleanup of frappe.throw/msgprint messages per the message style guide; meaning, severity, and .format() arguments are unchanged: - index bare {} placeholders as {0}/{1}/... so translators can reorder - move f-strings / .format() / concatenation out of _() (they break gettext extraction and never translate) - wrap translatable dynamic values (DocType/Select labels) in _() - fix grammar and colloquialisms - drop no-op _() wrapping runtime-built strings Part of #53976. --- .../manufacturing/doctype/bom_update_tool/bom_update_tool.js | 2 +- erpnext/manufacturing/doctype/work_order/work_order.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/erpnext/manufacturing/doctype/bom_update_tool/bom_update_tool.js b/erpnext/manufacturing/doctype/bom_update_tool/bom_update_tool.js index 5cdb425bffc..b38961ede76 100644 --- a/erpnext/manufacturing/doctype/bom_update_tool/bom_update_tool.js +++ b/erpnext/manufacturing/doctype/bom_update_tool/bom_update_tool.js @@ -78,7 +78,7 @@ frappe.ui.form.on("BOM Update Tool", { confirm_job_start: (frm, log_data) => { let log_link = frappe.utils.get_form_link("BOM Update Log", log_data.name, true); frappe.msgprint({ - message: __("BOM Updation is queued and may take a few minutes. Check {0} for progress.", [ + message: __("BOM update is queued and may take a few minutes. Check {0} for progress.", [ log_link, ]), title: __("BOM Update Initiated"), diff --git a/erpnext/manufacturing/doctype/work_order/work_order.js b/erpnext/manufacturing/doctype/work_order/work_order.js index 28dbf5060bf..e6a39ab203e 100644 --- a/erpnext/manufacturing/doctype/work_order/work_order.js +++ b/erpnext/manufacturing/doctype/work_order/work_order.js @@ -389,7 +389,7 @@ frappe.ui.form.on("Work Order", { function () { const selected_rows = dialog.fields_dict["operations"].grid.get_selected_children(); if (selected_rows.length == 0) { - frappe.msgprint(__("Please select atleast one operation to create Job Card")); + frappe.msgprint(__("Please select at least one operation to create Job Card")); return; } frappe.call({ @@ -760,7 +760,7 @@ erpnext.work_order = { frm.add_custom_button( __("Close"), function () { - frappe.confirm(__("Once the Work Order is Closed. It can't be resumed."), () => { + frappe.confirm(__("Once the Work Order is Closed, it cannot be resumed."), () => { erpnext.work_order.change_work_order_status(frm, "Closed"); }); },