feat: add owner user creation in UserSeeder with associated profile and role assignment

This commit is contained in:
Yoga Pangestu 2026-06-25 20:37:41 +07:00
parent 459d568c1a
commit d2b763ba57

View File

@ -28,6 +28,20 @@ public function run(): void
]);
$developer->assignRole(Role::DEVELOPER->value);
$owner = User::factory()->create([
'email' => 'owner@gmail.com',
'username' => 'owner',
'password' => config('auth.password_default'),
]);
UserProfile::factory()->create([
'user_id' => $owner->id,
'full_name' => 'Owner',
'gender' => Gender::MALE->value,
]);
$owner->assignRole(Role::OWNER->value);
});
}
}