Try our conversational search powered by Generative AI!

Programically set available pages

Vote:
 

Hello,
I'd like to ask if it's possible to somehow dybnamically set available pages.
I have container page which is used for multiple pages and under it, i can have pagetypes, but they are dependant on the parent. To iliustrate:
PageType1 -> ContainerPage ->ChildPage1

PageType2 -> ContainerPage ->ChildPage2

I'd like to be able to allow only ChildPage1 on first container page and allow only ChildPage2 on second container page.
Using attributes I can only set both. I can obviuosly create diferent container page types, but i don't think that it's a good solution.

Is it possible to somehow control availability in code?

Regards,
Giedrius

#90040
Sep 01, 2014 13:20
Vote:
 

I think that would be hard.

Basically the list of allowed page types is transfered from the server to a dojo store used by the javascripts in the browser to calculate what is available when you create new content.

#90281
Sep 04, 2014 18:24
Vote:
 

I think your suggestion to have a specific container page type is probably the easiest way to achive this.

There is another option and that is too hook events on DataFactory to check if it is allowed to create content at that location. This will interrupt the creation but I think the support to get the Cancel Reason displayed in the user interface might be lacking.

#90282
Sep 04, 2014 18:27
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.