1
0
forked from s421507/eOSP2
eOSP2/database/migrations/2014_10_12_000000_create_users_table.php

50 lines
1.5 KiB
PHP
Raw Normal View History

2019-07-11 23:55:51 +02:00
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
2019-10-06 02:15:16 +02:00
class CreateUsersTable extends Migration
2019-07-11 23:55:51 +02:00
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('users', function (Blueprint $table) {
$table->increments('id');
$table->string('password', 100);
$table->string('name', 45);
$table->string('surname', 45);
$table->string('PESEL',11);
$table->string('phoneNumber', 9);
$table->string('email', 50)->unique();
$table->integer('fireStationID')->nullable();
$table->integer('functionID');
$table->integer('degreeID');
$table->string('number', 45)->nullable()->default(null);
$table->integer('statusID')->default(0);
$table->integer('deleted')->default(0);
$table->integer('creatorID')->nullable()->default(null);
$table->integer('changingID')->nullable()->default(null);
$table->boolean('confirmed')->default(0);
$table->string('confirmation_code')->nullable();
2019-07-11 23:55:51 +02:00
$table->timestamp('email_verified_at')->nullable();
$table->rememberToken();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('users');
}
}