Laravel-5-Generators-Extended icon indicating copy to clipboard operation
Laravel-5-Generators-Extended copied to clipboard

create empty pivot table

Open johnef opened this issue 4 years ago • 0 comments

  • Laravel Version: 5.8.13
  • PHP Version: 7.1.3
  • Laravel-5-Generators-Extended Version:
  • Command: php artisan make:migration:pivot cities suppliers

What I did

I am trying to run php artisan make:migration:pivot cities suppliers

What happened

ya sure it created the migration witch looks like this 2020_08_27_030342_create__pivot_table.php and inside the migration file all the fields empty something like this

Schema::create('', function (Blueprint $table) {
            $table->integer('_id')->unsigned()->index();
            $table->foreign('_id')->references('id')->on('')->onDelete('cascade');
            $table->integer('_id')->unsigned()->index();
            $table->foreign('_id')->references('id')->on('')->onDelete('cascade');
            $table->primary(['_id', '_id']);
        });

johnef avatar Aug 27 '20 00:08 johnef