@@ -15,6 +15,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "label_and_type", | "fieldname": "label_and_type", | ||||
"fieldtype": "Section Break", | "fieldtype": "Section Break", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -39,6 +40,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 1, | "bold": 1, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "label", | "fieldname": "label", | ||||
"fieldtype": "Data", | "fieldtype": "Data", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -67,6 +69,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 1, | "bold": 1, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"default": "Data", | "default": "Data", | ||||
"fieldname": "fieldtype", | "fieldname": "fieldtype", | ||||
"fieldtype": "Select", | "fieldtype": "Select", | ||||
@@ -95,6 +98,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 1, | "bold": 1, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "fieldname", | "fieldname": "fieldname", | ||||
"fieldtype": "Data", | "fieldtype": "Data", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -121,6 +125,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "reqd", | "fieldname": "reqd", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -149,6 +154,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"depends_on": "eval:in_list([\"Float\", \"Currency\", \"Percent\"], doc.fieldtype)", | "depends_on": "eval:in_list([\"Float\", \"Currency\", \"Percent\"], doc.fieldtype)", | ||||
"description": "Set non-standard precision for a Float or Currency field", | "description": "Set non-standard precision for a Float or Currency field", | ||||
"fieldname": "precision", | "fieldname": "precision", | ||||
@@ -176,6 +182,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"depends_on": "eval:in_list(['Data', 'Link', 'Dynamic Link', 'Password', 'Select', 'Read Only', 'Attach', 'Attach Image'], doc.fieldtype)", | "depends_on": "eval:in_list(['Data', 'Link', 'Dynamic Link', 'Password', 'Select', 'Read Only', 'Attach', 'Attach Image'], doc.fieldtype)", | ||||
"fieldname": "length", | "fieldname": "length", | ||||
"fieldtype": "Int", | "fieldtype": "Int", | ||||
@@ -202,6 +209,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "search_index", | "fieldname": "search_index", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -230,6 +238,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "in_list_view", | "fieldname": "in_list_view", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -256,6 +265,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "bold", | "fieldname": "bold", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -281,6 +291,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"depends_on": "eval:doc.fieldtype===\"Section Break\"", | "depends_on": "eval:doc.fieldtype===\"Section Break\"", | ||||
"fieldname": "collapsible", | "fieldname": "collapsible", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
@@ -307,6 +318,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"depends_on": "eval:doc.fieldtype==\"Section Break\"", | "depends_on": "eval:doc.fieldtype==\"Section Break\"", | ||||
"fieldname": "collapsible_depends_on", | "fieldname": "collapsible_depends_on", | ||||
"fieldtype": "Code", | "fieldtype": "Code", | ||||
@@ -333,6 +345,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "column_break_6", | "fieldname": "column_break_6", | ||||
"fieldtype": "Column Break", | "fieldtype": "Column Break", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -356,6 +369,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"description": "For Links, enter the DocType as range.\nFor Select, enter list of Options, each on a new line.", | "description": "For Links, enter the DocType as range.\nFor Select, enter list of Options, each on a new line.", | ||||
"fieldname": "options", | "fieldname": "options", | ||||
"fieldtype": "Text", | "fieldtype": "Text", | ||||
@@ -383,6 +397,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "default", | "fieldname": "default", | ||||
"fieldtype": "Small Text", | "fieldtype": "Small Text", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -409,6 +424,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "permissions", | "fieldname": "permissions", | ||||
"fieldtype": "Section Break", | "fieldtype": "Section Break", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -433,6 +449,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "depends_on", | "fieldname": "depends_on", | ||||
"fieldtype": "Code", | "fieldtype": "Code", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -459,6 +476,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "hidden", | "fieldname": "hidden", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -487,6 +505,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "read_only", | "fieldname": "read_only", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -513,6 +532,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "unique", | "fieldname": "unique", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -538,6 +558,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"description": "Do not allow user to change after set the first time", | "description": "Do not allow user to change after set the first time", | ||||
"fieldname": "set_only_once", | "fieldname": "set_only_once", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
@@ -563,6 +584,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "column_break_13", | "fieldname": "column_break_13", | ||||
"fieldtype": "Column Break", | "fieldtype": "Column Break", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -586,6 +608,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"default": "0", | "default": "0", | ||||
"fieldname": "permlevel", | "fieldname": "permlevel", | ||||
"fieldtype": "Int", | "fieldtype": "Int", | ||||
@@ -615,6 +638,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"description": "User permissions should not apply for this Link", | "description": "User permissions should not apply for this Link", | ||||
"fieldname": "ignore_user_permissions", | "fieldname": "ignore_user_permissions", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
@@ -640,6 +664,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "allow_on_submit", | "fieldname": "allow_on_submit", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -668,6 +693,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "report_hide", | "fieldname": "report_hide", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -696,6 +722,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"description": "Don't HTML Encode HTML tags like <script> or just characters like < or >, as they could be intentionally used in this field", | "description": "Don't HTML Encode HTML tags like <script> or just characters like < or >, as they could be intentionally used in this field", | ||||
"fieldname": "ignore_xss_filter", | "fieldname": "ignore_xss_filter", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
@@ -722,6 +749,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "display", | "fieldname": "display", | ||||
"fieldtype": "Section Break", | "fieldtype": "Section Break", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -746,6 +774,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "in_filter", | "fieldname": "in_filter", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -774,6 +803,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "no_copy", | "fieldname": "no_copy", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -802,6 +832,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "print_hide", | "fieldname": "print_hide", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -830,6 +861,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"depends_on": "eval:[\"Int\", \"Float\", \"Currency\", \"Percent\"].indexOf(doc.fieldtype)!==-1", | "depends_on": "eval:[\"Int\", \"Float\", \"Currency\", \"Percent\"].indexOf(doc.fieldtype)!==-1", | ||||
"fieldname": "print_hide_if_no_value", | "fieldname": "print_hide_if_no_value", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
@@ -856,6 +888,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "print_width", | "fieldname": "print_width", | ||||
"fieldtype": "Data", | "fieldtype": "Data", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -880,6 +913,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "width", | "fieldname": "width", | ||||
"fieldtype": "Data", | "fieldtype": "Data", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -908,6 +942,35 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"depends_on": "eval:cur_frm.doc.istable", | |||||
"description": "Number of columns for a field in a Grid (Total Columns in a grid should be less than 11)", | |||||
"fieldname": "columns", | |||||
"fieldtype": "Int", | |||||
"hidden": 0, | |||||
"ignore_user_permissions": 0, | |||||
"ignore_xss_filter": 0, | |||||
"in_filter": 0, | |||||
"in_list_view": 0, | |||||
"label": "Columns", | |||||
"length": 0, | |||||
"no_copy": 0, | |||||
"permlevel": 0, | |||||
"precision": "", | |||||
"print_hide": 0, | |||||
"print_hide_if_no_value": 0, | |||||
"read_only": 0, | |||||
"report_hide": 0, | |||||
"reqd": 0, | |||||
"search_index": 0, | |||||
"set_only_once": 0, | |||||
"unique": 0 | |||||
}, | |||||
{ | |||||
"allow_on_submit": 0, | |||||
"bold": 0, | |||||
"collapsible": 0, | |||||
"columns": 0, | |||||
"fieldname": "column_break_22", | "fieldname": "column_break_22", | ||||
"fieldtype": "Column Break", | "fieldtype": "Column Break", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -931,6 +994,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "description", | "fieldname": "description", | ||||
"fieldtype": "Small Text", | "fieldtype": "Small Text", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -959,6 +1023,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "oldfieldname", | "fieldname": "oldfieldname", | ||||
"fieldtype": "Data", | "fieldtype": "Data", | ||||
"hidden": 1, | "hidden": 1, | ||||
@@ -984,6 +1049,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "oldfieldtype", | "fieldname": "oldfieldtype", | ||||
"fieldtype": "Data", | "fieldtype": "Data", | ||||
"hidden": 1, | "hidden": 1, | ||||
@@ -1016,7 +1082,7 @@ | |||||
"issingle": 0, | "issingle": 0, | ||||
"istable": 1, | "istable": 1, | ||||
"max_attachments": 0, | "max_attachments": 0, | ||||
"modified": "2016-07-11 03:25:57.882851", | |||||
"modified": "2016-08-23 11:59:07.036627", | |||||
"modified_by": "Administrator", | "modified_by": "Administrator", | ||||
"module": "Core", | "module": "Core", | ||||
"name": "DocField", | "name": "DocField", | ||||
@@ -1026,5 +1092,5 @@ | |||||
"read_only": 0, | "read_only": 0, | ||||
"read_only_onload": 0, | "read_only_onload": 0, | ||||
"sort_order": "ASC", | "sort_order": "ASC", | ||||
"track_seen": 0 | |||||
"track_seen": 0 | |||||
} | } |
@@ -54,7 +54,8 @@ docfield_properties = { | |||||
'default': 'Text', | 'default': 'Text', | ||||
'precision': 'Select', | 'precision': 'Select', | ||||
'read_only': 'Check', | 'read_only': 'Check', | ||||
'length': 'Int' | |||||
'length': 'Int', | |||||
'columns': 'Int' | |||||
} | } | ||||
allowed_fieldtype_change = (('Currency', 'Float', 'Percent'), ('Small Text', 'Data'), | allowed_fieldtype_change = (('Currency', 'Float', 'Percent'), ('Small Text', 'Data'), | ||||
@@ -15,6 +15,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "label_and_type", | "fieldname": "label_and_type", | ||||
"fieldtype": "Section Break", | "fieldtype": "Section Break", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -40,6 +41,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "label", | "fieldname": "label", | ||||
"fieldtype": "Data", | "fieldtype": "Data", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -66,6 +68,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"default": "Data", | "default": "Data", | ||||
"fieldname": "fieldtype", | "fieldname": "fieldtype", | ||||
"fieldtype": "Select", | "fieldtype": "Select", | ||||
@@ -94,6 +97,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "fieldname", | "fieldname": "fieldname", | ||||
"fieldtype": "Data", | "fieldtype": "Data", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -120,6 +124,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "reqd", | "fieldname": "reqd", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -148,6 +153,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "unique", | "fieldname": "unique", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -173,6 +179,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "in_list_view", | "fieldname": "in_list_view", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -197,6 +204,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "column_break_7", | "fieldname": "column_break_7", | ||||
"fieldtype": "Column Break", | "fieldtype": "Column Break", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -221,6 +229,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"depends_on": "eval:in_list([\"Float\", \"Currency\", \"Percent\"], doc.fieldtype)", | "depends_on": "eval:in_list([\"Float\", \"Currency\", \"Percent\"], doc.fieldtype)", | ||||
"description": "Set non-standard precision for a Float or Currency field", | "description": "Set non-standard precision for a Float or Currency field", | ||||
"fieldname": "precision", | "fieldname": "precision", | ||||
@@ -249,6 +258,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"depends_on": "eval:in_list(['Data', 'Link', 'Dynamic Link', 'Password', 'Select', 'Read Only', 'Attach', 'Attach Image'], doc.fieldtype)", | "depends_on": "eval:in_list(['Data', 'Link', 'Dynamic Link', 'Password', 'Select', 'Read Only', 'Attach', 'Attach Image'], doc.fieldtype)", | ||||
"fieldname": "length", | "fieldname": "length", | ||||
"fieldtype": "Int", | "fieldtype": "Int", | ||||
@@ -275,6 +285,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"description": "For Links, enter the DocType as range.\nFor Select, enter list of Options, each on a new line.", | "description": "For Links, enter the DocType as range.\nFor Select, enter list of Options, each on a new line.", | ||||
"fieldname": "options", | "fieldname": "options", | ||||
"fieldtype": "Text", | "fieldtype": "Text", | ||||
@@ -302,6 +313,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "permissions", | "fieldname": "permissions", | ||||
"fieldtype": "Section Break", | "fieldtype": "Section Break", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -327,6 +339,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"description": "This field will appear only if the fieldname defined here has value OR the rules are true (examples): \nmyfield\neval:doc.myfield=='My Value'\neval:doc.age>18", | "description": "This field will appear only if the fieldname defined here has value OR the rules are true (examples): \nmyfield\neval:doc.myfield=='My Value'\neval:doc.age>18", | ||||
"fieldname": "depends_on", | "fieldname": "depends_on", | ||||
"fieldtype": "Code", | "fieldtype": "Code", | ||||
@@ -354,6 +367,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"default": "0", | "default": "0", | ||||
"fieldname": "permlevel", | "fieldname": "permlevel", | ||||
"fieldtype": "Int", | "fieldtype": "Int", | ||||
@@ -381,6 +395,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "hidden", | "fieldname": "hidden", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -409,6 +424,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "read_only", | "fieldname": "read_only", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -434,6 +450,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"depends_on": "eval:doc.fieldtype==\"Section Break\"", | "depends_on": "eval:doc.fieldtype==\"Section Break\"", | ||||
"fieldname": "collapsible", | "fieldname": "collapsible", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
@@ -460,6 +477,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"depends_on": "eval:doc.fieldtype==\"Section Break\"", | "depends_on": "eval:doc.fieldtype==\"Section Break\"", | ||||
"fieldname": "collapsible_depends_on", | "fieldname": "collapsible_depends_on", | ||||
"fieldtype": "Code", | "fieldtype": "Code", | ||||
@@ -486,6 +504,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "column_break_14", | "fieldname": "column_break_14", | ||||
"fieldtype": "Column Break", | "fieldtype": "Column Break", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -510,6 +529,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "ignore_user_permissions", | "fieldname": "ignore_user_permissions", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -534,6 +554,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "allow_on_submit", | "fieldname": "allow_on_submit", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -560,6 +581,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "report_hide", | "fieldname": "report_hide", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -586,6 +608,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "display", | "fieldname": "display", | ||||
"fieldtype": "Section Break", | "fieldtype": "Section Break", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -611,6 +634,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "default", | "fieldname": "default", | ||||
"fieldtype": "Text", | "fieldtype": "Text", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -637,6 +661,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "in_filter", | "fieldname": "in_filter", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -665,6 +690,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "column_break_21", | "fieldname": "column_break_21", | ||||
"fieldtype": "Column Break", | "fieldtype": "Column Break", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -689,6 +715,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "description", | "fieldname": "description", | ||||
"fieldtype": "Text", | "fieldtype": "Text", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -717,6 +744,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "print_hide", | "fieldname": "print_hide", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -743,6 +771,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"depends_on": "eval:[\"Int\", \"Float\", \"Currency\", \"Percent\"].indexOf(doc.fieldtype)!==-1", | "depends_on": "eval:[\"Int\", \"Float\", \"Currency\", \"Percent\"].indexOf(doc.fieldtype)!==-1", | ||||
"fieldname": "print_hide_if_no_value", | "fieldname": "print_hide_if_no_value", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
@@ -769,6 +798,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"description": "Print Width of the field, if the field is a column in a table", | "description": "Print Width of the field, if the field is a column in a table", | ||||
"fieldname": "print_width", | "fieldname": "print_width", | ||||
"fieldtype": "Data", | "fieldtype": "Data", | ||||
@@ -796,6 +826,35 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"depends_on": "eval:cur_frm.doc.istable", | |||||
"description": "Number of columns for a field in a Grid (Total Columns in a grid should be less than 11)", | |||||
"fieldname": "columns", | |||||
"fieldtype": "Int", | |||||
"hidden": 0, | |||||
"ignore_user_permissions": 0, | |||||
"ignore_xss_filter": 0, | |||||
"in_filter": 0, | |||||
"in_list_view": 0, | |||||
"label": "Columns", | |||||
"length": 0, | |||||
"no_copy": 0, | |||||
"permlevel": 0, | |||||
"precision": "", | |||||
"print_hide": 0, | |||||
"print_hide_if_no_value": 0, | |||||
"read_only": 0, | |||||
"report_hide": 0, | |||||
"reqd": 0, | |||||
"search_index": 0, | |||||
"set_only_once": 0, | |||||
"unique": 0 | |||||
}, | |||||
{ | |||||
"allow_on_submit": 0, | |||||
"bold": 0, | |||||
"collapsible": 0, | |||||
"columns": 0, | |||||
"fieldname": "width", | "fieldname": "width", | ||||
"fieldtype": "Data", | "fieldtype": "Data", | ||||
"hidden": 0, | "hidden": 0, | ||||
@@ -824,6 +883,7 @@ | |||||
"allow_on_submit": 0, | "allow_on_submit": 0, | ||||
"bold": 0, | "bold": 0, | ||||
"collapsible": 0, | "collapsible": 0, | ||||
"columns": 0, | |||||
"fieldname": "is_custom_field", | "fieldname": "is_custom_field", | ||||
"fieldtype": "Check", | "fieldtype": "Check", | ||||
"hidden": 1, | "hidden": 1, | ||||
@@ -856,7 +916,7 @@ | |||||
"issingle": 0, | "issingle": 0, | ||||
"istable": 1, | "istable": 1, | ||||
"max_attachments": 0, | "max_attachments": 0, | ||||
"modified": "2016-07-11 03:27:58.928043", | |||||
"modified": "2016-08-23 12:03:07.126339", | |||||
"modified_by": "Administrator", | "modified_by": "Administrator", | ||||
"module": "Custom", | "module": "Custom", | ||||
"name": "Customize Form Field", | "name": "Customize Form Field", | ||||
@@ -865,5 +925,6 @@ | |||||
"quick_entry": 0, | "quick_entry": 0, | ||||
"read_only": 0, | "read_only": 0, | ||||
"read_only_onload": 0, | "read_only_onload": 0, | ||||
"sort_order": "ASC", | |||||
"track_seen": 0 | "track_seen": 0 | ||||
} | } |
@@ -42,6 +42,7 @@ CREATE TABLE `tabDocField` ( | |||||
`ignore_user_permissions` int(1) NOT NULL DEFAULT 0, | `ignore_user_permissions` int(1) NOT NULL DEFAULT 0, | ||||
`width` varchar(255) DEFAULT NULL, | `width` varchar(255) DEFAULT NULL, | ||||
`print_width` varchar(255) DEFAULT NULL, | `print_width` varchar(255) DEFAULT NULL, | ||||
`columns` int(11) NOT NULL DEFAULT 0, | |||||
`default` text, | `default` text, | ||||
`description` text, | `description` text, | ||||
`in_filter` int(1) NOT NULL DEFAULT 0, | `in_filter` int(1) NOT NULL DEFAULT 0, | ||||
@@ -338,27 +338,24 @@ frappe.ui.form.Grid = Class.extend({ | |||||
throw 'field not found: ' + _df.fieldname; | throw 'field not found: ' + _df.fieldname; | ||||
} | } | ||||
// map columns | |||||
if(_df.columns) { | |||||
df.colsize = _df.columns; | |||||
} | |||||
if(!df.hidden | if(!df.hidden | ||||
&& (this.editable_fields || df.in_list_view) | && (this.editable_fields || df.in_list_view) | ||||
&& this.frm.get_perm(df.permlevel, "read") | && this.frm.get_perm(df.permlevel, "read") | ||||
&& !in_list(frappe.model.layout_fields, df.fieldtype)) { | && !in_list(frappe.model.layout_fields, df.fieldtype)) { | ||||
if(!df.colsize) { | |||||
var colsize = 2; | |||||
switch(df.fieldtype) { | |||||
case "Text": | |||||
case "Small Text": | |||||
colsize = 3; | |||||
if(df.columns) { | |||||
df.colsize=df.columns; | |||||
} | |||||
else { | |||||
var colsize=2; | |||||
switch(df.fieldtype){ | |||||
case"Text": | |||||
case"Small Text": | |||||
colsize=3; | |||||
break; | break; | ||||
case "Check": | |||||
colsize = 1; | |||||
break; | |||||
} | |||||
df.colsize = colsize; | |||||
case"Check": | |||||
colsize=1 | |||||
} | |||||
df.colsize=colsize | |||||
} | } | ||||
total_colsize += df.colsize | total_colsize += df.colsize | ||||