<?php

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

return new class extends Migration
{
    /**
     * Run the migrations.
     */
    public function up(): void
    {
        Schema::create('order', function (Blueprint $table) {
            $table->id();
            $table->string('order_no')->comment('訂單編號');
            $table->string('member_id')->comment('會員編號');
            $table->string('name')->comment('姓名');
            $table->integer('goods_code')->nullable()->comment('提貨編號');
            $table->string('goods')->comment('商品');
            $table->string('amount')->comment('金額');
            $table->string('status')->comment('狀態0:未付款,1:已付款,2:已兌換 ,3:優惠碼兌換,4:已完成,5:已取消');
            $table->string('note')->comment('備註');
            $table->string('price')->comment('單一價格');
            $table->timestamps();
        });
    }

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