<?php

namespace Database\Seeders;

use Illuminate\Database\Console\Seeds\WithoutModelEvents;
use Illuminate\Database\Seeder;
use Illuminate\Support\Facades\Schema;

class DatabaseSeeder extends Seeder
{
    use WithoutModelEvents;

    public function run(): void
    {
        Schema::disableForeignKeyConstraints();

        try {
            $this->call([
                RolePermissionSeeder::class,
                UserSeeder::class,
                ProjectSeeder::class,
                TaskSeeder::class,
                SprintSeeder::class,
                BacklogSeeder::class,
                MeetingTypeSeeder::class,
                MeetingSeeder::class,
                CommentSeeder::class,
                ActivityLogSeeder::class,
                NotificationSeeder::class,
                SettingSeeder::class,
            ]);
        } finally {
            Schema::enableForeignKeyConstraints();
        }
    }
}
