F
Filament16mo ago
Wiin

Setting $panel->path('') causes route not defined error

Hello, I've recently started using filament v3 and when creating the panel if I try to set the path without prefix like this: return $panel ->default() ->id('admin') ->path('') The app throws this error: Route [filament.admin.auth.login] not defined. But if I set the path to something else like ->path('app') and go to /app it works perfectly. Any idea what could be causing the error? I'm using the stancl/multitenancy library too, but I don't think it has anything to do with the error.
4 Replies
Shaung Bhone
Shaung Bhone16mo ago
Make sure your routes/web.php file doesn't already define the '' or '/' route, as it will take precedence.
Wiin
WiinOP16mo ago
Ok I think it might have something to do with the original laravel routes causing conflict with filament ones Yes already checked, I think I need to remove laravel default /login routes or something Yep, that was the issue, confirmed. Thanks a lot
Shaung Bhone
Shaung Bhone16mo ago
ok mark as solution
sadiqumar
sadiqumar15mo ago
@wiin out of curiosity I just wanted to know how you were able to setup tenancy, I've done everything from the documentation and added InitilizeByDomainSobdomain in my admin panel middle ware, but I get 404
Want results from more Discord servers?
Add your server