How to proceed with JSON Forms UI Schemas and the Model Server #158
-
The model server has a REST operation to retrieve UI schemas for the Tree Editor/JSON forms. However the REST method just allows us to retrieve one UI schema per request. On the other side, my model consists of dozens of classes which are likely to have a UI schema. In the Coffee Editor example, the UI schemas are part of the Tree Editor code (hardcoded). What would it be the right way to retrieve the schemas?
Many thanks in advance. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hi @agonzalezgaliana , this is a good question. Best |
Beta Was this translation helpful? Give feedback.
Hi @agonzalezgaliana ,
this is a good question.
So the current take is:
If you have 'static' forms that won't change in a very fast fashion, the recommendation is to 'hardcode' them as it is done by the Coffee Editor.
If you need to support highly dynamic forms which can change on each request or depend on external data which is only available on the backend, eg the logged in user, then a server should serve them.
The current take of the modelserver team is, that the current endpoint to retrieve a uischema might not be a good fit to the modelserver and should rather be server by a customization. So either extend the ModelServer and add the necessary endpoints to you custom server or start…