Browse Source

MST and publish mapping

version2
venkata akhil 12 months ago
parent
commit
10c436323a
  1. 35
      smart_service/phase_2/doctype/module_publish_mapping/module_publish_mapping.json
  2. 5
      smart_service/phase_2/doctype/special_tool_information/special_tool_information.js
  3. 3
      smart_service/phase_2/doctype/special_tool_information/special_tool_information.json

35
smart_service/phase_2/doctype/module_publish_mapping/module_publish_mapping.json

@ -51,78 +51,67 @@
"default": "0", "default": "0",
"fieldname": "automotive_system", "fieldname": "automotive_system",
"fieldtype": "Check", "fieldtype": "Check",
"label": "Automotive System", "label": "Automotive System"
"read_only": 1
}, },
{ {
"default": "0", "default": "0",
"fieldname": "tsb", "fieldname": "tsb",
"fieldtype": "Check", "fieldtype": "Check",
"label": "TSB", "label": "TSB"
"read_only": 1
}, },
{ {
"default": "0", "default": "0",
"fieldname": "fsa", "fieldname": "fsa",
"fieldtype": "Check", "fieldtype": "Check",
"label": "FSA", "label": "FSA"
"read_only": 1
}, },
{ {
"default": "0", "default": "0",
"fieldname": "tekalert", "fieldname": "tekalert",
"fieldtype": "Check", "fieldtype": "Check",
"label": "TEKalert", "label": "TEKalert"
"read_only": 1
}, },
{ {
"default": "0", "default": "0",
"fieldname": "feature_finder", "fieldname": "feature_finder",
"fieldtype": "Check", "fieldtype": "Check",
"label": "Feature Finder", "label": "Feature Finder"
"read_only": 1
}, },
{ {
"default": "0", "default": "0",
"fieldname": "repairservice_check_sheet", "fieldname": "repairservice_check_sheet",
"fieldtype": "Check", "fieldtype": "Check",
"label": "Repair/Service Check Sheet", "label": "Repair/Service Check Sheet"
"read_only": 1
}, },
{ {
"default": "0", "default": "0",
"fieldname": "mahindra_special_tool_information", "fieldname": "mahindra_special_tool_information",
"fieldtype": "Check", "fieldtype": "Check",
"label": "Mahindra Special Tool Information", "label": "Mahindra Special Tool Information"
"read_only": 1
}, },
{ {
"default": "0", "default": "0",
"fieldname": "training_information", "fieldname": "training_information",
"fieldtype": "Check", "fieldtype": "Check",
"label": "Training Information", "label": "Training Information"
"read_only": 1
}, },
{ {
"default": "0", "default": "0",
"fieldname": "qwik_service", "fieldname": "qwik_service",
"fieldtype": "Check", "fieldtype": "Check",
"label": "QWIK Service", "label": "QWIK Service"
"read_only": 1
}, },
{ {
"default": "0", "default": "0",
"fieldname": "pdi_inspection", "fieldname": "pdi_inspection",
"fieldtype": "Check", "fieldtype": "Check",
"label": "PDI Inspection", "label": "PDI Inspection"
"read_only": 1
}, },
{ {
"default": "0", "default": "0",
"fieldname": "torque_information_nm", "fieldname": "torque_information_nm",
"fieldtype": "Check", "fieldtype": "Check",
"label": "Torque Information NM", "label": "Torque Information NM"
"read_only": 1
}, },
{ {
"fieldname": "publish_type", "fieldname": "publish_type",
@ -156,7 +145,7 @@
], ],
"index_web_pages_for_search": 1, "index_web_pages_for_search": 1,
"links": [], "links": [],
"modified": "2023-10-06 12:18:41.170342", "modified": "2023-10-06 18:04:11.661649",
"modified_by": "Administrator", "modified_by": "Administrator",
"module": "Phase-2", "module": "Phase-2",
"name": "Module Publish Mapping", "name": "Module Publish Mapping",

5
smart_service/phase_2/doctype/special_tool_information/special_tool_information.js

@ -272,10 +272,8 @@ frappe.ui.form.on('Instructions', {
refresh_field("instructions"); refresh_field("instructions");
}, },
content_type: function (frm, cdt, cdn) { content_type: function (frm, cdt, cdn) {
// refresh_field("instructions")
var select_value = locals[cdt][cdn]; var select_value = locals[cdt][cdn];
var x = select_value.idx - 1; var x = select_value.idx - 1;
// let my_row = frm.fields_dict.content.grid.grid_rows[x];
if (select_value.content_type == 'Image' || select_value.content_type == 'Video' || select_value.content_type == 'PDF'){ if (select_value.content_type == 'Image' || select_value.content_type == 'Video' || select_value.content_type == 'PDF'){
cur_frm.get_field("instructions").grid.grid_rows[x].columns.content.df.read_only = 1; cur_frm.get_field("instructions").grid.grid_rows[x].columns.content.df.read_only = 1;
cur_frm.get_field("instructions").grid.grid_rows[x].columns.attach_file.df.read_only = 0; cur_frm.get_field("instructions").grid.grid_rows[x].columns.attach_file.df.read_only = 0;
@ -290,13 +288,14 @@ frappe.ui.form.on('Instructions', {
cur_frm.get_field("instructions").grid.grid_rows[x].columns.title.df.read_only = 0; cur_frm.get_field("instructions").grid.grid_rows[x].columns.title.df.read_only = 0;
cur_frm.refresh_fields("content_type") cur_frm.refresh_fields("content_type")
} }
frm.reload_doc()
cur_frm.refresh_fields("content_type") cur_frm.refresh_fields("content_type")
refresh_field("instructions"); refresh_field("instructions");
}, },
}) })
function check_field_character(field_name) { function check_field_character(field_name) {
if (field_name) { if (field_name) {
var alphanum = /^[a-zA-Z]+/; var alphanum = /^[0-9a-zA-Z_-]+/;
if (field_name.length > 1) { if (field_name.length > 1) {
if (field_name.length > 100) { if (field_name.length > 100) {
frappe.throw("<b>Tool Name:</b> Only <b> 100 </b> characters are allowed") frappe.throw("<b>Tool Name:</b> Only <b> 100 </b> characters are allowed")

3
smart_service/phase_2/doctype/special_tool_information/special_tool_information.json

@ -153,6 +153,7 @@
"fieldtype": "Column Break" "fieldtype": "Column Break"
}, },
{ {
"description": "Upload *.mp4 max 100 MB",
"fieldname": "video", "fieldname": "video",
"fieldtype": "Attach", "fieldtype": "Attach",
"label": "Video" "label": "Video"
@ -186,7 +187,7 @@
], ],
"index_web_pages_for_search": 1, "index_web_pages_for_search": 1,
"links": [], "links": [],
"modified": "2023-10-06 12:05:44.002461", "modified": "2023-10-06 16:54:21.868057",
"modified_by": "Administrator", "modified_by": "Administrator",
"module": "Phase-2", "module": "Phase-2",
"name": "Special Tool Information", "name": "Special Tool Information",

Loading…
Cancel
Save