<?php

namespace Database\Seeders;

use App\Models\User;
use Illuminate\Database\Console\Seeds\WithoutModelEvents;
use Illuminate\Database\Seeder;
use Illuminate\Support\Facades\Hash;

class UserSeeder extends Seeder
{
    /**
     * Run the database seeds.
     */
    public function run(): void
    {
//        $admin = User::create([
//            'name' => 'Amine BENDRIOUCH',
//            'email' => 'aminebendriouch.dev@gmail.com',
//            'username' => 'abendriouch',
//            'job' => 'Chef de projets développement',
//            'password' => Hash::make('password')
//        ]);

        $president = User::create([
//            'name' => 'Mohamed ZAHID',
            'name' => 'Test Pre',
//            'email' => 'm.zahid@menara-holding.ma',
            'email' => 'a.bendriouch@menara-prefa.ma',
            'username' => 'mzahid',
            'job' => 'Président Directeur Général',
            'password' => Hash::make('G7Hstn$T')
        ]);

        $office_manager = User::create([
//            'name' => 'Basma LAGRAM',
            'name' => 'Test Manager',
//            'email' => 'b.lagram@menara-holding.ma',
            'email' => 'aminebendriouch.dev@gmail.com',
            'username' => 'blagram',
            'job' => 'Office Manager P.D.G',
            'password' => Hash::make('yy4mAM@T')
        ]);

        $assistant = User::create([
//            'name' => 'Yassine MSAADI',
            'name' => 'Test Assistant',
//            'email' => 'y.msaadi@menara-holding.ma',
            'email' => 'amnben1998@gmail.com',
            'username' => 'ymsaadi',
            'job' => 'Assistant Auprès de la Présidence',
            'password' => Hash::make('t3@Bk&bb')
        ]);

//        $admin->assignRole('admin');
        $president->assignRole('president');
        $office_manager->assignRole('office_manager');
        $assistant->assignRole('assistant');
    }
}
