[BUGFIX] Missing rendered children in preview workspace #2225
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.
As described in Issue #2158 children are not rendered when previewing changes made in the preview workspace:
I have encountered the same problem.
The Problem is that when rendering the content records of a workspace element, that they are identified by their colPos, which are based on the uid of the LIVE-element.
As example, we have these Elements:
ColumnNumberUtility::calculateColumnNumberForParentAndColumn
function.With this set, we render the preview element:
We see that the "placeholder" (the preview element) is used instead the original:
Rendering the preview results in the child elements being searched by colPos 4301, 4302, 4303, ... (Again, because of
ColumnNumberUtility::calculateColumnNumberForParentAndColumn
).The Problem here is that we want to render also the live elements, which have the colPos 4201, 4201, ...
So no children are rendered.
So as a solution, i kept that information about the original record and used it then to also check for rows in this live record.