Voyager (https://voyager.devdojo.com/) is a very nice ready-made admin for your laravel site. It makes building your admin section quite a lot easier. And if your needs are more specific, Voyager lets you extend Controllers and Views so you can pretty much adapt it however you like.
But being a bad programmer, I ran into a few bumps while trying to get Voyager working. Let's see which ones and how to avoid them.
Memory problem when installing Voyager locally with Composer
When trying to download the Voyager package with Composer locally, I ran into a memory limit error.
You need to use memory_limit=-1 to avoid itphp -d memory_limit=-1 yourpathto/composer/composer.phar require tcg/voyager
Key too long at Voyager install
When executing php artisan voyager:install , I got a PDO Exception : key too long max length 1000 error.
You can resolve it in config/database.php adding this in the mysql config array
'mysql' => [
...
'engine' => 'InnoDB ROW_FORMAT=DYNAMIC',
...
]
Laravel version
Be careful of the Laravel version you're using. For Voyager 1.2, it's Laravel 5.8 maxcomposer create-project --prefer-dist laravel/laravel awesomeprojectname "5.8.*"
Your best bet is to check https://github.com/the-control-group/voyager to see what's what.
An admin user needs to be created
When an admin user exists in database:php artisan voyager:admin your@email.com
When no admin user exists in database:php artisan voyager:admin your@email.com --create
Relationships creation
When creating a BREAD relationship in Voyager, it's easy to forget to create the model. Well, don't.
And when creating the relationship you need to provide the model path, i.e. App\MyModel