feat: add missing profile and status columns to users table
This commit is contained in:
+31
@@ -0,0 +1,31 @@
|
|||||||
|
use Illuminate\Database\Migrations\Migration;
|
||||||
|
use Illuminate\Database\Schema\Blueprint;
|
||||||
|
use Illuminate\Support\Facades\Schema;
|
||||||
|
|
||||||
|
return new class extends Migration
|
||||||
|
{
|
||||||
|
public function up(): void
|
||||||
|
{
|
||||||
|
Schema::table('users', function (Blueprint $table) {
|
||||||
|
$table->string('phone')->nullable()->after('name');
|
||||||
|
$table->string('user_email')->nullable()->after('phone');
|
||||||
|
$table->integer('birth_year')->nullable()->after('user_email');
|
||||||
|
$table->string('address')->nullable()->after('birth_year');
|
||||||
|
$table->tinyInteger('known_sis')->nullable()->after('address');
|
||||||
|
$table->string('job')->nullable()->after('known_sis');
|
||||||
|
$table->tinyInteger('status')->default(1)->after('job');
|
||||||
|
$table->tinyInteger('spined')->default(0)->after('status');
|
||||||
|
$table->string('confirmation_string')->nullable()->after('spined');
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
public function down(): void
|
||||||
|
{
|
||||||
|
Schema::table('users', function (Blueprint $table) {
|
||||||
|
$table->dropColumn([
|
||||||
|
'phone', 'user_email', 'birth_year', 'address',
|
||||||
|
'known_sis', 'job', 'status', 'spined', 'confirmation_string'
|
||||||
|
]);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
};
|
||||||
Reference in New Issue
Block a user