<?php

namespace Database\Seeders;

use Illuminate\Database\Console\Seeds\WithoutModelEvents;
use Illuminate\Database\Seeder;
use App\Models\ProductLocationRack;

class ProductRacksTableSeeder extends Seeder
{
    /**
     * Run the database seeds.
     *
     * @return void
     */
    public function run()
    {
        /**
         * Reset the ProductLocationRack table
         */
        // if (\App::environment('local')) {
        //     ProductLocationRack::truncate();
        // }

        $group = [
                'name'         => 'N/A',
                'code'         =>'N/A',
                'warehouse_id' => '1',
                'company_id'   => '1',
                'priority'     => '1',
                'status'       => '1',
                'is_default'   => '1',
            ];

        ProductLocationRack::firstOrCreate(['code' => 'N/A'], $group);
    }
}
