Remove table and form option from employee custom fields

This commit is contained in:
gamonoid
2017-11-26 20:56:12 +01:00
parent 1ddf6ffbb6
commit 4a07ca07e8

View File

@@ -8,7 +8,7 @@
*/ */
function FieldNameAdapter(endPoint,tab,filter,orderBy) { function FieldNameAdapter(endPoint,tab,filter,orderBy) {
this.initAdapter(endPoint,tab,filter,orderBy); this.initAdapter(endPoint,tab,filter,orderBy);
} }
FieldNameAdapter.inherits(AdapterBase); FieldNameAdapter.inherits(AdapterBase);
@@ -17,32 +17,32 @@ FieldNameAdapter.inherits(AdapterBase);
FieldNameAdapter.method('getDataMapping', function() { FieldNameAdapter.method('getDataMapping', function() {
return [ return [
"id", "id",
"name", "name",
"textOrig", "textOrig",
"textMapped", "textMapped",
"display" "display"
]; ];
}); });
FieldNameAdapter.method('getHeaders', function() { FieldNameAdapter.method('getHeaders', function() {
return [ return [
{ "sTitle": "ID" ,"bVisible":false}, { "sTitle": "ID" ,"bVisible":false},
{ "sTitle": "Name" }, { "sTitle": "Name" },
{ "sTitle": "Original Text"}, { "sTitle": "Original Text"},
{ "sTitle": "Mapped Text"}, { "sTitle": "Mapped Text"},
{ "sTitle": "Display Status"} { "sTitle": "Display Status"}
]; ];
}); });
FieldNameAdapter.method('getFormFields', function() { FieldNameAdapter.method('getFormFields', function() {
return [ return [
[ "id", {"label":"ID","type":"hidden"}], [ "id", {"label":"ID","type":"hidden"}],
[ "type", {"label":"Type","type":"placeholder","validation":""}], [ "type", {"label":"Type","type":"placeholder","validation":""}],
[ "name", {"label":"Name","type":"placeholder","validation":""}], [ "name", {"label":"Name","type":"placeholder","validation":""}],
[ "textOrig", {"label":"Original Text","type":"placeholder","validation":""}], [ "textOrig", {"label":"Original Text","type":"placeholder","validation":""}],
[ "textMapped", {"label":"Mapped Text","type":"text","validation":""}], [ "textMapped", {"label":"Mapped Text","type":"text","validation":""}],
[ "display", {"label":"Display Status","type":"select","source":[["Form","Form"],["Table and Form","Table and Form"],["Hidden","Hidden"]]}] [ "display", {"label":"Display Status","type":"select","source":[["Form","Show"],["Hidden","Hidden"]]}]
]; ];
}); });
@@ -51,7 +51,7 @@ FieldNameAdapter.method('getFormFields', function() {
*/ */
function CustomFieldAdapter(endPoint,tab,filter,orderBy) { function CustomFieldAdapter(endPoint,tab,filter,orderBy) {
this.initAdapter(endPoint,tab,filter,orderBy); this.initAdapter(endPoint,tab,filter,orderBy);
this.tableType = ""; this.tableType = "";
} }
@@ -61,41 +61,41 @@ CustomFieldAdapter.inherits(AdapterBase);
CustomFieldAdapter.method('getDataMapping', function() { CustomFieldAdapter.method('getDataMapping', function() {
return [ return [
"id", "id",
"name", "name",
"display", "display",
"display_order" "display_order"
]; ];
}); });
CustomFieldAdapter.method('getHeaders', function() { CustomFieldAdapter.method('getHeaders', function() {
return [ return [
{ "sTitle": "ID" ,"bVisible":false}, { "sTitle": "ID" ,"bVisible":false},
{ "sTitle": "Name" }, { "sTitle": "Name" },
{ "sTitle": "Display Status"}, { "sTitle": "Display Status"},
{ "sTitle": "Priority"} { "sTitle": "Priority"}
]; ];
}); });
CustomFieldAdapter.method('getFormFields', function() { CustomFieldAdapter.method('getFormFields', function() {
return [ return [
[ "id", {"label":"ID","type":"hidden"}], [ "id", {"label":"ID","type":"hidden"}],
//[ "type", {"label":"Type","type":"placeholder","validation":""}], //[ "type", {"label":"Type","type":"placeholder","validation":""}],
[ "name", {"label":"Name","type":"text","validation":""}], [ "name", {"label":"Name","type":"text","validation":""}],
[ "display", {"label":"Display Status","type":"select","source":[["Form","Show"],["Hidden","Hidden"]]}], [ "display", {"label":"Display Status","type":"select","source":[["Form","Show"],["Hidden","Hidden"]]}],
[ "field_type", {"label":"Field Type","type":"select","source":[["text","Text Field"],["textarea","Text Area"],["select","Select"],["select2","Select2"],["select2multi","Multi Select"],["fileupload","File Upload"],["date","Date"],["datetime","Date Time"],["time","Time"]]}], [ "field_type", {"label":"Field Type","type":"select","source":[["text","Text Field"],["textarea","Text Area"],["select","Select"],["select2","Select2"],["select2multi","Multi Select"],["fileupload","File Upload"],["date","Date"],["datetime","Date Time"],["time","Time"]]}],
[ "field_label", {"label":"Field Label","type":"text","validation":""}], [ "field_label", {"label":"Field Label","type":"text","validation":""}],
[ "field_validation", {"label":"Validation","type":"select","validation":"none","sort":"none","source":[["","Required"],["none","None"],["number","Number"],["numberOrEmpty","Number or Empty"],["float","Decimal"],["email","Email"],["emailOrEmpty","Email or Empty"]]}], [ "field_validation", {"label":"Validation","type":"select","validation":"none","sort":"none","source":[["","Required"],["none","None"],["number","Number"],["numberOrEmpty","Number or Empty"],["float","Decimal"],["email","Email"],["emailOrEmpty","Email or Empty"]]}],
[ "field_options", {"label":"Field Options","type":"datagroup", [ "field_options", {"label":"Field Options","type":"datagroup",
"form":[ "form":[
[ "label", {"label":"Label","type":"text","validation":""}], [ "label", {"label":"Label","type":"text","validation":""}],
[ "value", {"label":"Value","type":"text","validation":"none"}] [ "value", {"label":"Value","type":"text","validation":"none"}]
], ],
"html":'<div id="#_id_#" class="panel panel-default"><div class="panel-body">#_delete_##_edit_#<span style="color:#999;font-size:13px;font-weight:bold">#_label_#</span>:#_value_#</div></div>', "html":'<div id="#_id_#" class="panel panel-default"><div class="panel-body">#_delete_##_edit_#<span style="color:#999;font-size:13px;font-weight:bold">#_label_#</span>:#_value_#</div></div>',
"validation":"none" "validation":"none"
}], }],
[ "display_order", {"label":"Priority","type":"text","validation":"number"}], [ "display_order", {"label":"Priority","type":"text","validation":"number"}],
[ "display_section", {"label":"Display Section","type":"text","validation":""}] [ "display_section", {"label":"Display Section","type":"text","validation":""}]
]; ];
}); });