Hi, My entity has an attribute “content” which is actuall HTML so I would like to use the SourceCodeEditor component in the FieldGroup instead of the TextField. I tried the following code in the init method:
SourceCodeEditor sourceCodeEditor = componentsFactory.createComponent(SourceCodeEditor.class) fieldGroup.getFieldNN("content").setComponent(sourceCodeEditor)
But I get
IllegalStateException: Unable to change component for bound FieldConfig
I set the field custom property to true:
<field property="content" custom="true">
The editor then comes up with the SourceCodeEditor component but it does not show the content value. I guess this should be expected since the documentation says the custom true attribute means the field identifier does not refer to an entity attribute.
Is this expected behavior? If so, then how do I accomplish this? Is it something like overriding the postInit and getItem methods in the AbstractEditor? Thanks.