<?php

use Illuminate\Database\Seeder;

class CompanyRequestTopicSeeder extends Seeder
{
    /**
     * Run the database seeds.
     *
     * @return void
     */
    public function run()
    {
        $topics = factory(\App\CompanyRequestTopic::class, 3)->create();

        foreach (languages() as $language) {
            foreach ($topics as $topic) {
                factory(\App\CompanyRequestTopicDescription::class)->create([
                    'company_request_topic_id' => $topic->id,
                    'language_id' => $language->id,
                ]);
            }


        }
    }
}
