I'm building a community website with Drupal Commons and I need to be able to create 3 kinds of groups:

  • public groups : anyone can view content, group members only can post/edit/delete content
  • private groups : group members only can view/post/edit/delete content
  • semi-private groups : authenticated users can view content, group members only can post/edit/delete content

How can I achieve this?

  • create a role of every group type and assign permission
    – Adi
    Nov 17 '15 at 12:36
  • Thanks Adi. But I'm not sure to understand your proposition: you mean that I could assign a group-type-based role to each user? Maybe I should mention that a user can belong to several groups, whatever their type.
    – jmague
    Nov 17 '15 at 13:28

The Group module allows for creating arbitrary collections of your content and users on your site, and grant access control permissions on those collections. It is available as of D7, and has a D8 version also. It is designed to be an alternative to Organic Groups. The Group module creates groups as entities, making them fully fieldable, extensible and exportable.

For this specific question, you'd enable the gnode submodule, and for each group type you would define the appropriate permissions (view, edit, delete, etc) for the various Content Types. That's it.

For more details about the various types of roles used by the Group module, refer to my answer to "What are the various roles supported by the Group module?".


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.