up()
up() : void
Run the migrations.
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
class CreateClassTable extends Migration {
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('class', function(Blueprint $table)
{
$table->integer('id', true);
$table->string('name')->nullable();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::drop('class');
}
}