<?php

use App\Page;
use App\PageDescription;
use Illuminate\Database\Seeder;

class PagesDescriptionSeeder extends Seeder
{
    /**
     * Run the database seeds.
     *
     * @return void
     */
    public function run()
    {
        foreach (Page::cursor() as $page) {
            foreach (languages() as $language) {
                factory(PageDescription::class)->create([
                    'language_id' => $language->id,
                    'page_id' => $page->id
                ]);
            }
        }
    }
}
