firefly-iii/database/migrations/2016_06_16_000001_create_users_table.php
2016-06-18 07:37:12 +02:00

44 lines
1004 B
PHP

<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
/**
* Class CreateUsersTable
*/
class CreateUsersTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
if (!Schema::hasTable('users')) {
Schema::create(
'users', function (Blueprint $table) {
$table->increments('id');
$table->timestamps();
$table->string('email', 255);
$table->string('password', 60);
$table->string('remember_token', 100);
$table->string('reset', 32);
$table->tinyInteger('blocked', false, true)->default('0');
$table->string('blocked_code', 25)->nullable();
}
);
}
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::drop('users');
}
}