Rolin
Rolin
FFilament
Created by Rolin on 4/8/2024 in #❓┊help
Login not working it's refreshing the page
I've found the issue. The session table want to have a integer as user_id but I'm using a uuid as id for the user so the session is not linked to the user.
24 replies
FFilament
Created by Rolin on 4/8/2024 in #❓┊help
Login not working it's refreshing the page
It's something with the session/cookie. I've installed breeze also and that's also not working.
24 replies
FFilament
Created by Rolin on 4/8/2024 in #❓┊help
Login not working it's refreshing the page
Do you have any idea what is maybe wrong? Or a direction in where I can search?
24 replies
FFilament
Created by Rolin on 4/8/2024 in #❓┊help
Login not working it's refreshing the page
So something is going wrong with the guard but I've no idea what when I dump both the guards (existing laravel and the fresh one) both are the same also the request are the same. The only thing is that the fresh install is $guard->checks() is true and in the existing one is it false.
24 replies
FFilament
Created by Rolin on 4/8/2024 in #❓┊help
Login not working it's refreshing the page
But where 🤔 It is something with the guard I think. The hole login process is working for checking etc. but when it comes to the guard in authenticate then the guard->checks() is false.
24 replies
FFilament
Created by Rolin on 4/8/2024 in #❓┊help
Login not working it's refreshing the page
I've created another fresh install with Laravel 11 with Filament that works but I've checked all the things and everything is the same. So I don't get it why it's not working in an existing Laravel project?
24 replies
FFilament
Created by Rolin on 4/8/2024 in #❓┊help
Login not working it's refreshing the page
It's in a Laravel 11 application that I've created couple weeks ago with only some API endpoints I've added a fresh Filament install to it.
24 replies
FFilament
Created by Rolin on 4/8/2024 in #❓┊help
Login not working it's refreshing the page
class AdminPanelProvider extends PanelProvider
{
public function panel(Panel $panel): Panel
{
return $panel
->default()
->id('admin')
->path('admin')
->login()
->colors([
'primary' => Color::Amber,
])
->discoverResources(in: app_path('Filament/Resources'), for: 'App\\Filament\\Resources')
->discoverPages(in: app_path('Filament/Pages'), for: 'App\\Filament\\Pages')
->pages([
Pages\Dashboard::class,
])
->discoverWidgets(in: app_path('Filament/Widgets'), for: 'App\\Filament\\Widgets')
->widgets([
Widgets\AccountWidget::class,
Widgets\FilamentInfoWidget::class,
])
->middleware([
EncryptCookies::class,
AddQueuedCookiesToResponse::class,
StartSession::class,
AuthenticateSession::class,
ShareErrorsFromSession::class,
VerifyCsrfToken::class,
SubstituteBindings::class,
DisableBladeIconComponents::class,
DispatchServingFilamentEvent::class,
])
->authMiddleware([
Authenticate::class,
]);
}
}
class AdminPanelProvider extends PanelProvider
{
public function panel(Panel $panel): Panel
{
return $panel
->default()
->id('admin')
->path('admin')
->login()
->colors([
'primary' => Color::Amber,
])
->discoverResources(in: app_path('Filament/Resources'), for: 'App\\Filament\\Resources')
->discoverPages(in: app_path('Filament/Pages'), for: 'App\\Filament\\Pages')
->pages([
Pages\Dashboard::class,
])
->discoverWidgets(in: app_path('Filament/Widgets'), for: 'App\\Filament\\Widgets')
->widgets([
Widgets\AccountWidget::class,
Widgets\FilamentInfoWidget::class,
])
->middleware([
EncryptCookies::class,
AddQueuedCookiesToResponse::class,
StartSession::class,
AuthenticateSession::class,
ShareErrorsFromSession::class,
VerifyCsrfToken::class,
SubstituteBindings::class,
DisableBladeIconComponents::class,
DispatchServingFilamentEvent::class,
])
->authMiddleware([
Authenticate::class,
]);
}
}
24 replies
FFilament
Created by Rolin on 4/8/2024 in #❓┊help
Login not working it's refreshing the page
It have the ->default() on it.
24 replies
FFilament
Created by Rolin on 4/8/2024 in #❓┊help
Login not working it's refreshing the page
I've opened the Authenticate class from Filament it looks like something is going wrong here:
protected function authenticate($request, array $guards): void
{
$guard = Filament::auth();

if (! $guard->check()) {
$this->unauthenticated($request, $guards);

return;
}
protected function authenticate($request, array $guards): void
{
$guard = Filament::auth();

if (! $guard->check()) {
$this->unauthenticated($request, $guards);

return;
}
The guard is false so it will go in to the if statement. But the credentials are correct that's the strange part. When I enter not the correct credentials then it will show a message with credentials wrong
24 replies
FFilament
Created by Rolin on 4/8/2024 in #❓┊help
Login not working it's refreshing the page
Console log also nothing
24 replies
FFilament
Created by Rolin on 4/8/2024 in #❓┊help
Login not working it's refreshing the page
I don't get anything in my error logs
24 replies