From 2dd18c414389a87718a81f37a9ae687b735b0c8d Mon Sep 17 00:00:00 2001 From: Ali <010109ali@gmail.com> Date: Tue, 28 Oct 2025 14:11:48 +0400 Subject: [PATCH] fixed bug with none in tables name --- .../formula_editor/doctype/formula_editor/formula_editor.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/formula_editor/formula_editor/doctype/formula_editor/formula_editor.js b/formula_editor/formula_editor/doctype/formula_editor/formula_editor.js index 9ce12ff..845a000 100644 --- a/formula_editor/formula_editor/doctype/formula_editor/formula_editor.js +++ b/formula_editor/formula_editor/doctype/formula_editor/formula_editor.js @@ -750,7 +750,8 @@ frappe.require([ return; } - let label = field.label || field.fieldname || "*Нет наименования*"; // ✅ Сначала label, потом fieldname let match = label.match(/^(.*?)\s*→\s*(.*?)$/); + let label = field.label ? field.label : "*Нет наименования*"; + let match = label.match(/^(.*?)\s*→\s*(.*?)$/); let table_name = match ? match[1] : field.fieldname.startsWith("table_") ? field.fieldname : "Основные поля"; let field_label = match ? match[2] : label;