<?php

namespace Database\Seeders;

use Dipokhalder\EnvEditor\EnvEditor;
use Illuminate\Database\Seeder;
use App\Models\Faq;
use App\Enums\Status;

class FaqTableSeeder extends Seeder
{
    /**
     * Run the database seeds.
     *
     * @return void
     */
    public array $faqs = [
        [
            'question' => 'What types of meals do you offer?',
            'answer'   => 'At TiffinKing, we offer a diverse range of meals, including home-style comfort food, corporate catering options, and region-based specialties. Our menu features nutritious and delicious dishes crafted with fresh ingredients, ensuring a perfect balance of taste and health. Whether you need daily meals, event catering, or customized meal plans, we’ve got you covered!'
        ],
        [
            'question' => 'Are your ingredients fresh and locally sourced?',
            'answer'   => 'At TiffinKing, we offer a diverse range of meals, including home-style comfort food, corporate catering options, and region-based specialties. Our menu features nutritious and delicious dishes crafted with fresh ingredients, ensuring a perfect balance of taste and health. Whether you need daily meals, event catering, or customized meal plans, we’ve got you covered!'
        ],
        [
            'question' => 'Do you provide vegetarian or vegan options?',
            'answer'   => 'At TiffinKing, we offer a diverse range of meals, including home-style comfort food, corporate catering options, and region-based specialties. Our menu features nutritious and delicious dishes crafted with fresh ingredients, ensuring a perfect balance of taste and health. Whether you need daily meals, event catering, or customized meal plans, we’ve got you covered!'
        ],
        [
            'question' => 'Can I customize my meal plan?',
            'answer'   => 'At TiffinKing, we offer a diverse range of meals, including home-style comfort food, corporate catering options, and region-based specialties. Our menu features nutritious and delicious dishes crafted with fresh ingredients, ensuring a perfect balance of taste and health. Whether you need daily meals, event catering, or customized meal plans, we’ve got you covered!'
        ],
        [
            'question' => 'What is the delivery schedule and service area?',
            'answer'   => 'At TiffinKing, we offer a diverse range of meals, including home-style comfort food, corporate catering options, and region-based specialties. Our menu features nutritious and delicious dishes crafted with fresh ingredients, ensuring a perfect balance of taste and health. Whether you need daily meals, event catering, or customized meal plans, we’ve got you covered!'
        ],
        [
            'question' => 'How do I place an order?',
            'answer'   => 'At TiffinKing, we offer a diverse range of meals, including home-style comfort food, corporate catering options, and region-based specialties. Our menu features nutritious and delicious dishes crafted with fresh ingredients, ensuring a perfect balance of taste and health. Whether you need daily meals, event catering, or customized meal plans, we’ve got you covered!'
        ],
        [
            'question' => 'Are your ingredients fresh and locally sourced?',
            'answer'   => 'At TiffinKing, we offer a diverse range of meals, including home-style comfort food, corporate catering options, and region-based specialties. Our menu features nutritious and delicious dishes crafted with fresh ingredients, ensuring a perfect balance of taste and health. Whether you need daily meals, event catering, or customized meal plans, we’ve got you covered!'
        ]
    ];

    public function run()
    {
        $envService = new EnvEditor();
        if ($envService->getValue('DEMO')) {
            foreach ($this->faqs as $faq) {
                Faq::create([
                    'question' => $faq['question'],
                    'answer'   => $faq['answer'],
                    'status'   => Status::ACTIVE
                ]);
            }
        }
    }
}
