:::

5-4 /database/migrations/2018_08_10_145117_add_tests_cols.php

<?php

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

class AddTestsCols extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::table('tests', function (Blueprint $table) {
            $table->unsignedTinyInteger('grade');
            $table->unsignedTinyInteger('class');
            $table->unsignedTinyInteger('num');
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::table('tests', function (Blueprint $table) {
            $table->dropColumn(['grade', 'class', 'num']);
        });
    }
}

 


:::

書籍目錄

展開 | 闔起

https%3A%2F%2Fcampus-xoops.tn.edu.tw%2Fmodules%2Ftad_book3%2Fpage.php%3Ftbdsn%3D1333

計數器

今天: 3567356735673567
昨天: 3438343834383438
總計: 7393896739389673938967393896739389673938967393896