<?php

namespace Database\Seeders;

use App\Models\User;
use Illuminate\Database\Seeder;
use Database\Seeders\PlanSeeder;

class DatabaseSeeder extends Seeder
{
    /**
     * Seed the application's database.
     *
     * @return void
     */
    public function run()
    {
        $user = [
            [
                'first_name' => 'Admin',
                'last_name' => 'Admin',
                'role' => 'admin',
                'email_code' => '1234',
                'email' => 'admin@gmail.com',
                'password' => bcrypt('123456'),
            ],
            [
                'first_name' => 'user',
                'last_name' => 'user',
                'role' => 'user',
                'email_code' => '1234',
                'email' => 'user@gmail.com',
                'password' => bcrypt('123456'),
            ],
        ];

        foreach ($user as $key => $value) {
            $user = User::create($value);
            // $this->call(PropertiesTableSeeder::class);
        }

        
        $this->call(PlanSeeder::class);
        // \App\Models\User::factory(10)->create();
    }
}
