create(); User::factory()->create([ 'name' => 'Administrator', 'username' => 'admin', 'email' => 'test@example.com', 'role' => UserRole::Admin->value, ]); $chevron = Institute::where('name', 'Chevron')->first(); $srini = Institute::where('name', 'Srinivasa')->first(); User::factory(2)->create([ 'institute_id' => $chevron->id, 'role' => UserRole::Technician->value, ]); User::factory(2)->create([ 'institute_id' => $srini->id, 'role' => UserRole::Technician->value, ]); } }