Skip to content

Instantly share code, notes, and snippets.

@andreferraro
Last active August 29, 2015 14:25
Show Gist options
  • Save andreferraro/186751f7fca293107356 to your computer and use it in GitHub Desktop.
Save andreferraro/186751f7fca293107356 to your computer and use it in GitHub Desktop.
<?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('name');
$table->string('email')->unique();
$table->string('password', 60);
$table->enum('role', ['admin','vendedor','suporte']);
$table->rememberToken();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::drop('users');
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment