<?php

use Illuminate\Database\Seeder;
use App\Status;

class StatusSeeder extends Seeder
{
    /**
     * Run the database seeds.
     *
     * @return void
     */
    public function run()
    {
        $inserts = array(
            array(
                'Abierta', 'open', 'task'
            ),
            array(
                'Abierta', 'open', 'subtask'

            ),
            array(
                'Cerrada', 'closed', 'task'
            ),
            array(
                'Cerrada', 'closed', 'subtask'
            ),
            array(
                'En espera', 'on-wait', 'task'
            ),
            array(
                'Cancelada', 'cancelled', 'task'
            ),
            array(
                'Cancelada', 'cancelled', 'subtask'
            ),
        );


        for ($i = 0; $i < count($inserts); $i++) {

            $model = new Status();

            $model->name = $inserts[$i][0];
            $model->slug = $inserts[$i][1];
            $model->status_type = $inserts[$i][2];

            $model->save();





        }
    }
}
