<?php

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

class CreateFurnitureNewgoodsCommentTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('furniture_newgoods_comment', function (Blueprint $table) {
            $table->increments('id');
            $table->integer('user_id')->comment('用户ID');
            $table->integer('newgoods_id')->comment('新品ID');
            $table->integer('comments_field_1')->comment('评价条目1评分');
            $table->integer('comments_field_2')->comment('评价条目2评分');
            $table->integer('comments_field_3')->comment('评价条目3评分');
            $table->integer('comments_field_4')->comment('评价条目4评分');
            $table->text('content')->nullable()->comment('评论详情');
            $table->integer('store_id')->comment('店铺ID');

            $table->timestamps();
        });
    }

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