diff options
Diffstat (limited to 'database')
-rw-r--r-- | database/migrations/2016_09_04_081740_create_users_table.php | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/database/migrations/2016_09_04_081740_create_users_table.php b/database/migrations/2016_09_04_081740_create_users_table.php new file mode 100644 index 0000000..c5586dc --- /dev/null +++ b/database/migrations/2016_09_04_081740_create_users_table.php @@ -0,0 +1,33 @@ +<?php + +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->increments('id'); + $table->string('email')->unique(); + $table->string('name')->unique(); + $table->string('password'); + $table->integer('points')->default(0); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::drop('users'); + } +} |