Workaround for failing entity tree children #15887
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Prerequisites
Description
The refactor in #15856 has had the side effect of breaking entity trees that can hold multiple entity types. More to the point, the trees currently affected are the ones that have containers (folders) - like the document type and data type trees.
This PR introduces what can best be described as a workaround. Fortunately we already have a follow-up task planned that will make it possible to paginate multiple entity types in entity trees (among other reasons to ensure correct pagination for these "folder trees").
Testing this PR
It should be possible to see direct children of folders in entity trees:
Slightly more complex child structures should also work. Specifically for document types, these can be created beneath one another (inheritance), while the topmost ones still can reside in a folder:
It should be possible view documents that are moved to the recycle bin:
Apparently, the backoffice UI currently does not support creating inherited document types, so this will have to be done using Swagger. The following payload should do the trick:
Same goes for moving documents to the recycle bin - this is not yet a feature in the backoffice UI, so that has to be done using Swagger as well.