FilamentF
Filament5mo ago
rabol

No email is send on registration

Hi

I'm trying to use Filament to do the authentication and also have MFA

My app consists o the frontend and the 3 panels, user, vendor and admin

First:

A user created with
php artisan make:filament-user


cannot login

currently the access check is VERY simple
public function canAccessPanel(Panel $panel): bool
    {
        logger()->info(__('Checking access for user :email on panel :panel', ['email' => $this->email, 'panel' => $panel->getId()]));

        // for now all is allowed
        if ($panel->getId() === 'admin') {
            logger()->info(__('admin: Has verified email :verifiedEmail', ['verifiedEmail' => $this->hasVerifiedEmail()]));

            return $this->hasVerifiedEmail();
        }

        if ($panel->getId() === 'user') {
            logger()->info(__('user: Has verified email :verifiedEmail', ['verifiedEmail' => $this->hasVerifiedEmail()]));

            return $this->hasVerifiedEmail();
        }

        if ($panel->getId() === 'vendor') {
            logger()->info(__('vendor: Has verified email :verifiedEmail', ['verifiedEmail' => $this->hasVerifiedEmail()]));

            return $this->hasVerifiedEmail();
        }

        logger()->info(__('Access denied for user :email on panel :panel', ['email' => $this->email, 'panel' => $panel->getId()]));

        return false;
    }


Register as new user does not send an email, but try to login in the user and then that fails because the email is not yet verified.

I'm sure that it's some kind of configuration, but I think I have followed all the point in the documentation.

what can I do to make this work ?
Was this page helpful?