<?php

namespace Database\Seeders;

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

class UserSeeder extends Seeder
{
    public function run()
    {
        $users = [
            [
                'name' => 'Famel',
                'email' => 'famel@gmail.com',
                'password' => Hash::make('famel123'),
                'pin_code' => '123456',
                'role' => 'karyawan',
                'created_at' => now(),
                'updated_at' => now()
            ],
            [
                'name' => 'Karyawan 1',
                'email' => 'karyawan1@gmail.com',
                'password' => Hash::make('karyawan123'),
                'pin_code' => '234567',
                'role' => 'karyawan',
                'created_at' => now(),
                'updated_at' => now()
            ],
            [
                'name' => 'Karyawan 2',
                'email' => 'karyawan2@gmail.com',
                'password' => Hash::make('karyawan123'),
                'pin_code' => '345678',
                'role' => 'karyawan',
                'created_at' => now(),
                'updated_at' => now()
            ]
        ];

        foreach ($users as $user) {
            User::create($user);
        }
    }
} 