<?php

use Illuminate\Database\Seeder;

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

        $inserts = array(
            array(
                1, 2, 1
            ),
            array(
                2, 1 , 2
            ),
        );


        for ($i = 0; $i < count($inserts); $i++) {
//
            DB::table('user_unit')->insert(
                ['user_id' => $inserts[$i][0], 'unit_id' =>$inserts[$i][1] ,'teamrole_id' =>$inserts[$i][2] ]
            );

        }
    }
}
