F
Filamentβ€’6mo ago
joaoppcastro

How to redirect route to panel with id or channel_id?

I have this route: Route::get('/login', function () { return redirect(route('filament.admin.auth.login')); })->name('login'); Supposedly I'm doing the email verification and once verified it goes to the login but after that I wanted it to go to the admin panel, the redirect isn't exactly that, so what's there goes to the home page 127.0.0.1:8000, The intention was to go to the panel through the channel if I understand myself, can anyone help?
3 Replies
joaoppcastro
joaoppcastroβ€’6mo ago
And I can only log in to an anonymous tab because I'm already logged in as admin
DrByte
DrByteβ€’6mo ago
Filament handles all the routes for login per-panel in a way that automatically takes the logged-in user to the main page of that same panel once login is completed. So, visiting /admin when not logged in to the admin panel, takes you to the admin login route, and when login is completed, takes you back to the path of the admin page that was attempted to be accessed before being logged in. What is your app trying to do that's different from that flow? and why? Understanding that will help provide a solution ... (Since you mentioned email verification, it does similarly: the email verification, when clicked, will take the visitor to the panel they were verified for accessing.)
joaoppcastro
joaoppcastroβ€’6mo ago
thanks for explaining !! πŸ™‚