Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
pterodactyl
GitHub Repository: pterodactyl/panel
Path: blob/1.0-develop/database/migrations/2016_01_23_203159_add_users.php
7460 views
1
<?php
2
3
use Illuminate\Support\Facades\Schema;
4
use Illuminate\Database\Schema\Blueprint;
5
use Illuminate\Database\Migrations\Migration;
6
7
class AddUsers extends Migration
8
{
9
/**
10
* Run the migrations.
11
*/
12
public function up(): void
13
{
14
Schema::create('users', function (Blueprint $table) {
15
$table->increments('id');
16
$table->char('uuid', 36)->unique();
17
$table->string('email')->unique();
18
$table->text('password');
19
$table->string('remember_token')->nullable();
20
$table->char('language', 5)->default('en');
21
$table->tinyInteger('root_admin')->unsigned()->default(0);
22
$table->tinyInteger('use_totp')->unsigned();
23
$table->char('totp_secret', 16)->nullable();
24
$table->timestamps();
25
});
26
}
27
28
/**
29
* Reverse the migrations.
30
*/
31
public function down(): void
32
{
33
Schema::dropIfExists('users');
34
}
35
}
36
37