Creating and managing user roles in Magento 2 is essential for maintaining secure and efficient store operations. By precisely assigning permissions to different users, you can effectively control access and streamline administrative tasks. Here’s a step-by-step guide to help you create user roles in Magento effortlessly.
Steps to Create User Roles in Magento 2
1. Navigate to User Roles
- Log into your Magento Admin Panel.
- Go to System > Permissions > User Roles.
2. Add a New Role
After that click the “Add New Role” button.
3. Define Role Information
Fill out the following details for adding new roles.
3.1 Role Name
Enter a descriptive and unique name for the role (e.g., “Sales Manager“ or “Product Editor”).
3.2 Your Password
Enter your current admin password for verification.
3.3 Save Initial Role Information
Click the “Save Role” button to proceed.
4. Configure Role Resources
4.1 Access Role Resources
After saving the initial role information, navigate to the Role Resources tab.
4.2 Set Resource Access Levels
Select “Custom” to assign specific permissions, or “All” to grant unrestricted access.
4.3 Select Specific Permissions
A detailed list of resources will appear if’ Custom’ is selected. Check the boxes for the resources you wish to grant access to. For example, to grant access to order and customer management, select:
- “Sales > Operations > Orders”
- “Customers > All Customers”
4.4 Save Resource Settings
Click the “Save Role” button to finalize the permissions.
5. Assign the Role to a User
5.1 Navigate to User Management
Go to System > Permissions > All Users.
5.2 Create a New User
Click the “Add New User” button.
5.3 Complete User Information
- User Name
Create a distinctive username.
- First Name and Last Name
Enter the user’s full name.
Provide the user’s email address.
- Password
Set a strong password for the user.
- Interface Locale
Select the preferred language for the admin interface.
- Assign the Appropriate Role
In the User Role section, select the role you created from the available roles list.
- Save User Information
Click the “Save User” button to complete the user creation process and assign the specified role.
Creating and managing user roles in Magento 2 allows you to control access precisely, improving security and efficiency. By setting specific permissions, you ensure users only access the areas they need, optimizing store management.