User Groups,
Access Levels
and Permissions
---
Joomla 5
- User Groups
- Access Levels
- Permissions
---
User Groups
----
### User Groups
- Collections of users ("Categories")
- Grouped together
- based on common characteristics
- or roles
----
### Joomla uses User Groups for
- User Account Management
- Viewing Access Levels
- Permissions (Access Control List)
- Workflow
----
### User Groups Benefits
- Flexibility: config groups to match requirements.
- Security: Restricts access based on roles.
- Scalability: Suitable for small and large sites.
- Ease of Management: Reduces managing individual user permissions.
----
### Joomla's default User Groups
- Public: Anyone
- Guest: Non-logged-in users
- Registered: Logged-in users without special permissions
- Author: only submit new articles. Not editing others' content
- Editor: Can edit any article. No publishing
- Publisher: Can publish or unpublish any article
- Manager: Can manage site content with limited backend access
- Administrator: Has higher-level administrative access but not full control
- Super Users: Full control over the site, including all administrative features
- Your Own: Create your own Groups for Viewing Levels and Permissions
---
(Viewing) Access Levels
----
### Viewing Access Levels (VAL)
- What can someone
- from a User Group
- see on a page
----
### Config Viewing Access Levels
Set "Access" via:
- Components
- "Access": in Menu Item for Component View
- Modules
- "Access" in Module Parameters
- Plugins
- "Access" in Plugin Parameters
----
### Store Viewing Access Levels
- Components
- #__categories: access
- #__content: access
- #__menu: access
- Modules
- Plugins
---
Permissions (Access Control List)
----
### ACL: Permissions (ACL)
- Access-Control List (ACL)
- What can someone
- from specific User Group
- do in a component
- Cascading: inherit from Parent User Group
----
### Config Permissions
Set "Permissions" via:
- Components
- "Options" > "Permissions"
- Modules
- No, only "viewing" access
- Plugins
- No, only "trigger" access
----
### Store Permissions
- Components
- Modules
- No, only "viewing" access
- Plugins
- No, only "trigger" access
----
### Permissions Assets Table
Permissions for com_content:
- #__assets table
- record: com_content
- column: rules (JSON: Action + User Group IDs)
```json
{
"core.admin":{"7":1},
"core.manage":{"6":1},
"core.create":{"3":1},
"core.edit":{"4":1},
"core.edit.state":{"5":1},
"core.execute.transition":{"6":1,"5":1}
}
```
----
### Who has Permissions (default)
Permissions for com_content:
- core.admin: Administrator (ID:7)
- core.manage: Manager (ID:6)
- core.create: Author (ID:3)
- core.edit: Editor (ID4)
- core.edit.state: Publisher (ID:5)
- core.execute.transition: Manager (ID:6) + Publisher(ID:5)
----
### How Permissions 1/2
File: /administrator/components/com_content/access.xml
```xml
```
----
### How Permissions 2/2
File: /administrator/components/com_content/src/ View/Articles/HtmlView.php
```php
protected function addToolbar() {
$canDo = ContentHelper::getActions('com_content',
'category', $this->state->get('filter.category_id'));
$user = $this->getCurrentUser();
$toolbar = $this->getDocument()->getToolbar();
ToolbarHelper::title(Text::_('COM_CONTENT_ARTICLES_TITLE'), 'copy article');
if ($canDo->get('core.create') ||
\count($user->getAuthorisedCategories('com_content',
'core.create')) > 0)
{
$toolbar->addNew('article.add');
}
```
---
Create your own
User Groups,
Viewing Access Levels,
Permissions
----
### Create!
- Let's create a User Group (UG) : Marketing Group
- With Viewing Access Level (VAL) : Marketing Level
- Set Permissions (ACL) to
- Login into the back-end
- Manage articles from category "News"
- Manage Redirects
---
Create your own User Groups
----
### UG: User Groups
----
### UG: New Marketing Group
► Users > Groups > New
----
### UG: New Marketing Group
- Group Title: Marketing Group
- Group Parent: Public
----
### UG: Marketing Group
New User Group:
Marketing Group
---
(Viewing) Access Levels
----
### VAL: New Marketing Level
► Users > Access Levels > New
----
### VAL: New Marketing Level
- Level Title: Marketing Level
- User Groups With Viewing Access: Marketing Group
----
### VAL: New Marketing Level
- Level Title: Marketing Level
- User Groups With Viewing Access: Marketing Group
---
Permissions (Access Control List)
----
### ACL: Permissions (ACL)
- Access-Control List (ACL)
- What can someone
- from specific User Group
- do in a component
----
### ACL: Back-end
- Login in Back-end
- Manage Content
- Manage Categories
- Manage Redirects
► System > Global Configuration > Permissions >
Marketing Group > Administrator Login: Allowed
----
### ACL: Content
- Login in Back-end
- Manage Content
- Manage Categories
- Manage Redirects
► Content > Articles > Options >
Permissions >
Marketing Group > Access Admin. Interface: Allowed
----
### ACL: Categories
- Login in Back-end
- Manage Content
- Manage Categories
- Manage Redirects
► Content > Categories > "News" > Permissions >
Marketing Group > all Actions: Allowed
----
### ACL: Redirects
- Login in Back-end
- Manage Content
- Manage Categories
- Manage Redirects
► System > Redirects > Permissions >
Marketing Group > Allow all Actions except "Configure"
---
Add New User
----
### Add New User
- Mark Ting
- Marketing Department
► Users > Manage > New
----
### Back-end Login with account
No Back-end Title + Toolbar
----
### VAL: Title + Toolbar Module
- Duplicate Admin Modules:
- and assign Access to:
► System > Administrator Modules > duplicate
----
### Back-end Login with account
Back-end Title + Toolbar visible
----
### Users: Result
|
User Group: Marketing Group |
|
Viewing Access Level: Marketing Level |
|
Permissions of Marketing Group
- Login back-end
- Manage articles from category "News"
- Manage Redirects
|
---
More
----
### More with Joomla core
- Workflows
- Joomla content Statuses:
Published, Unpublished, Archived, Trashed
- Create your own Statuses + Content Approval Flows
- Webservices API
- Webservices only for Super Users with token?
- Create Super User/token + downgrade to Registered User
----
### More with 3rd Party
- ACL Manager:
- GUI to manage ACL Permissions
developed by Sander Potjer (PWT)
- Membership Pro:
- Extension to move Users to User Groups,
e.g. after payment
---
Demo
---
Questions?
----
## Photo Credits
- https://unsplash.com/photos/blue-and-gray-stairs-inside-building-PFeFOCB6S18
- https://pixabay.com/photos/notebook-paper-pages-open-731212/
- https://www.pexels.com/photo/woman-in-yellow-t-shirt-using-gray-binoculars-3813486/
- https://unsplash.com/photos/a-red-and-white-sign-sitting-on-the-side-of-a-road--XiKxvvFGgU
- https://unsplash.com/photos/creative-decor-Q_6BS8IN0J8
- https://www.pexels.com/photo/group-of-people-near-wall-2422290/
- https://www.pexels.com/photo/woman-in-yellow-t-shirt-using-gray-binoculars-3813486/
- https://unsplash.com/photos/a-red-and-white-sign-sitting-on-the-side-of-a-road--XiKxvvFGgU
- https://www.pexels.com/photo/woman-demonstrating-blank-business-card-in-light-room-7319300/
- https://unsplash.com/photos/a-neon-sign-that-says-more-on-it-VPRnUFM0eX4
- https://unsplash.com/photos/3GZi6OpSDcY
- https://unsplash.com/photos/hhq1Lxtuwd8