<?php

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

return new class extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('order_user_infos', function (Blueprint $table) {
            $table->id();
            $table->integer('order_id')->unique()->unsigned()->comment("订单id");
            $table->string('name')->nullable()->comment("真实姓名");
            $table->date('birthday')->nullable()->comment("生日");
            $table->integer('stature')->nullable()->comment("身高");
            $table->float('weight', 5,2)->nullable()->comment("体重");
            $table->enum('sex', [1,2])->nullable()->comment("性别 1:男，2:女");
            $table->string('stomach')->nullable()->comment("肠胃问题");
            $table->string('heart')->nullable()->comment("心脏问题");
            $table->string('sleep')->nullable()->comment("睡眠问题");
            $table->string('immunity')->nullable()->comment("免疫力问题");
            $table->string('man')->nullable()->comment("男科问题");
            $table->text('other')->nullable()->comment("其他问题");
            $table->string('dietary')->nullable()->comment("饮食问题");
            $table->string('living')->nullable()->comment("生活问题");
            $table->text('mental')->nullable()->comment("心理状态");
            $table->text('family')->nullable()->comment("家庭关系");
            $table->string('family_member')->nullable()->comment("家庭成员");
            $table->string('personal')->nullable()->comment("个人情况");
            $table->string('desc')->nullable()->comment("其他描述");
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('order_user_infos');
    }
};
