<?php

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

class CreateStationTaskBatchesTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('station_task_batches', function (Blueprint $table) {
            $table->id();
            $table->integer('batch_id')->index();
            $table->integer('station_id')->index();
            $table->integer('station_task_batch_type_id')->index();
            $table->enum('status',['待处理','挂起','处理中','完成','异常','取消'])->index();
            $table->timestamps();
        });
    }

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