Run the migrations.

@return void
326030
public function up()
    {
        Schema::create(
            'field_integer',
            function (Blueprint $table) {
                $this->fieldTableFields($table);
                $table->integer('value');
            }
        );

        Schema::create(
            'field_double',
            function (Blueprint $table) {
                $this->fieldTableFields($table);
                $table->double('value');
            }
        );

        Schema::create(
            'field_boolean',
            function (Blueprint $table) {
                $this->fieldTableFields($table);
                $table->boolean('value');
            }
        );
    }
198155
public function up() {
        Schema::create('languages', function (Blueprint $table) {
            $table->increments('id');
            $table->char('slug', 2)->unique();
            $table->string('title', 30);
            $table->tinyInteger('rank')->unsigned()->default(1);
            $table->boolean('active')->default(1);

            $table->index('active');
            $table->index('rank');
        });
    }
819778
public function up()
    {
        Schema::create('authors', function (Blueprint $table) {
            $table->increments('id');
            $table->string('name');
            $table->string('email');
            $table->timestamps();
        });

        Schema::create('books', function (Blueprint $table) {
            $table->increments('id');
            $table->string('title');
            $table->date('published_at')->nullable();
            $table->integer('author_id')->unsigned()->index();
            $table->text('description')->nullable();
            $table->boolean('out_of_print')->default(false);
            $table->timestamps();
        });
    }
409171
public function up()
    {
        Schema::table('changes', function (Blueprint $table) {
            $table->integer('admin_id')->unsigned()->nullable()->change();
        });
        Schema::table('changes', function (Blueprint $table) {
            $table->dropForeign(['admin_id']);
        });
        Schema::table('changes', function (Blueprint $table) {
            $table->foreign('admin_id')
                ->references('id')->on('admins')
                ->onUpdate('cascade')
                ->onDelete('set null');
        });
    }
682410
public function up()
    {
        Schema::create('objects', function (Blueprint $table) {
            $table->engine = 'InnoDB';
            $table->increments('id');
            $table->integer('image_id')->unsigned()->nullable();
            $table->json('status');
            $table->json('title');
            $table->json('slug');
            $table->json('summary');
            $table->json('body');
            $table->timestamps();
        });
    }
640200
public function up()
    {
        Schema::create($this->getLogTable(), function (Blueprint $table) {
            $table->engine="innoDB";
            $table->increments('id');
            $table->unsignedBigInteger('transaction_id'); 
            $table->string('result_code', 10)->nullable();
            $table->string('result_message', 255)->nullable();
            $table->timestamp('log_date')->nullable();

            $table
                ->foreign('transaction_id')
                ->references('id')
                ->on($this->getTable())
                ->onDelete('cascade');
        });
    }
243355
public function up()
    {
        Schema::connection($this->connection)->create('signup_data', function (Blueprint $table) {
            $table->increments('id', true);
            $table->integer('user_id')->unsigned();
            $table->string('firstname');
            $table->string('surname');
            $table->enum('gender', ['male', 'female']);
            $table->string('email')->unique();
            $table->string('mobile_number')->unique();
        });
    }
363552
public function up()
    {
        Schema::create('user_permissions', function (Blueprint $table) {
			$table->char("user_id", 32)->nullable();
			$table->char("permission_id", 32)->nullable();
            $table->timestamps();
        });
    }
1350716
public function up()
    {
        Schema::create('posts', function (Blueprint $table) {
            $table->increments('id');

            $table->string('title');
            $table->string('slug');
            $table->string('category')->nullable();
            $table->text('excerpt')->nullable();
            $table->longText('content')->nullable();
            $table->longText('featured_media')->nullable();
            $table->timestamp('published_at')->nullable();

            $table->integer('author_user_id')->unsigned()->nullable();

            $table->foreign('author_user_id')
                ->references('id')
                ->on('users')
                ->onDelete('cascade')
                ->onUpdate('cascade');

            $table->nullableTimestamps();
            $table->softDeletes();
        });
    }
804004
public function up()
    {

        Schema::table('group_role', function (Blueprint $table) {

            $table->boolean('not')->after('group_id')->default(false);
        });

        Schema::table('permission_role', function (Blueprint $table) {

            $table->boolean('not')->after('role_id')->default(false);
        });

        Schema::table('affiliation_user', function (Blueprint $table) {

            $table->boolean('not')->after('affiliation_id')->default(false);
        });

        Schema::table('affiliation_role', function (Blueprint $table) {

            $table->boolean('not')->after('affiliation_id')->default(false);
        });
    }
552592
public function up()
    {
        Schema::create(\Config::get('registry.table', 'system_registries'), function(Blueprint $table)
        {
            $table->string('key');
            $table->text('value');

            $table->primary('key');
        });
    }
888822
public function up()
    {
    	if (Schema::hasTable('users')) {

    		Schema::table('users', function (Blueprint $table) {
	            
	            if (!Schema::hasColumn('users', 'is_admin')) {

	            	$table->tinyInteger('is_admin')->default(0)->comment('1: admin, 0: not is admin');
	            }

	            if (!Schema::hasColumn('users', 'name')) {
	            	$table->string('name');
	            }
	            
	            if (!Schema::hasColumn('users', 'email')) {
	            	$table->string('email')->unique();
	            }

	            if (!Schema::hasColumn('users', 'password')) {
	            	$table->string('password');
	            }

	            if (!Schema::hasColumn('users', 'remember_token')) {
	            	$table->rememberToken();
	            }


	        });
    	}

    	else {

    		Schema::create('users', function (Blueprint $table) {
	            $table->increments('id');
	            $table->string('name');
	            $table->string('email')->unique();
	            $table->string('password');
	            $table->tinyInteger('is_admin')->default(0)->comment('1: admin, 0: not is admin');
	            $table->rememberToken();
	            $table->timestamps();
	        });
    	}
        
    }
377408
public function up()
    {
        $this->createSchema(function (Blueprint $table) {
            $table->string('email');
            $table->string('token');
            $table->timestamp('created_at')->nullable();

            $table->index(['email', 'token']);
        });
    }
489838
public function up()
    {
        Schema::table('categories', function(Blueprint $table)
        {
            $table->string('slug')->nullable()->index();
        });

        Schema::table('articles', function(Blueprint $table)
        {
            $table->string('slug')->nullable()->index();
        });

        Category::all()->each->touch();
    }
769996
public function up()
    {
        Schema::create('authentication_log', function (Blueprint $table) {
            $table->bigIncrements('id');
            $table->morphs('authenticatable');
            $table->string('ip_address', 45)->nullable();
            $table->text('user_agent')->nullable();
            $table->timestamp('login_at')->nullable();
            $table->timestamp('logout_at')->nullable();
        });
    }
1108754
public function up()
    {
        Schema::create('scaffoldinterfaces', function (Blueprint $table) {
            $table->increments('id')->unsigned();
            $table->String('package');
            $table->String('migration');
            $table->String('model');
            $table->String('controller');
            $table->String('views');
            $table->String('tablename');
            $table->timestamps();
        });
        Schema::create('relations', function (Blueprint $table) {
            $table->increments('id')->unsigned();
            $table->integer('scaffoldinterface_id')->unsigned();
            $table->String('to');
            $table->String('having');
            $table->foreign('scaffoldinterface_id')->references('id')->on('scaffoldinterfaces')->onDelete('cascade');
            $table->timestamps();
        });
    }
1308151
public function up()
    {
        Schema::create('users', function (Blueprint $table) {

            $table->increments('id');
            $table->string('name', 100);
            $table->string('email', 100)->unique();
            $table->string('password');
            $table->string('role', 100)->default('user');

            $table->string('avatar', 100)->nullable();
            $table->text('info')->length(500)->nullable();
            $table->string('where_from')->nullable();
            $table->rememberToken();
            $table->string('api_token', 32)->nullable(); // md5(str_random(16));
            $table->ipAddress('last_ip')->nullable();

            $table->index('name');

            $table->timestamps();
            $table->timestamp('logined_at')->nullable();
        });
    }