Groups Specific Roles
Written Steps
In this video we will allow a group to have roles that are different from all other groups on the site.
Enable Custom Roles and Permissions
To do this we will add the "Group roles and permissions" field to the "Group" bundle.
- Go to Configuration > Organic Groups field settings
- Bundle: Group
- Fields: Group roles and permissions
- (Add Field)
Now, when we create a group (or indeed edit a group), we can choose to override the default Organic Groups roles and permissions.
- Add Content > Group
- Title: Group #3
- Body: (Lorem Ipsum)
- Group visibility: Public
- Group roles and permissions: Override default roles and permissions
- Provide a menu link
Note: Groups that were created before you add this field will continue to work as they did before. As soon as you edit a group however, you will be required to select either "Use default roles and permissions" or "Override default roles and permissions."
I'm going to go ahead and override the roles and permissions for Group #2.
Now when we click on the "Group" tab, we see that the "(read only)" text is no longer next to "Roles" or "Permissions". When I click "Roles" I have the option to add a role to this group. No other group will have roles that I add here. I'm going to add the role "Page Manager".
If we go to Group #1 and look at the roles, we see that there is no "Page Manager" for Group #1.
Adding a new role doesn't do us much good on it's own. So in the next video we will give some new permissions to the role: "Page Manager".




Add comment