Skip to content
Snippets Groups Projects
Commit 8cddb29f authored by S.Listl's avatar S.Listl Committed by Sebastian Listl
Browse files

Attribute DropDownDefinition fix

(cherry picked from commit 3e5544d3)
parent bfd6cd27
No related branches found
No related tags found
No related merge requests found
......@@ -37,7 +37,6 @@
<stateProcess>%aditoprj%/entity/Attribute_entity/entityfields/attribute_type/stateProcess.js</stateProcess>
<valueProcess>%aditoprj%/entity/Attribute_entity/entityfields/attribute_type/valueProcess.js</valueProcess>
<displayValueProcess>%aditoprj%/entity/Attribute_entity/entityfields/attribute_type/displayValueProcess.js</displayValueProcess>
<onValueChange>%aditoprj%/entity/Attribute_entity/entityfields/attribute_type/onValueChange.js</onValueChange>
</entityField>
<entityField>
<name>ATTRIBUTE_PARENT_ID</name>
......@@ -186,6 +185,7 @@
<dropDownProcess>%aditoprj%/entity/Attribute_entity/entityfields/dropdowndefinition/dropDownProcess.js</dropDownProcess>
<stateProcess>%aditoprj%/entity/Attribute_entity/entityfields/dropdowndefinition/stateProcess.js</stateProcess>
<titleProcess>%aditoprj%/entity/Attribute_entity/entityfields/dropdowndefinition/titleProcess.js</titleProcess>
<valueProcess>%aditoprj%/entity/Attribute_entity/entityfields/dropdowndefinition/valueProcess.js</valueProcess>
</entityField>
<entityParameter>
<name>AttrParentType_param</name>
......
import("system.neon");
import("system.vars");
import("Attribute_lib");
import("Entity_lib");
var type = vars.get("local.value") || "";
if (type.trim() != $AttributeTypes.KEYWORD && vars.exists("$field.DROPDOWNDEFINITION") && vars.get("$field.DROPDOWNDEFINITION"))
neon.setFieldValue("$field.DROPDOWNDEFINITION", "");
\ No newline at end of file
......@@ -8,9 +8,7 @@ var type = vars.get("$field.ATTRIBUTE_TYPE").trim();
if (type && $AttributeTypes[type] && $AttributeTypes[type].getDropDownDefinitions
&& !AttributeUtil.hasRelations(vars.get("$field.UID")))
fieldState = neon.COMPONENTSTATE_EDITABLE;
else if (vars.get("$sys.recordstate") == neon.OPERATINGSTATE_VIEW)
fieldState = neon.COMPONENTSTATE_INVISIBLE;
else
fieldState = neon.COMPONENTSTATE_READONLY;
fieldState = neon.COMPONENTSTATE_INVISIBLE;
result.string(fieldState);
\ No newline at end of file
import("system.result");
import("system.vars");
import("Attribute_lib");
var type = vars.get("$field.ATTRIBUTE_TYPE").trim();
if (type && $AttributeTypes[type] && typeof($AttributeTypes[type].getDropDownDefinitions) !== "function")
result.string("");
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment