database/seeds/ProductSeed.php
/**
     * Run the database seeds.
     *
     * @return void
     */
Run the database seeds.
@return void
Run the database seeds . @return void
public function run()
    {
        $items = [
            ['id' => 1, 'photo1' => '/tmp/php9yJVJI', 'album_id' => null,],
        ];
        foreach ($items as $item) {
            \App\Product::create($item);
        }
    }
public function run ( ) { $ items = [ [ 'id' => 1 , 'photo1' => '/tmp/php9yJVJI' , 'album_id' => null , ] , ] ; foreach ( $ items as $ item ) { \ App \ Product :: create ( $ item ) ; } }
Run the database seeds.
Run the database seeds .