It would be nice to be able to additionally link og-group-access to user-roles and not only to single users/nodes.

Up to now there is only the option to make nodes public or belong to og-groups (if a node does not belong to either og-group automatically sets it to public).

I think tis reduces easy & less query & data intensive administration for groups that might have a huge number of members like:
Members, Customers, Developers, ...

Up to now every single member of a role that already exists as a drupal user-role needs to be linked again ("manually") within node_access table to the og-group nid to be able to view content of such an og-group. To me this seems to unnecessarily bloat the node_access table instead of using already existing user-roles for "inscribing" to og-groups. Might be possible to implement this through a new realm-type in node_access table?
How do you think about this?

Problem of course is that the direction Drupal is going concerning ACL/group administration/creation seems not really clear to make a severe code change like this.

Greetings
wernerbraun

Comments

moshe weitzman’s picture

i'm unlikely to implement this. roles and group memberships are *deliberately* not related in og. a helper module might be able to keep them in sync, if you want that.

Boris Mann’s picture

I think I just came up for a good use case/implementation for how to do this. Let me know if you think this is still helper-module type functionality.

In connecting groups to roles, it goes something like this:

1. Add group to existing role: all users with that role are subscribed to the new group
2. Add role to user: that user is automatically subscribed to all groups associated with that role

You might even have a role that is automatically subscribed to all new groups.

Yep, writing it down, it sounds like a helper module that depends on OG. I'll leave it here for future inspiration.

dwees’s picture

Component: Code » og.module

Did anyone make any progress on this? This is actually what I need for a site where I'm using OG to segment the site content easily for users.

Dave

MisterSpeed’s picture

We do need this as well on a client's site. Would Moshe be open to the idea of making that feature optional and configurable through the administrative side of the module ? if so we would happily assign a developer to that project.

AFowle’s picture

http://drupal.org/project/og_multiple_mandatory_groups_by_role does some of this. It is probably not quite what the original poster wanted, because it adds individual users to the group depending on their role, rather than just acting by role. It does work, but the interface could do with tidying up. When a notifications module update trashed my site (my fault) I used this module to delete all users from the group and reintroduce them, so that automatic notifications sorted things out.

It has not been updated in a while and perhaps would be a welcome recipient of 63reasons's multiple developers.

Grayside’s picture

Status: Active » Closed (won't fix)

This is outside the scope of OG's core use case, and as demonstrated above external modules can facilitate this.

Also, multiple years since last comment.