1
0
Fork 0
pixelfed/database/migrations/2014_10_12_000000_create_us...

39 lines
953 B
PHP
Raw Normal View History

2018-04-15 23:56:48 +00:00
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateUsersTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('users', function (Blueprint $table) {
$table->bigIncrements('id');
2018-04-16 00:12:07 +00:00
$table->string('name')->nullable();
$table->string('username')->nullable()->unique()->index();
2018-04-15 23:56:48 +00:00
$table->string('email')->unique();
$table->string('password');
$table->rememberToken();
2018-04-16 00:12:07 +00:00
$table->boolean('is_admin')->default(false);
$table->timestamp('email_verified_at')->nullable();
2018-04-15 23:56:48 +00:00
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('users');
}
}