Run the migrations.

@return void
359341
public function up()
    {
        Schema::create('common_fields', function (Blueprint $table) {
            $table->increments('id')->comment('ID');
            $table->string('name')->nullable()->comment(hst_lang('hstcms::public.name'));
            $table->string('fieldname')->nullable()->comment();
            $table->string('fieldtype')->nullable()->comment();
            $table->string('relatedtable')->nullable()->comment();
            $table->string('relatedid')->nullable()->comment();
            $table->string('module')->nullable()->comment();
            $table->tinyInteger('ismain', false)->nullable(0)->comment();
            $table->tinyInteger('ismshow', false)->nullable(0)->comment();
            $table->tinyInteger('ismember', false)->nullable(0)->comment();
            $table->tinyInteger('issearch', false)->nullable(0)->comment();
            $table->tinyInteger('vieworder', false)->nullable(0)->comment();
            $table->tinyInteger('disabled', false)->nullable(0)->comment();
            $table->integer('times')->nullable()->comment(hst_lang('hstcms::public.times'));
            $table->text('setting')->nullable()->comment();
            //$table->timestamps();
        });
    }
1130679
public function up()
    {
        Schema::create('crud_notify', function ($table) {
            $table->increments('id');
            $table->string('message');
            $table->integer('target_user_id');
            $table->integer('ttl')->default(0);
            $table->tinyInteger('broadcast')->default(0);
            $table->tinyInteger('delivered')->default(0);
            $table->integer('created_by');
            $table->integer('created_at');
            $table->integer('updated_at');
            $table->integer('delivered_at');
        });
    }
1175017
public function up()
    {
        Schema::create('roles', function (Blueprint $table) {
            $table->increments('id');
            $table->string('uuid', 36);
            $table->string('name', 80);
            $table->string('slug', 45);
            $table->string('description', 120);
            $table->tinyInteger('is_locked')->default(1)->comment('1 = Locked, 2 = Unlocked');
            $table->timestamps();
            $table->charset = 'utf8';
            $table->collation = 'utf8_general_ci';
        });
    }
1049759
public function up()
    {

        Schema::create('users', function (Blueprint $table) {

            $table->bigInteger('id')->primary();
            $table->integer('group_id');
            $table->string('name')->unique();
            $table->string('email')->unique()->nullable();
            $table->boolean('active')->default(true);
            $table->string('character_owner_hash');
            $table->dateTime('last_login')->nullable();
            $table->string('last_login_source')->nullable();
            $table->rememberToken();

            $table->index('group_id');

            $table->timestamps();
        });
    }
155076
public function up()
    {
        Schema::connection($this->connection)->create('provider', function (Blueprint $table) {
            $table->increments('id', true);
            $table->string('firstname');
            $table->string('lastname');
            $table->string('practice_name');
            $table->string('address');
            $table->string('town');
            $table->string('state')->nullable();
            $table->string('country')->nullable();
            $table->string('email')->nullable();
        });
    }
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');
        });
    }
107134
public function up()
    {
        Schema::create(Models::table('abilities'), function (Blueprint $table) {
            $table->increments('id');
            $table->string('name');
            $table->string('title')->nullable();
            $table->integer('entity_id')->unsigned()->nullable();
            $table->string('entity_type')->nullable();
            $table->boolean('only_owned')->default(false);
            $table->json('options')->nullable();
            $table->integer('scope')->nullable()->index();
            $table->timestamps();
        });

        Schema::create(Models::table('roles'), function (Blueprint $table) {
            $table->increments('id');
            $table->string('name');
            $table->string('title')->nullable();
            $table->integer('level')->unsigned()->nullable();
            $table->integer('scope')->nullable()->index();
            $table->timestamps();

            $table->unique(
                ['name', 'scope'],
                'roles_name_unique'
            );
        });

        Schema::create(Models::table('assigned_roles'), function (Blueprint $table) {
            $table->increments('id');
            $table->integer('role_id')->unsigned()->index();
            $table->integer('entity_id')->unsigned();
            $table->string('entity_type');
            $table->integer('restricted_to_id')->unsigned()->nullable();
            $table->string('restricted_to_type')->nullable();
            $table->integer('scope')->nullable()->index();

            $table->index(
                ['entity_id', 'entity_type', 'scope'],
                'assigned_roles_entity_index'
            );

            $table->foreign('role_id')
                  ->references('id')->on(Models::table('roles'))
                  ->onUpdate('cascade')->onDelete('cascade');
        });

        Schema::create(Models::table('permissions'), function (Blueprint $table) {
            $table->increments('id');
            $table->integer('ability_id')->unsigned()->index();
            $table->integer('entity_id')->unsigned()->nullable();
            $table->string('entity_type')->nullable();
            $table->boolean('forbidden')->default(false);
            $table->integer('scope')->nullable()->index();

            $table->index(
                ['entity_id', 'entity_type', 'scope'],
                'permissions_entity_index'
            );

            $table->foreign('ability_id')
                  ->references('id')->on(Models::table('abilities'))
                  ->onUpdate('cascade')->onDelete('cascade');
        });
    }
315831
public function up()
    {

        Schema::create('userattitudes_counters', function (Blueprint $table) {
            $table->string('item_type', 32);
            $table->integer('item_id')->unsigned();
            $table->integer('count')->unsigned()->nullable()->default(null);
        });

    }
1165884
public function up()
    {
        Schema::drop('product_categories');

        Schema::create('categories', function (Blueprint $table) {
        $table->increments('id');
        $table->integer('parent')->unsigned()->nullable();
        $table->integer('position');

        $table->timestamps();
        $table->softDeletes();
      });

        Schema::create('category_translations', function (Blueprint $table) {
            $table->increments('id');
            $table->integer('category_id')->unsigned();
            $table->string('locale')->index();
        $table->string('label', 255);
        $table->string('slug', 255);
            $table->unique(['category_id', 'locale']);
            $table->foreign('category_id')->references('id')->on('categories')->onDelete('cascade');
        });

        Schema::create('category_product', function (Blueprint $table) {
        $table->increments('id');
        $table->integer('category_id')->unsigned();
        $table->integer('product_id')->unsigned();

        // $table->foreign('category_id')->references('category_id')->on('categories')->onDelete('cascade');
        // $table->foreign('product_id')->references('product_id')->on('products')->onDelete('cascade');
    });
    }
678435
public function up()
    {
        $this->createSchema(function (Blueprint $table) {
            $table->bigIncrements('id');
            $table->string('name')->index();
            $table->timestamp('created_at')->index();
            $table->timestamp('updated_at')->index();
        });
    }
1183544
public function up()
    {
        Schema::table('users', function (Blueprint $table) {
            $table->enum('type', array_values(UserType::toArray()))->default(UserType::__default);
            $table->boolean('is_active')->default(true);
            $table->dateTime('last_login_at')->nullable();
            $table->integer('login_count')->unsigned()->nullable()->default(0);
            $table->softDeletes();
        });
    }
877007
public function up()
    {
        Schema::create('config_categories', function (Blueprint $table) {
            $table->increments('id');
            $table->unsignedInteger('parent_id')->nullable();
            $table->unsignedInteger('package_id');
            $table->string('key')->unique();
            $table->timestamps();

            $table->foreign('package_id')->references('id')->on('packages');
            $table->foreign('parent_id')->references('id')->on('config_categories');
        });

        Schema::create('configs', function (Blueprint $table) {
            $table->increments('id');
            $table->unsignedInteger('config_category_id');
            $table->string('key');
            $table->string('value');
            $table->timestamps();

            $table->foreign('config_category_id')->references('id')->on('config_categories');
        });

        $this->config = new Config();
        $this->categories();
    }
287295
public function up()
	{
		Schema::create($this->table, function($t)
		{
			$t->increments('id')->unsigned();
			$t->string('username', 100);
			$t->string('email');

			$t->timestamps();
			$t->softDeletes();

            $t->index('username');
            $t->index(array('deleted_at', 'username'));
        });
    }
1236197
public function up()
    {
        Schema::create('user_role', function (Blueprint $table) {
            $table->bigIncrements('id');

            $table->bigInteger('user_id')->unsigned();
            $table->bigInteger('role_id')->unsigned();

            $table->nullableTimestamps();

            $table->index(['user_id', 'role_id']);
        });
    }
552592
public function up()
    {
        Schema::create(\Config::get('registry.table', 'system_registries'), function(Blueprint $table)
        {
            $table->string('key');
            $table->text('value');

            $table->primary('key');
        });
    }
967651
public function up()
    {
        Schema::table('users', function (Blueprint $table) {
            $table->timestamp('last_login')->nullable();
            $table->jsonb('permissions')->nullable();
        });
    }
578981
public function up()
    {
        Schema::create('tags', function (Blueprint $table) {
            $table->uuid('id')->primary('id');
            $table->uuid('user_id')->index();
            $table->string('text', 64)->index('text');
            $table->timestamps();

            $table->unique(['user_id', 'text']);

            $table->foreign('user_id')->references('id')->on('users');
        });

    }