<?php

namespace Database\Seeders;

use App\Models\SpeakerType;
use Illuminate\Database\Seeder;

class SpeakerTypeSeeder extends Seeder
{
    public function run(): void
    {
        $types = [
            ['name' => 'Keynote Speaker', 'slug' => 'keynote', 'color' => 'primary', 'order' => 1],
            ['name' => 'Plenary Speaker', 'slug' => 'plenary', 'color' => 'success', 'order' => 2],
            ['name' => 'Invited Speaker', 'slug' => 'invited', 'color' => 'warning', 'order' => 3],
            ['name' => 'Workshop Presenter', 'slug' => 'workshop', 'color' => 'info', 'order' => 4],
        ];

        foreach ($types as $type) {
            SpeakerType::updateOrCreate(
                ['slug' => $type['slug']],
                array_merge($type, ['is_active' => true])
            );
        }
    }
}
