I have created a room template that contains two pages, one for the end user content and other for the content manager. The only difference between them is the layout sets of the iViews, which have Editing functions for the content manager and on the other page, the other layout sets hide these functions. It works, but my question is:
Is there a way to switch between layout sets on the same page without having to duplicate it and change the iView parameters? I mean, according to the room role of the visitant, can i change the layout set at runtime?
Something like a room extension called ON_ENTER_ROOM that runs in the event of entering the room.
Thanks in advance!
> Something like a room extension called ON_ENTER_ROOM
> that runs in the event of entering the room.
No, that does not exist nor it would help you with your issue, for: What would you want to switch in this moment? You couldn't switch the LayoutSet of the iView in question, because if one second later the next one enters the room (with a different role) the property would be switched back.
But: What you want to achieve can be achieved by something we call "proxy iView". It just examins who calls the iView and then forwards the request to km.cm.navigation with the parameters as request parameters. With this, you can dynamically switch between LayoutSets depending on the user.
Search for "Detlev proxy iView" on SDN to gather more details.
Hope it helps