Fix: New registered candidates visibility (profile creation and tenant scope adjustment)

This commit is contained in:
jeremy bayse
2026-04-16 18:31:23 +02:00
parent 957947cc0b
commit 84a9c6bb14
2 changed files with 10 additions and 1 deletions

View File

@@ -41,6 +41,12 @@ class RegisteredUserController extends Controller
'name' => $request->name,
'email' => $request->email,
'password' => Hash::make($request->password),
'role' => 'candidate',
]);
// Create the associated candidate record so they appear in the lists
$user->candidate()->create([
'status' => 'en_attente',
]);
event(new Registered($user));