F
Filamentβ€’11mo ago
Oddman

How do I configure the user model to be something like "admin"

Looked over the docs, couldn't find it - wanting to use an Admin model, not User.
4 Replies
josef
josefβ€’11mo ago
use a custom guard and tell filament about it
Oddman
Oddmanβ€’11mo ago
Awesome, thanks @justjosef πŸ™‚ Easy as expected. hehe
Medo
Medoβ€’11mo ago
Just Add to your panel service provider and add admin as guards in config/auth
$panel->login()
->authGuard('admin')
$panel->login()
->authGuard('admin')
Oddman
Oddmanβ€’11mo ago
@msaidm too slow, alrady got the answer and resolved it πŸ™‚ thanks tho Hmmmm. actually this has ruined the login form πŸ€” It's trying to post to a route that doesn't exist anymore. Weird, just started working. That's really odd.