📅  最后修改于: 2022-03-11 14:54:16.057000             🧑  作者: Mango
// You forgot to create the column before creating the relationship
// Do something like (add unsigned before the relationship):
$table->integer('user_id')->unsigned();
$table->foreign('user_id')->references('id')->on('users');