<?php

use Illuminate\Database\Seeder;

class PageSeeder extends Seeder
{
    /**
     * Run the database seeds.
     *
     * @return void
     */
    public function run()
    {

        factory(\App\Page::class, 3)->create(); // [vision, message, goals]
        factory(\App\Page::class, 3)->create(['image' => 'assets/admin/images/logo.png']); // 3 cards in Why us

        /**
         * [
         * Chairman Message
         * Patient Information
         * Patients Services
         * InPatient
         * Nursing
         * Quality Department
         * Accreditation
         * CEO Message
         * ]
         */
        factory(\App\Page::class,8)->create(['image' => 'assets/admin/images/logo.png']);

        factory(\App\Page::class)->create(); // Board of Directors

        factory(\App\Page::class, 6)->create(); // Home page sections



        foreach (languages() as $language) {
            // [vision, message, goals]
            factory(\App\PageDescription::class)->create([
                'page_title' => 'الرؤية',
                'title' => 'الرؤية',
                'page_id' => 1,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'الرسالة',
                'title' => 'الرسالة',
                'page_id' => 2,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'الأهداف',
                'title' => 'الأهداف',
                'page_id' => 3,
                'language_id' => $language->id,
            ]);

            // 3 cards in Why us
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Why us card 1',
                'title' => 'Great Infrastructure',
                'description' => 'Our 100-bedded, well-furnished hospital with technologically well-equipped Diagnostics
center and extraordinary ambience is uniquely positioned in paving the way for a new era
in health care in the region.',
                'page_id' => 4,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Why us card 2',
                'title' => 'Outstanding, Highly Qualified Doctors',
                'description' => 'An organization is only as good as it\'s people are. No effort has been spared to bring on board
the best of the medical profession across clinical specialties, from around the globe. Our panel of
medical experts have extraordinarily credentialed and defined each doctor`s privileges, ensuring
increased patient safety with the provision of high-quality medical services. The talent pool is
further strengthened by qualified and well-trained nursing and technical professionals. Our
nurses are trained in the latest techniques across various specialties and have implemented
global best practices in caregiving.',
                'page_id' => 5,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Why us card 3',
                'title' => 'Emergency Support',
                'description' => 'Level-1, 24-Hour Accident & Emergency Centre. A&E is equipped with state-of-the-art
equipment for a wide spectrum of patients with acute emergencies for initial evaluation,
resuscitation, treatment, investigation, stabilisation, monitoring and disposition',
                'page_id' => 6,
                'language_id' => $language->id,
            ]);

            /**
             * [
             * Chairman Message
             * Patient Information
             * Patients Services
             * InPatient
             * Nursing
             * Quality Department
             * Accreditation
             * CEO Message
             * ]
             */
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Chairman Message',
                'title' => 'Chairman Message',
                'page_id' => 7,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Patient Information',
                'title' => 'Patient Information',
                'title_2' => 'Patient Information',
                'description_2' => 'Description 2 here',
                'page_id' => 8,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Patients Services',
                'title' => 'Patients Services',
                'page_id' => 9,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'In Patient',
                'title' => 'In Patient',
                'page_id' => 10,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Nursing',
                'title' => 'Nursing',
                'page_id' => 11,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Quality Department',
                'title' => 'Quality Department',
                'page_id' => 12,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Accreditation',
                'title' => 'Accreditation',
                'page_id' => 13,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'CEO Message',
                'page_id' => 14,
                'language_id' => $language->id,
            ]);

            // Board of Directors
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Second section in Board of Directors',
                'title' => 'Title here',
                'page_id' => 15,
                'language_id' => $language->id,
            ]);

            // Home page sections
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Home page section (1)',
                'page_id' => 16,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Home page section (2)',
                'page_id' => 17,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Home page section (3)',
                'page_id' => 18,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Home page section (4)',
                'page_id' => 19,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Home page section (5)',
                'page_id' => 20,
                'language_id' => $language->id,
            ]);
            factory(\App\PageDescription::class)->create([
                'page_title' => 'Home page section (6)',
                'page_id' => 21,
                'language_id' => $language->id,
            ]);


        }
    }
}
