chore: rearranged web form tabs and fields
This commit is contained in:
parent
1b230b75e3
commit
2eb70c381a
2 changed files with 75 additions and 74 deletions
|
|
@ -188,23 +188,22 @@ function get_fields_for_doctype(doctype) {
|
||||||
function render_list_settings_message(frm) {
|
function render_list_settings_message(frm) {
|
||||||
// render list setting message
|
// render list setting message
|
||||||
if (frm.fields_dict["list_setting_message"] && !frm.doc.login_required) {
|
if (frm.fields_dict["list_setting_message"] && !frm.doc.login_required) {
|
||||||
const switch_to_form_settings_tab = `
|
const go_to_login_required_field = `
|
||||||
<span class="bold pointer" title="${__("Switch to Form Settings Tab")}">
|
<code class="pointer" title="${__("Go to Login Required field")}">
|
||||||
${__("Form Settings Tab")}
|
${__("login_required")}
|
||||||
</span>
|
</code>
|
||||||
`;
|
`;
|
||||||
$(frm.fields_dict["list_setting_message"].wrapper)
|
$(frm.fields_dict["list_setting_message"].wrapper)
|
||||||
.html(
|
.html(
|
||||||
$(
|
$(
|
||||||
`<div class="form-message blue">
|
`<div class="form-message blue">
|
||||||
${__(
|
${__("Login is required to see web form list view. Enable {0} to see list settings", [
|
||||||
"Login is required to see web form list view. Enable <code>login_required</code> from {0} to see list settings",
|
go_to_login_required_field,
|
||||||
[switch_to_form_settings_tab]
|
])}
|
||||||
)}
|
|
||||||
</div>`
|
</div>`
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
.find("span")
|
.find("code")
|
||||||
.click(() => frm.scroll_to_field("login_required"));
|
.click(() => frm.scroll_to_field("login_required"));
|
||||||
} else {
|
} else {
|
||||||
$(frm.fields_dict["list_setting_message"].wrapper).empty();
|
$(frm.fields_dict["list_setting_message"].wrapper).empty();
|
||||||
|
|
|
||||||
|
|
@ -5,50 +5,50 @@
|
||||||
"document_type": "Document",
|
"document_type": "Document",
|
||||||
"engine": "InnoDB",
|
"engine": "InnoDB",
|
||||||
"field_order": [
|
"field_order": [
|
||||||
"title_and_route_tab",
|
"form_tab",
|
||||||
"title",
|
"title",
|
||||||
"route",
|
"route",
|
||||||
"published",
|
"published",
|
||||||
"column_break_4",
|
"column_break_1",
|
||||||
"doc_type",
|
"doc_type",
|
||||||
"module",
|
"module",
|
||||||
"is_standard",
|
"is_standard",
|
||||||
"introduction",
|
"section_break_1",
|
||||||
"introduction_text",
|
"introduction_text",
|
||||||
"form_settings_tab",
|
"web_form_fields",
|
||||||
|
"settings_tab",
|
||||||
"login_required",
|
"login_required",
|
||||||
"allow_multiple",
|
"allow_multiple",
|
||||||
"allow_edit",
|
"allow_edit",
|
||||||
"allow_delete",
|
"allow_delete",
|
||||||
"column_break_18",
|
"column_break_2",
|
||||||
"apply_document_permissions",
|
"apply_document_permissions",
|
||||||
"allow_print",
|
"allow_print",
|
||||||
"print_format",
|
"print_format",
|
||||||
"allow_comments",
|
"allow_comments",
|
||||||
"show_attachments",
|
"show_attachments",
|
||||||
"allow_incomplete",
|
"allow_incomplete",
|
||||||
"form_fields",
|
"section_break_2",
|
||||||
"web_form_fields",
|
|
||||||
"max_attachment_size",
|
"max_attachment_size",
|
||||||
"list_settings_tab",
|
"section_break_3",
|
||||||
"list_setting_message",
|
"list_setting_message",
|
||||||
"show_list",
|
"show_list",
|
||||||
"list_title",
|
"list_title",
|
||||||
"list_columns",
|
"list_columns",
|
||||||
"sidebar_settings_tab",
|
"section_break_4",
|
||||||
"show_sidebar",
|
"show_sidebar",
|
||||||
"website_sidebar",
|
"website_sidebar",
|
||||||
"customization_tab",
|
"customization_tab",
|
||||||
"button_label",
|
"button_label",
|
||||||
"banner_image",
|
"banner_image",
|
||||||
"column_break_37",
|
"column_break_3",
|
||||||
"breadcrumbs",
|
"breadcrumbs",
|
||||||
"section_break_43",
|
"section_break_5",
|
||||||
"success_title",
|
"success_title",
|
||||||
"success_url",
|
"success_url",
|
||||||
"column_break_41",
|
"column_break_4",
|
||||||
"success_message",
|
"success_message",
|
||||||
"scripting_style_tab",
|
"section_break_6",
|
||||||
"client_script",
|
"client_script",
|
||||||
"custom_css"
|
"custom_css"
|
||||||
],
|
],
|
||||||
|
|
@ -81,10 +81,6 @@
|
||||||
"label": "Module",
|
"label": "Module",
|
||||||
"options": "Module Def"
|
"options": "Module Def"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"fieldname": "column_break_4",
|
|
||||||
"fieldtype": "Column Break"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"default": "0",
|
"default": "0",
|
||||||
"fieldname": "is_standard",
|
"fieldname": "is_standard",
|
||||||
|
|
@ -158,12 +154,6 @@
|
||||||
"fieldtype": "Check",
|
"fieldtype": "Check",
|
||||||
"label": "Allow Incomplete Forms"
|
"label": "Allow Incomplete Forms"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"collapsible": 1,
|
|
||||||
"fieldname": "introduction",
|
|
||||||
"fieldtype": "Section Break",
|
|
||||||
"label": "Introduction"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"fieldname": "introduction_text",
|
"fieldname": "introduction_text",
|
||||||
"fieldtype": "Text Editor",
|
"fieldtype": "Text Editor",
|
||||||
|
|
@ -250,21 +240,6 @@
|
||||||
"label": "List Columns",
|
"label": "List Columns",
|
||||||
"options": "Web Form List Column"
|
"options": "Web Form List Column"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"fieldname": "title_and_route_tab",
|
|
||||||
"fieldtype": "Tab Break",
|
|
||||||
"label": "Title & Route"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"collapsible": 1,
|
|
||||||
"fieldname": "form_fields",
|
|
||||||
"fieldtype": "Section Break",
|
|
||||||
"label": "Form Fields"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"fieldname": "column_break_18",
|
|
||||||
"fieldtype": "Column Break"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"fieldname": "website_sidebar",
|
"fieldname": "website_sidebar",
|
||||||
"fieldtype": "Link",
|
"fieldtype": "Link",
|
||||||
|
|
@ -276,29 +251,6 @@
|
||||||
"fieldtype": "HTML",
|
"fieldtype": "HTML",
|
||||||
"label": "List Setting Message"
|
"label": "List Setting Message"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"fieldname": "form_settings_tab",
|
|
||||||
"fieldtype": "Tab Break",
|
|
||||||
"label": "Form Settings"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"collapsible": 1,
|
|
||||||
"collapsible_depends_on": "show_list",
|
|
||||||
"fieldname": "list_settings_tab",
|
|
||||||
"fieldtype": "Tab Break",
|
|
||||||
"label": "List Settings"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"collapsible": 1,
|
|
||||||
"fieldname": "sidebar_settings_tab",
|
|
||||||
"fieldtype": "Tab Break",
|
|
||||||
"label": "Sidebar Settings"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"fieldname": "scripting_style_tab",
|
|
||||||
"fieldtype": "Tab Break",
|
|
||||||
"label": "Scripting / Style"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"fieldname": "customization_tab",
|
"fieldname": "customization_tab",
|
||||||
"fieldtype": "Tab Break",
|
"fieldtype": "Tab Break",
|
||||||
|
|
@ -315,24 +267,74 @@
|
||||||
"label": "Banner Image"
|
"label": "Banner Image"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"fieldname": "column_break_41",
|
"fieldname": "form_tab",
|
||||||
|
"fieldtype": "Tab Break",
|
||||||
|
"label": "Form"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"fieldname": "column_break_1",
|
||||||
"fieldtype": "Column Break"
|
"fieldtype": "Column Break"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"fieldname": "section_break_43",
|
"fieldname": "section_break_1",
|
||||||
|
"fieldtype": "Section Break"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"fieldname": "settings_tab",
|
||||||
|
"fieldtype": "Tab Break",
|
||||||
|
"label": "Settings"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"fieldname": "column_break_2",
|
||||||
|
"fieldtype": "Column Break"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"collapsible": 1,
|
||||||
|
"fieldname": "section_break_2",
|
||||||
|
"fieldtype": "Section Break"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"collapsible": 1,
|
||||||
|
"collapsible_depends_on": "show_list",
|
||||||
|
"fieldname": "section_break_3",
|
||||||
|
"fieldtype": "Section Break",
|
||||||
|
"label": "List Settings"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"collapsible": 1,
|
||||||
|
"collapsible_depends_on": "show_sidebar",
|
||||||
|
"fieldname": "section_break_4",
|
||||||
|
"fieldtype": "Section Break",
|
||||||
|
"label": "Sidebar Settings"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"fieldname": "column_break_3",
|
||||||
|
"fieldtype": "Column Break"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"collapsible": 1,
|
||||||
|
"collapsible_depends_on": "eval: doc.success_title || doc.success_message || doc.success_url",
|
||||||
|
"fieldname": "section_break_5",
|
||||||
"fieldtype": "Section Break",
|
"fieldtype": "Section Break",
|
||||||
"label": "After Submission"
|
"label": "After Submission"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"fieldname": "column_break_37",
|
"fieldname": "column_break_4",
|
||||||
"fieldtype": "Column Break"
|
"fieldtype": "Column Break"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"collapsible": 1,
|
||||||
|
"collapsible_depends_on": "eval: doc.client_script || doc.custom_css",
|
||||||
|
"fieldname": "section_break_6",
|
||||||
|
"fieldtype": "Section Break",
|
||||||
|
"label": "Scripting / Style"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"has_web_view": 1,
|
"has_web_view": 1,
|
||||||
"icon": "icon-edit",
|
"icon": "icon-edit",
|
||||||
"is_published_field": "published",
|
"is_published_field": "published",
|
||||||
"links": [],
|
"links": [],
|
||||||
"modified": "2022-08-11 16:27:25.914627",
|
"modified": "2022-08-17 18:58:49.451658",
|
||||||
"modified_by": "Administrator",
|
"modified_by": "Administrator",
|
||||||
"module": "Website",
|
"module": "Website",
|
||||||
"name": "Web Form",
|
"name": "Web Form",
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue