-
-
Notifications
You must be signed in to change notification settings - Fork 222
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
!!! TASK: Remove leftovers from magic underscore access for internal node properties #5015
!!! TASK: Remove leftovers from magic underscore access for internal node properties #5015
Conversation
one todo is: how to sort by creation date in Neos 9?? Something like node.timestamps.originalCreated in our weekly from the 26. we discussed that instead of adding a new flowquery or a magic parameter, we probably want to support the old legacy 8.3 syntax The question is if these modifiers should only work for the |
todos
|
it will be fully migrated via #5015 (comment)
I do not understand why you did this? |
That was what i have been discussing in #4208 or in the meetings i thought but it seems we have talked past each other? My thesis in short (now part of the main description): We have the
While these are the ones known from 8.3
The actual important and ones used in 8.3 like To avoid confusion about which magic underscore properties still exist in 9.0 a simple way is - it thought we agreed upon this in the meeting from the 19.01 link - to NOT have any underscore property logic and remove any magic from this syntax. Like one can use an underscore now in consumer land but it is never any more special than any other character. Thats why this pr remove partially implemented legacy support for There is a little but as discussed in on the 26.04 we concluded to still allow sorting nodes by date via the |
This is all clear, but
why, why didn't you just add the things missing to my original PR? |
Because i thought it would get too complex and the |
Too much going on LOL, seems still a bit weird but 🤷 |
it will be fully migrated via neos/neos-development-collection#5015 (comment)
As we don't support property('_hidden') there would be no way to figure out if a node is hidden.
…nd filter FlowQuery Fixes neos#4208 (comment)
ef940a0
to
5f8579c
Compare
was previously removed via neos#5036
…astPublicationDateTime support for `sort`
We should not need to load the node type for every fetch, only if we want to fetch references
The migration to use the herby introduced This pr is ready for final reviews. If i get feedback regarding "9.0 proposed getter and documentation" from above i can also add that documentation to the node. |
…-underscore-access-for-internal-node-properties
Neos.ContentRepository.NodeAccess/Classes/FlowQueryOperations/SortOperation.php
Outdated
Show resolved
Hide resolved
Neos.ContentRepository.NodeAccess/Classes/FlowQueryOperations/SortByTimeStampOperation.php
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good! Just a remark regarding the new sort operation
Neos.ContentRepository.NodeAccess/Classes/FlowQueryOperations/SortByTimestampOperation.php
Show resolved
Hide resolved
…-underscore-access-for-internal-node-properties
…-underscore-access-for-internal-node-properties
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lovely, thanks!
neos/neos-development-collection#5015 `nodePath` also doesnt accept absolute node paths anymore
We have the
_*
underscore access syntax to access actual php object fields of the Node. Due to the ESCR rewrite the Node object looks completely different and has way less getters / fields. See #4208 (comment) for a comparison.The only overlap of fields to the old node are those few:
_name
_nodeTypeName
(unknown as.nodeType
was always used)_properties
(useless asq(node).property(...)
is used)Keeping the underscore access would expose a lot of new node fields like
_contentRepositoryId
which has no gain over tonode.contentRepositoryId
.Adding a full runtime migration layer for fields of 8.3 like
_identifier
,_depth
,_nodeType
and_hiddenAfterDateTime
was decided against as there is a rector migration in place.So to avoid confusion about which magic underscore properties still exist in 9.0 - as rule of thumb - None, and the syntax will be removed from fusion. One can use an underscore now in consumer land but it is never any more special than any other character.
The sort operation previously also handled
_creationDateTime
,_lastModificationDateTime
and_lastPublicationDateTime
. For Neos 9.0 the newsortByTimestamp(created|lastModified|originalCreated|originalLastModified)
flowquery can be used.Related: #4921
Resolves: #4208