<?php

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

class CreateStudentCountTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('student_count', function (Blueprint $table) {
            $table->increments('id');
            $table->integer('year')->nullable()->comment('年份');
            $table->string('class',32)->nullable()->comment('科类');
            $table->integer('grade')->nullable()->comment('分数');
            $table->integer('sum')->nullable()->comment('人数');
            $table->integer('total')->nullable()->comment('累计');

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

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