2

I have three types of user roles in my site:

  • department heads.
  • department managers.
  • employees.

There are several department heads. Each Department Head manages multiple department managers. And each Department manager manages multiple employees.

What I want is:

  • Department managers should be able to see details of THEIR employees.
  • Department heads should be able see THEIR managers and the employees working under each of these managers.

There are lots of techniques/solutions on roles and permissions. Such as those provided by specific contributed modules (including Organic groups). But I am confused which one to start with.

Anybody can shed some light about this?

1

Have a look at the Group module (a new module as of D7). It should address most (if not all) of your requirements. And it offers a potential alternative to the Organic groups module. Here is a quote from its project page:

Organic groups allows content itself to be groups, which isn't always what people want. It relies on an entity reference field to keep track of the ties between a group (node, term, ...) and its content (node, term, user, ...).

Group instead creates groups as entities, making them fully fieldable, extensible and exportable. Every group can have users, roles and permissions attached to it. Groups can also act as a parent of any type of entity. Seeing as a group itself is also an entity, creating subgroups is very easy.

Some major differences between these 2 modules are:

  • Group started in D7 only, taking full advantage of entities introduced in D7.
  • Organic Groups is commonly perceived as a huge module, which carries a lot of "legacy" from pre-D7 releases.
  • A D8 version of Group is in the pipeline and actively being worked on these days (expectation is "only a few months from now").

Additional Group sub-modules

Extra features can be enabled via these sub-modules:

  • Group Add: Add members to a group without their consent.
  • Subgroup: Make group to belong to another group.
  • Group Invite: Allow group members to invite people into their group.
  • Group Node: Enables Group functionality for the Node module.
  • Group member profiles: Create multiple fieldable member profiles, which can be attached to a member.

Have a look at my answer to "How to create basic Organic Groups functionality with flags and references?" for way more details about it, such as available integration with other (commonly used) modules.

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.