<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

return new class extends Migration {
    public function up()
    {
        Schema::table('partners', function (Blueprint $table) {
            $table->integer('sex')->default(0)->after('mobile')->comment('性别,1男,2女,0保密');
            $table->integer('age')->default(0)->after('sex')->comment('年龄');
        });
    }

    public function down()
    {
        Schema::table('partners', function (Blueprint $table) {
            //
            $table->dropColumn('sex');
            $table->dropColumn('age');
        });
    }
};