In the last part, we completed user Authentication for our admin panel. In this part, we going to implement user roles and permissions.
- Part 1 — Installation
- Part 2 — Authentication
- Part 3 — User roles and permissions
- Part 4 — Basic Laravel CRUD creation for permission management
- Part 5 — CRUD access control based on role and permission
- Part 6 — Basic search filter and column sort with pagination
- Part 7 — Create UI for Role management
- Part 8 — Laravel user management CRUD
- Part 9 — Create an account update page
- Part 10 — Restructuring a Laravel controller using Form Request Validation
- Part 11 — Restructuring a Laravel controller using Services & Action Classes
- Part 12 — Create Reusable Blade Components in Laravel
- Part 13 — Implement Delete Confirmation in Laravel CRUD
- Part 14 — Migrating from Laravel Mix to Vite
Multiple user roles and permission controls are required features for the admin panel.
The Spatie Laravel-permission is the best package to manage user permissions and roles in a database. In this part, we install and use this package for our admin panel.
The following steps are involved to set up roles and permission to our Laravel Admin panel.
- 1. Install Spatie Laravel-permission package
- 2. Publish the configuration and migration file
- 3. Running Migration
Read full story on medium.com
Previous part — Part 2: Steps for adding a user authentication to the Laravel application
Next part — Part 4: Laravel CRUD creation for permission management