feat(scanner): implement password reset attempt functionality for scanner users

This commit is contained in:
2026-08-13 16:44:27 -03:00
parent e33ebf0af1
commit 630b49cad7
8 changed files with 253 additions and 3 deletions

View File

@@ -56,9 +56,11 @@ class NotificationMailService
return;
}
$recoveryDomain = $channel === PasswordResetRequested::CHANNEL_ADMINAPP
? $tenant->websiteType?->dominio
: $tenant->dominio;
$recoveryDomain = match ($channel) {
PasswordResetRequested::CHANNEL_ADMINAPP => $tenant->websiteType?->dominio,
PasswordResetRequested::CHANNEL_SCANNER => $tenant->websiteType?->scanner_domain,
default => $tenant->dominio,
};
$recoveryUrl = $recoveryDomain === null
? null
: 'https://'.$recoveryDomain.'/recuperar-contrasena/codigo?email='.urlencode($attempt->user->email);