atcheck/database/migrations/2019_11_26_232020_create_classes_table.php

36 lines
792 B
PHP

<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateClassesTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('classes', function (Blueprint $table) {
$table->bigIncrements('id')->unique();
$table->integer('subject_id');
$table->date('date');
$table->string('classes_code')->nullable();
$table->boolean('test_mode')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('classes');
}
}