Permissions
Description
Permissions manages Enso route permissions and route-access checks.
The package exposes CRUD, options, table init, table data, and Excel export endpoints for system permissions, and registers the verify-route-access middleware alias used to guard application routes.
It is intended to work together with menus, roles, and users for route-level authorization.
Installation
Install the package:
composer require laravel-enso/permissions
Run the package migrations:
php artisan migrate
Optional publish:
php artisan vendor:publish --tag=permissions-factories
Features
- Permission CRUD endpoints.
- Options endpoint for select fields.
- Table init, table data, and Excel export endpoints.
- Route access middleware alias.
- Integration with menus, roles, and users.
Usage
Main route group:
system.permissions.*
Middleware alias:
verify-route-access
API
HTTP routes
GET api/system/permissions/createPOST api/system/permissionsGET api/system/permissions/{permission}/editPATCH api/system/permissions/{permission}DELETE api/system/permissions/{permission}GET api/system/permissions/initTableGET api/system/permissions/tableDataGET api/system/permissions/exportExcelGET api/system/permissions/options
Middleware
verify-route-access
Depends On
Required Enso packages:
laravel-enso/core↗laravel-enso/dynamic-methods↗laravel-enso/enums↗laravel-enso/forms↗laravel-enso/helpers↗laravel-enso/menus↗laravel-enso/migrator↗laravel-enso/roles↗laravel-enso/select↗laravel-enso/tables↗laravel-enso/users↗
Companion frontend package:
Contributions
are welcome. Pull requests are great, but issues are good too.
Thank you to all the people who already contributed to Enso!