database/seeders/UserSeeder.php
/**
     * Run the database seeds.
     *
     * @return void
     */
Run the database seeds.
@return void
Run the database seeds . @return void
public function run()
    {
        $admin = \App\Models\User::factory()->create(['email' => 'admin@example.com']);
        $admin->assignRole('admin');
        $user = \App\Models\User::factory()->create(['email' => 'user@example.com']);
        \App\Models\User::factory(10)->create();
    }
public function run ( ) { $ admin = \ App \ Models \ User :: factory ( ) -> create ( [ 'email' => 'admin@example.com' ] ) ; $ admin -> assignRole ( 'admin' ) ; $ user = \ App \ Models \ User :: factory ( ) -> create ( [ 'email' => 'user@example.com' ] ) ; \ App \ Models \ User :: factory ( 10 ) -> create ( ) ; }
Run the database seeds.
Run the database seeds .