November Happy Hour will be moved to Thursday December 5th.
AI OnAI Off
November Happy Hour will be moved to Thursday December 5th.
Basically, the form elements widget will list all element which are inherited from ElementBlockBase. For custom its behavour, you could override the ContentTypeService.js in FormsUI module, for insert/remove element types you want to display.
Could you please "pinpoint" me to where in ContentTypeService.js I would modify this?
Cant this be done by overriding anything on the .Net-side of EPiServer? I assume that ContentTypeService somehow communicates with the backend to get the valid ElementBlocks (or maybe just any block which is then filtered by the ContentTypeService), if this is the case.. then I guess I should be able to override whatever returns the result to ContentTypeService.js.. any ideas?
Hi!
I have created a new class that inherits from FormContainerBlock (lets call it MyCustomFormContainerBlock).. and so far everything works great, I can use it just fine with EPi Forms.
I also needed to create a few custom ElementBlocks, which I simply did by creating a new class and inherit from whichever current implementation of a default element that fit my needs the best.. for instance:
And I also created a controller with an action for the above Element:
Everything renders just fine, and it all works just fine with forms.. however.. I would like to be able to only show my custom elements for the MyCustomFormContainerBlock, and for the default FormContainerBlock I would like to exclude my custom elements..is this possible?
So far I have tried to override and use AllowedTypes for the ElementsArea-property of MyCustomFormContainerBlock, but if I specify my custom elements they dont show up in the UI for some reason (the contentarea doesnt allow the user to pick any elements)