<?php

namespace Database\Seeders;

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

class DatabaseSeeder extends Seeder
{
    public function run(): void
    {
        // Admin
        User::updateOrCreate(
            ['email' => 'admin@gmail.com'],
            [
                'nama' => 'Admin',
                'password' => Hash::make('password123'),
                'role' => 'admin',
            ]
        );

        // Ekspedisi
        User::updateOrCreate(
            ['email' => 'ekspedisi@gmail.com'],
            [
                'nama' => 'Ekspedisi',
                'password' => Hash::make('password123'),
                'role' => 'ekspedisi',
            ]
        );
    }
}