Hello,
On a service page (parent), I show a list of sub-services (children).
I apply this structure on any number of levels.
Therefore, I have a section that shows children of current service.
– This CPT has a “parent-service” field self-referencing that CPT
– The list of a children is selected using a filter referencing that field
How can I hide the whole section if my list of children is empty?
I could have a list of all children in a field, but since I reference the same CPT, if I use same custom key for relations it populates both. And I don’t want to maintain the children field if a parent is enough.
Thank you very much
Joachim
©2025 Created with 27collective LLC. All rights reserved