<?php

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

class CreateCombosTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('combos', function (Blueprint $table) {
            $table->id();
            $table->bigInteger(' hospital_id')->index();
            $table->string('combo_id', 50)->index()->comment('套餐 ID');
            $table->string('name', 50)->comment('套餐 名称');
            $table->decimal('original_price')->comment('原始价格');
            $table->decimal('price')->comment('价格');
            $table->string('cover', 200)->comment('套餐封面图');
            $table->string('intro', 200)->comment('套餐简介');
            $table->string('sub_intro', 200)->comment('服务承诺');
            $table->longText('desc')->comment('套餐详情');
            $table->longText('items')->comment('所含项目 JSON');
            $table->timestamps();
        });
    }

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