<?php

use Illuminate\Database\Seeder;

class PageDescriptionSeeder extends Seeder
{
    /**
     * Run the database seeds.
     *
     * @return void
     */
    public function run()
    {
        $image = 'assets/admin/images/logo.png';
        factory(\App\Page::class)->create(['why_us_image' => $image, 'why_us_experience_years' => 10]); //
        factory(\App\Page::class)->create(['about_us_overview_image' => $image]); //
        factory(\App\Page::class)->create(['about_us_social_responsibility_image' => $image]); //
        factory(\App\Page::class)->create(['about_us_company_strategy_image' => $image]); //
        factory(\App\Page::class)->create(['vision_icon' => $image, 'message_icon' => $image, 'values_icon' => $image]); //
        factory(\App\Page::class)->create(['culture_values_image' => $image]); //
        factory(\App\Page::class)->create(['performance_development_image' => $image]);


        foreach (languages() as $language) {
            factory(\App\PageDescription::class)->create([
                'why_us_title' => 'why us title',
                'why_us_description' => 'why us description',
                'why_us_experience_years_title' => 'why us experience years title',
                'page_id' => 1,
                'language_id' => $language->id
            ]);
            factory(\App\PageDescription::class)->create([
                'about_us_overview_title' => 'about us overview title',
                'about_us_overview_description' => 'about us overview description',
                'page_id' => 2,
                'language_id' => $language->id
            ]);
            factory(\App\PageDescription::class)->create([
                'about_us_social_responsibility_title' => 'about us social responsibility title',
                'about_us_social_responsibility_description' => 'about us social responsibility description',
                'page_id' => 3,
                'language_id' => $language->id
            ]);
            factory(\App\PageDescription::class)->create([
                'about_us_company_strategy_title' => 'about us company strategy title',
                'about_us_company_strategy_description' => 'about us company strategy description',
                'page_id' => 4,
                'language_id' => $language->id
            ]);
            factory(\App\PageDescription::class)->create([
                'vision_title' => 'vision title',
                'message_title' => 'message title',
                'values_title' => 'values title',
                'vision_description' => 'vision description',
                'message_description' => 'message description',
                'values_description' => 'values description',
                'page_id' => 5,
                'language_id' => $language->id
            ]);
            factory(\App\PageDescription::class)->create([
                'culture_values_title' => 'culture values title',
                'culture_values_description' => 'culture values description',
                'page_id' => 6,
                'language_id' => $language->id
            ]);
            factory(\App\PageDescription::class)->create([
                'performance_development_title' => 'performance development title',
                'performance_development_description' => 'performance development description',
                'page_id' => 7,
                'language_id' => $language->id
            ]);
        }

    }
}
