silverbux / laravel-angular-admin

Laravel + Angularjs + Bootstrap + AdminLTE binded by Gulp workflow Admin Dashboard Boilerplate / Starter.
http://silverbux.github.io/laravel-angular-admin/
MIT License
925 stars 414 forks source link

Two errors when signing in: Cannot read property 'userRole' of undefined AND Cannot read property 'errors' of undefined #91

Open viniciusfreitasmg opened 7 years ago

viniciusfreitasmg commented 7 years ago

Hello, I have done the installation according to the documentation, after running artisan server and open localhost: 8000 opens the login screen of adminLte, but when I inform the user and password the request returns me the following error in console and for that. Can anybody help me?

Error generated at console:

_final-fa2c0e61be.js:24015 TypeError: Cannot read property 'userRole' of undefined at final-fa2c0e61be.js:106906 at processQueue (final-fa2c0e61be.js:26512) at final-fa2c0e61be.js:26528 at Scope.$eval (final-fa2c0e61be.js:27810) at Scope.$digest (final-fa2c0e61be.js:27624) at Scope.$apply (final-fa2c0e61be.js:27918) at done (final-fa2c0e61be.js:21898) at completeRequest (final-fa2c0e61be.js:22107) at XMLHttpRequest.requestLoaded (final-fa2c0e61be.js:22035) (anonymous) @ final-fa2c0e61be.js:24015 (anonymous) @ final-fa2c0e61be.js:20523 processQueue @ final-fa2c0e61be.js:26520 (anonymous) @ final-fa2c0e61be.js:26528 $eval @ final-fa2c0e61be.js:27810 $digest @ final-fa2c0e61be.js:27624 $apply @ final-fa2c0e61be.js:27918 done @ final-fa2c0e61be.js:21898 completeRequest @ final-fa2c0e61be.js:22107 requestLoaded @ final-fa2c0e61be.js:22035

final-fa2c0e61be.js:24015 TypeError: Cannot read property 'errors' of undefined at LoginFormController.failedLogin (final-fa2c0e61be.js:106921) at processQueue (final-fa2c0e61be.js:26512) at final-fa2c0e61be.js:26528 at Scope.$eval (final-fa2c0e61be.js:27810) at Scope.$digest (final-fa2c0e61be.js:27624) at Scope.$apply (final-fa2c0e61be.js:27918) at done (final-fa2c0e61be.js:21898) at completeRequest (final-fa2c0e61be.js:22107) at XMLHttpRequest.requestLoaded (final-fa2c0e61be.js:22035) (anonymous) @ final-fa2c0e61be.js:24015 (anonymous) @ final-fa2c0e61be.js:20523 processQueue @ final-fa2c0e61be.js:26520 (anonymous) @ final-fa2c0e61be.js:26528 $eval @ final-fa2c0e61be.js:27810 $digest @ final-fa2c0e61be.js:27624 $apply @ final-fa2c0e61be.js:27918 done @ final-fa2c0e61be.js:21898 completeRequest @ final-fa2c0e61be.js:22107 requestLoaded @ final-fa2c0e61be.js:22035 tela-erro _

silverbux commented 7 years ago

upon installation did you do?

$ php artisan migrate
$ php artisan db:seed
viniciusfreitasmg commented 7 years ago

Yes, I did this procedure. See the user registry attachment.

tela-registro

viniciusfreitasmg commented 7 years ago

I was able to resolve the error by this post. Thank you!

https://github.com/silverbux/laravel-angular-admin/issues/82#issue