I can't access voyager admin page anymore. It was working before then it just stopped. Now after admin login, if I try to access it, I get redirected to laravel welcome page. Please any suggestions?
Hi @AdeSamson,
What role does the user you are trying to login as have?
It sounds like the role assigned to that user doesn't have the Dashboard permission set. You can either manually add it via the database or use the command line to add a new user with admin role and then login and add the permission back in to the role.
Sorry I didn't mention earlier. I gave it a role of admin by doing this: php artisan voyager:admin [email protected] --create. Still it redirects me to the welcome page. Funny thing is, it was working perfectly yesterday
This happened to me too, I had been assuming that migrate:refresh --seed was working correctly but AFAICT none of the Voyager seeders are being referenced.
[root]/seeds/DatabaseSeeder.php is blank (with the UsersTableSeeder commented out), I assume because I already had a user when I ran the voyager admin install.
Anyway, editing DatabaseSeeder to add the voyager seeders back in should work, I simply did this to get all the default Voyager data populated which fixed everything
php artisan db:seed --class=DataTypesTableSeeder
php artisan db:seed --class=DataRowsTableSeeder
php artisan db:seed --class=MenusTableSeeder
php artisan db:seed --class=MenuItemsTableSeeder
php artisan db:seed --class=RolesTableSeeder
php artisan db:seed --class=PermissionsTableSeeder
php artisan db:seed --class=PermissionRoleTableSeeder
I should add that I'm using Voyager with Laravel Spark, just in case that makes any difference.
This is also happening to me :-(
I have just installed Voyager and I added admin permissions to one user with php artisan. After that first login, I was able to view the admin area. I then logged out.
When logging in again, I get redirected to my main site upon successful login.
Laravel Version: 5.4.*
PHP Version: 7.0.15
Mysql Version 5.7.18
@bealers, you're correct, we don't add the Voyager seeder to the default seeder, and adding the --seed flag to migrate:refresh doesn't let you specify what seeder class should be run. The solution there is to either do as you've done, or add the single VoyagerDatabaseSeeder instead of the list like you've done, or just call it manually:
> php artisan migrate:refresh --seed
> php artisan db:seed --class=VoyagerDatabaseSeeder
My issue got fixed.
I'm still not sure what the original issue was, but I deleted my app's database, recreated it then ran:
php artisan migrate
php artisan db:seed --class=VoyagerDatabaseSeeder
And created my admin user again. All good.
My issue got fixed too. Thanks
tengo el mismo problema y no e podido resolverlo
I think this issue shoud be re-opened.
Having the same issue, with Laravel 5.5:
Here are the steps:
Push the files into production.
Run the migration files.
Added a user with admin privileges.
Got redirected to the welcome screen.
Any advice?
Please do not comment on old issues. You can create your own or ask in the slack group
Sorry. I was aware of that. But I wasn't able to find my comment to delete it.
For the record this was a permission issue, at it was fixed by re-running voyager install on the production server after deployment.
Cheers, and, again, sorry for the inconvenience.
Marcio
after creating.. php artisan voyager:admin [email protected] --create . It leads to your home page or welcome page of ur laravel.. So.. bcz.. it does not have a permission on it in its voyager databases, or its behavies like this..
just.. after creating ur admin i.e (php artisan voyager:admin [email protected] --create ).
install this: $ php artisan voyager:install
after this .. it works perfectly..
Try it.. bcz I GOT it.
@VedPrakashN, please don't comment on old issues. The last comment here was nearly a year ago, and it's been closed for a few months longer. It's also for a MUCH older version, which can't even be installed anymore.
Most helpful comment
@bealers, you're correct, we don't add the Voyager seeder to the default seeder, and adding the
--seedflag tomigrate:refreshdoesn't let you specify what seeder class should be run. The solution there is to either do as you've done, or add the single VoyagerDatabaseSeeder instead of the list like you've done, or just call it manually: