I want to set my menu according to organic group roles.
So there is any option or module which set menus per organic group role as menu per role work for global roles.

CommentFileSizeAuthor
#5 Screen Shot 04.PNG20.4 KBmorybel
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

morybel’s picture

Issue summary: View changes

A bit late but..
I need that function as well.

I have 5 roles on each organic groups and I need to show "user guides" as well as other instructions on different sections of my secure websites only to administrator and Manager of the groups, not to regular members. I was hoping more for a block setup than a menu but maybe I should open a new tread.

Thanks for any suggestions.

sophiejones’s picture

Hi.
I was reading issues in hopes of finding what i need and saw your issue. I am not 100% sure but I think you might be able to achieve this with og_tabs and a specific content type to use for this sort of thing and under permissions for the group you can set who can or cannot see this particular content type and by extension its tab.
But as I said I have not used it in this fashion but I think it is doable, for your use-case since it is very specific to two roles. .

morybel’s picture

Assigned: » Unassigned
Priority: Major » Normal

I'm still trying to figure this out, having put this project on hold for some time.

sophiejones, it is a good suggestion, but I really need to hide a menu item (or block), not tabs in nodes.

I have a main menu with subitems that are views. These views have OG permissions and those who doesn't have specific OG rules still sees the Views but as empty. It looks weird, I would rather have them not knowing there is something on that menu item.

I can't find anything related to show/hide menu items to OG roles.

Any help would be appreciated.
Thanks

sophiejones’s picture

Hello
I don't know your set up but sometimes you can actually manage this through site role. For example if only specific site role are eligible to become group administrator/manager then you can easily make this view only accessible to that role by using the module menu_visibility.
but if each group has its own specific view, then you are talking about og_context, in that case that only works when your views are in group pages. in such a case you can use og permission and define it to people who can administer group or such permission that is only for administrator/group manager.
-another way is to make your entire site one giant group. that other groups will be its subgroup using audience field. (you don't need og_subgroups module for this) then in this giant group create a role and assign this role to all the managers of your other groups, these are people who have permission to create this subgroup content type.
then you can use this permission in your views to define access.
I have found the only way to use og_roles as a mean to define access to a view is by making one thing unique to that role in group and then use the permission of this unique thing like creation of subgroup that no one else can do to set permission for your view.
-Another thing you need to consider is that views access will never help you to make the menu link to this view invisible or visible. they will get access denied but they can still see the link.
-Your best bet is to create a site role that you can assign to those users who will be eligible to become group administrators/manager. this way you can use menu_visibility and make the link visible to them and no one else.
I hope this helps.

morybel’s picture

FileSize
20.4 KB

Thanks you've given me food for thought..

I only have one role on my site: firefighters. But within firefighters I have organic group roles: "Administrator", "Mechanics", "Training officers" etc..

My "Administrators" have full rights all over the views, but my "Mechanics" should only see the "mecanical" views of the site. Althought they don't see the contents of the views, they can still access the views because the menu elements is not hidden from them. It's an empty view. We don't see the data but we can see how much data there is, really weird. (see picture)

emtpy view

I would rather have something like: "You are not allowed to access this report" or hide it all so they can't see this.

Thanks.

.