for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
use Phpmig\Migration\Migration;
use Illuminate\Database\Capsule\Manager as Capsule;
class UsersMigration extends Migration
{
/**
* Do the migration
*/
public function up()
Capsule::schema()->create('users', function($table)
$table->increments('id');
$table->string('first_name');
$table->string('last_name');
$table->string('username')->unique()->nullable();
$table->string('mobile')->unique();
$table->string('email')->unique()->nullable();
$table->string('api_token');
$table->rememberToken();
$table->timestamps();
});
}
* Undo the migration
public function down()
Capsule::schema()->drop('users');