Govintra uses WordPress’s standard roles: Administrator, Editor, Author, Contributor and Subscriber. The theme does not add roles of its own. Instead it adds a set of capabilities for every kind of content it registers, and hands them to the standard roles so that an editor can edit news, events, tasks and the rest just as they edit pages. If you need finer control, for example a role that can only publish news, you build it from those capabilities with a role management plugin.
What each standard role can do
- Subscriber: log in, read, comment, edit their own staff profile, and post to the wall.
- Contributor: everything a subscriber can, plus write drafts of every kind of content and pick existing terms for them. Contributors cannot publish, cannot upload files and cannot edit anything once it is published.
- Author: write, publish, edit and delete their own content of every kind, and upload files. Authors cannot touch other people’s content.
- Editor: write, publish, edit and delete anyone’s content of every kind, including private items, and manage the theme’s own lists (news types, event types, blog categories, course types, award categories, A to Z letters, grades and locations). Editors cannot manage task categories or tags, cannot edit the homepage, and cannot create intraverts or ultraverts.
- Administrator: everything, including the Options screens, the customiser, categories and tags, intraverts, ultraverts, other people’s profiles and the admin-only settings on them.
The capabilities for each module are granted whenever that module is switched on under Options, Modules, and are re-applied every time an admin page loads. That has a consequence: removing one of the theme’s capabilities from Editor, Author or Contributor does not stick. To take something away from editors, create a new role instead and move those people to it.
Capabilities for each kind of content
Each kind of content has the same family of capabilities as WordPress posts, with its own name in place of “posts”. Tasks and guides use guides: edit_guides, edit_published_guides, edit_others_guides, publish_guides, delete_guides, delete_published_guides, delete_others_guides, read_private_guides, edit_private_guides and delete_private_guides. The other names are:
- News:
news_posts. News updates:news_updates. Blog posts:blog_posts. Events:event_posts. - Vacancies:
vacancy_posts. Projects:projects. Training:training_posts. Teams:teams. Team news:team_news_posts. Jargon buster:jargonbusters. - Wall entries:
wall_entries. Intraverts:intraverts. Ultraverts:ultraverts.
Contributors get the edit and delete capabilities for their own drafts; authors add publish and edit-published; editors and administrators get the whole family. Pages use WordPress’s own pages capabilities, unchanged.
Capabilities for the lists
Each of the theme’s lists has four capabilities: manage_, edit_, delete_ and assign_, followed by the list’s name: news-type, news-update-type, event-type, blog-category, course-type, award-category, a_to_z, grade and building_location (locations). Contributors and authors get assign_, so they can pick terms; editors and administrators get all four. Locations are the exception: editors have the capabilities but the Users, Locations menu item itself is administrators only.
Task categories and tags are WordPress’s built-in taxonomies and are managed by administrators only. That applies to every other role, including custom roles made with Members, unless the role has been given the manage_options capability, which makes it an administrator in all but name. Everyone else chooses from tick-lists of existing terms when editing, and cannot open the Categories or Tags screens or add a category from the editing screen. See Add terms to taxonomies.
Things only administrators can do
- Edit the homepage. The page chosen as the static homepage under Settings, Reading cannot be edited or deleted by anyone else, whatever their role.
- Create and edit intraverts and ultraverts. The theme deliberately removes those capabilities from Editor. Give a custom role the
intravertsorultravertscapabilities if a communications team needs them. See Intravert guide and Ultraverts guide. - Edit, moderate and delete wall entries. Everyone can post to the wall; only administrators can change or remove what others posted.
- Edit other people’s profiles, and use the Admin settings on a profile (user tags, feature bio, sort order, hide from directory). Any role with WordPress’s
edit_userscapability can edit other people’s profiles on the intranet. - Use the Options screens and the customiser, manage categories and tags, and see the ACF menu.
Create a custom role
WordPress has no screen for roles, so install a role management plugin. We recommend Members. Under Members, Add New Role, give the role a name and tick the capabilities it needs; the Govintra capabilities appear under their own headings alongside the WordPress ones. Two patterns cover most needs:
- News editor:
read,upload_files, the wholenews_postsfamily andassign_news-type. Addedit_news_updatesandpublish_news_updatesif they write news updates too. - Page editor:
read,upload_files, thepagesfamily and theguidesfamily, so they can maintain pages and how-to guides but not news or events.
Start from a copy of Editor and remove what the role should not have, or from nothing and add. Test with a user in the new role before rolling it out: the admin menu only shows the content types the role can edit. One thing to check after installing Members: if the bbPress forum menus disappear from the admin, that is a known clash between Members and bbPress’s own roles, not the theme.
