Show child resources in Menu Tree but not Parent(s) using Resource Groups

Hi,

I have a bunch of microsites that I want visible/editable to the different resource groups in the Manager. For SEO purposes, they all exist under a single parent. I want to show the child resources to the different logged in Groups, but not the “container” parent, however, if I restrict the access of the parent to Admin Only resource group, I can’t see the child pages when logged in.

In tree terms:

Website
-Parent (/venues)
–Child 1 (/venues/venue-1)
—Child 1 pages
—Child 1 pages
—Child 1 pages
–Child 2 (/venues/venue-2)
—Child 2 pages
—Child 2 pages
—Child 2 pages
–Child 3 (/venues/venue-3)
–Child 4 (/venues/venue-4)
etc.

Is there anyway I can keep the Child pages visible/accessible in the Menu tree without that Resource Group having access to the Parent page?

The solutions I’ve though of:

  • Move the Child Pages up one level, and amend the URL path by manually adding /venues/ to the individual aliases on every child page. Not ideal, as building Navs/Menus will need tweaking manually.

However, I have come across this scenario on other websites and potentially will have the same on this one, so I was wondering if there is a “correct” way of doing it, that allows you to set folders/containers/parents as see-through, and just show the pages you have access to?

I hope my explanation makes sense!

Thanks,
Quentin

It’s been a while since I’ve looked at that, but IIRC, if you give them load permission for the parent but not list or view permission, the children may show up and the parent will be hidden. Be sure to clear the cache after making any changes.

Another possibility is to give permission for the parent, but change the show_in_tree field of the parent to 0 in the DB.

Maybe set the system setting tree_root_id as global or in usergroup to the parent id? :thinking: The subresources can be hidden via resourcegeoups.

That worked! Thanks @jenswittmann. I knew there would be a proper way of doing it.

Also great to realise that the super granular nature of ModX ACL allows you to create settings for the individual User Groups.

1 Like

Thanks for the suggestions @bobray. I went with Jens solution as I wanted to show the parent in tree for Admin users, so setting to 0 in DB would prevent that.

The load not list / view permissions sounded like an extra Resource Group and tweaking, which would probably work, but I didn’t want to go down that rabbit hole!

This topic was automatically closed 2 days after discussion ended and a solution was marked. New replies are no longer allowed. You can open a new topic by clicking the link icon below the original post or solution and selecting “+ New Topic”.