Branch - Admin Role
About
This branch provides additional functionality for roles/permissions provided by the spatie/laravel-permission composer package.
Features
Admin
role seeded by default- Artisan command to register new Users (and optionally assign their roles)
- Example Users index page utilizing
useLazyDataTable()
composable
Setup
Clone from source repository, specifying the branch.
bash
git clone -b feature/admin-role https://github.com/connorabbas/laravel-primevue-starter-kit.git
bash
git clone -b feature/admin-role git@github.com:connorabbas/laravel-primevue-starter-kit.git
Follow the standard setup instructions.
Register User command
Since there is no registration page for admins, use the following artisan command:
bash
php artisan user:register
And assign the Admin role.
Admin Pages
A separate Admin dashboard page, and a Users index page are provided by default, protected by the role:Admin
middleware
The Users index page provides an example using the useLazyDataTable()
composable and PrimeVue's <DataTable />
component. To seed the users table with test data (locally) you can run:
bash
php artisan db:seed