From b181b81ebf033cf61b691f98b2f713df2bb5ea80 Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Thu, 10 Mar 2016 17:50:27 +0530 Subject: [PATCH] [fix] mark new row as Custom Field in Customize Form to make it draggable --- frappe/custom/doctype/customize_form/customize_form.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/frappe/custom/doctype/customize_form/customize_form.js b/frappe/custom/doctype/customize_form/customize_form.js index e8eb4f3de4..ad18048554 100644 --- a/frappe/custom/doctype/customize_form/customize_form.js +++ b/frappe/custom/doctype/customize_form/customize_form.js @@ -97,6 +97,10 @@ frappe.ui.form.on("Customize Form Field", { msgprint(__("Cannot delete standard field. You can hide it if you want")); throw "cannot delete custom field"; } + }, + fields_add: function(frm, cdt, cdn) { + var f = frappe.model.get_doc(cdt, cdn); + f.is_custom_field = 1; } });