答案 0 :(得分:0)
使用php artisan make:migration add_ancestry_column_to_users_table
创建新的迁移,并用下面的代码替换以下两个函数:
public function up()
{
Schema::table('users', function (Blueprint $table) {
$table->string('ancestry')->nullable();
});
}
public function down()
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn('ancestry');
});
}