My current project for college is a school management system. It consists mainly of three "profiles" - one for students, another for teachers/professors and a third for coordinators/admins.
After authentication and leaving the login page, this is what I'd like to happen:
- If users occupy only one role inside the application, they should be redirected directly to the correspondent profile (e.g.: a student goes straight to a student profile);
- However, for those who occupy two or even all three roles (unlikely but possible), an identities page gives them a choice between their different profiles;
- A user can only have access to pages and profiles as defined by their role(s);
What would be the best way to implement this within Laravel 5.6?
Note: I can currently authenticate users but no permissions and roles are in place. I'm using Laravel's default users table.