How to hide a portlet (Site Setup) based on roles?

4 messages Options
Embed this post
Permalink
Lars Löwenadler () How to hide a portlet (Site Setup) based on roles?
Reply Threaded More More options
Print post
Permalink
Hi, Plone 3.3 user here, building a site for users with the Plone "member" role only.

As a member clicks Preferences on the personal bar, the member sees the Site Setup portlet on the left - though only the heading, not the content. When clicking the heading the member expectedly gets the message "Insufficient Privileges".

Now, I'd like to completely hide this portlet for everyone (except managers like me), but I can't find the proper code nor the proper place/template to do it. I have 'googled' for a while now. My attempts include adding a condition to the page template "plone_control_panel" (but I can't get it right), among other random actions based on hints from the Internet.

Any suggestions would be much appreciated!

Thanks,
Lars
vedaw () Re: How to hide a portlet (Site Setup) based on roles?
Reply Threaded More More options
Print post
Permalink
Hm, I just added a testuser to a vanilla Plone site and clicked on the
user's name to access their preferences, and I do not see a Site Setup
portlet. It just takes me to a dashboard area with no right or left
columns....

My thought is that you probably have to modify something in the
plone.app.controlpanel egg (control-panel.pt), but I'm not sure. This might
be a question better asked on the plone-users list.

Cheers,

- Veda


On 9/8/09 1:02 AM, "Lars Löwenadler" <[hidden email]>
wrote:

>
> Hi, Plone 3.3 user here, building a site for users with the Plone "member"
> role only.
>
> As a member clicks Preferences on the personal bar, the member sees the Site
> Setup portlet on the left - though only the heading, not the content. When
> clicking the heading the member expectedly gets the message "Insufficient
> Privileges".
>
> Now, I'd like to completely hide this portlet for everyone (except managers
> like me), but I can't find the proper code nor the proper place/template to
> do it. I have 'googled' for a while now. My attempts include adding a
> condition to the page template "plone_control_panel" (but I can't get it
> right), among other random actions based on hints from the Internet.
>
> Any suggestions would be much appreciated!
>
> Thanks,
> Lars


_______________________________________________
UI mailing list
[hidden email]
http://lists.plone.org/mailman/listinfo/ui
Lars Löwenadler () Re: How to hide a portlet (Site Setup) based on roles?
Reply Threaded More More options
Print post
Permalink
Thanks for the reply. Please make sure you click Preferences (your-plone-site/plone_memberprefs_panel in the browser address field) though, not the user's name (that one takes you to your-plone-site/author/testuser). Clicking Preferences renders the empty portlet for my testuser, while clicking the user's name renders an empty area with a default silhouette picture of the user.

As for modifying the control panel, I deleted my unsuccessful changes to the default one, so I'm afraid that's not the key either.

Sorry if this is a silly question but which list is the Plone-users list? I'm still confused by these forums and lists. Is Plone-users list simply a mailing list, not a forum board here?

Thanks,
Lars

vedaw wrote:
Hm, I just added a testuser to a vanilla Plone site and clicked on the
user's name to access their preferences, and I do not see a Site Setup
portlet. It just takes me to a dashboard area with no right or left
columns....

My thought is that you probably have to modify something in the
plone.app.controlpanel egg (control-panel.pt), but I'm not sure. This might
be a question better asked on the plone-users list.

Cheers,

- Veda
Karl Johan Kleist () Re: How to hide a portlet (Site Setup) based on roles?
Reply Threaded More More options
Print post
Permalink
Not silly at all, since for some reason the "plone-users" mailing list is called "General Questions" here in the nabble forums: http://plone.org/support/forums/general

Lars Löwenadler wrote:
Sorry if this is a silly question but which list is the Plone-users list? I'm still confused by these forums and lists. Is Plone-users list simply a mailing list, not a forum board here?