Change Method.

More information on this method is available here:
http://docs.phinx.org/en/latest/migrations.html#the-change-method
@return void
966873
public function change()
    {
        $table = $this->table('saved_searches');
        $table->changeColumn('type', 'string', [
            'default' => null,
            'limit' => 255,
            'null' => true,
        ]);
        $table->update();
    }
581389
public function changename()
    {
        $soxId = $this->getEditObjectId();
        $aParams = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter("editval");

        $this->resetContentCache();

        $oArticle = oxNew(\OxidEsales\Eshop\Application\Model\Article::class);
        if ($soxId != "-1") {
            $oArticle->loadInLang($this->_iEditLang, $soxId);
        }

        $oArticle->setLanguage(0);
        $oArticle->assign($aParams);
        $oArticle->setLanguage($this->_iEditLang);
        $oArticle->save();
    }
1301324
public function up()
    {
        Schema::create('items', function (Blueprint $table) {
            $table->increments('id');
            $table->integer('page_id')->unsigned();
            $table->morphs('element');
            $table->integer('position')->unsigned();
            #$table->integer('proceeding_position')->unsigned();
            $table->string('name')->nullable();
            $table->boolean('proceed')->nullable();
            $table->string('template')->nullable();
            $table->string('cssId')->nullable();
            $table->string('cssClass')->nullable();
            $table->string('validation')->nullable();
            $table->nullableTimestamps();
            #$table->unique(['page_id', 'name']);
        });
    }
1221613
public function change()
    {
        $tableName = 'language_translations';
        if (!$this->hasTable($tableName)) {
            $tableName = 'translations';
        }

        $table = $this->table($tableName);
        if (!$table->hasColumn('is_active')) {
            $table->addColumn('is_active', 'boolean', [
                'default' => 0,
                'null' => false,
            ]);
        }
        $table->update();
    }
688669
public function up()
    {
        Schema::table('email_log', function ($table) {
            if (!Schema::hasColumn('email_log', 'bcc')) {
                $table->string('to')->nullable()->change();
                $table->string('bcc')->after('to')->nullable();
            }
        });
    }
312262
public function up()
    {
        // drop all columns (to add columns and also for column order)
        Schema::table('users', function (Blueprint $table) {
            $table->dropColumn('name');
            $table->dropColumn('email');
            $table->dropColumn('password');
            $table->dropColumn('email_verified_at');
            $table->dropColumn('remember_token');
            $table->dropColumn('created_at');
            $table->dropColumn('updated_at');
        });

        Schema::table('users', function (Blueprint $table) {
            $table->string('firstname')->nullable();
            $table->string('lastname')->nullable();
            $table->string('email', 50)->index()->unique();
            $table->string('cellphone', 50)->nullable();
            $table->string('telephone', 50)->nullable();
            $table->string('image', 50)->nullable();
            $table->string('gender', 10)->nullable();
            $table->date('born_at')->nullable();
            $table->string('password')->nullable();
            $table->rememberToken();
            $table->string('confirmation_token')->nullable();
            $table->timestamp('logged_in_at')->nullable();
            $table->timestamps();
            $table->timestamp('confirmed_at')->nullable();
            $table->timestamp('password_updated_at')->nullable();
            $table->integer('deleted_by')->unsigned()->nullable();
            $table->timestamp('deleted_at')->nullable();
        });
    }
14897
public function change()
    {
        $table = $this->table('link', array('id' => false, 'primary_key' => array('link')));
        $table->addColumn('link', 'string', array('limit' => 100))
              ->addColumn('url', 'string', array('limit' => 500))
              ->addColumn('active', 'boolean')
              ->create();
    }
611017
public function up()
    {
        Schema::table('page_versions', function (Blueprint $table) {
            $table->renameColumn('edited_time', 'created_at');
            $table->renameColumn('edited_by', 'created_by');
        });

        Schema::table('asset_versions', function (Blueprint $table) {
            $table->renameColumn('edited_at', 'created_at');
            $table->renameColumn('edited_by', 'created_by');
        });

        Schema::table('assets', function (Blueprint $table) {
            $table->renameColumn('uploaded_time', 'created_at');
            $table->renameColumn('uploaded_by', 'created_by');
        });

        Schema::table('pages', function (Blueprint $table) {
            $table->renameColumn('created_time', 'created_at');
        });
    }
782525
public function change()
    {
        $tableName = 'language_translations';
        if (!$this->hasTable($tableName)) {
            $tableName = 'translations';
        }
        $table = $this->table($tableName);
        if ($table->hasColumn('is_active')) {
            $table->removeColumn('is_active');
        }
        if ($table->hasColumn('code')) {
            $table->removeColumn('code');
        }
        if ($table->hasColumn('language_id')) {
            $table->changeColumn('language_id', 'string', [
                'limit' => 36,
                'null' => false,
            ]);
        } else {
            $table->addColumn('language_id', 'string', [
                'limit' => 36,
                'null' => false,
            ]);
        }
        $table->save();
    }
962537
public function up()
    {
        Schema::create('changes', function ($table) {
            $table->engine = 'InnoDB';
            $table->increments('id');

            $table->string('model');
            $table->string('key');
            $table->string('action');
            $table->string('title')->nullable();
            $table->longText('changed')->nullable();

            $table->integer('admin_id')->unsigned();
            $table->longText('meta')->nullable();
            $table->boolean('deleted')->nullable();
            $table->timestamps();

            $table->index(['model', 'key']);
            $table->index(['key', 'model']);
            $table->index(['action', 'created_at']);
            $table->index(['created_at', 'action']);
            $table->index(['deleted', 'created_at']);
            $table->foreign('admin_id')->references('id')->on('admins')->onUpdate('cascade')->onDelete('cascade');
        });
    }
692372
public function change()
    {
        $rolePermissionTable = $this->table('role_permission', ['signed' => false]);

        $rolePermissionTable->addColumn('role_id', 'integer', ['signed' => false])
            ->addColumn('permission_id', 'integer', ['signed' => false])
            ->addColumn('created_at', 'datetime')
            ->addIndex(['role_id', 'permission_id'], ['name' => 'idx_role_permission_unique', 'unique' => true])
            ->addForeignKey('role_id', 'role', 'id', ['delete' => 'RESTRICT', 'constraint' => 'fk_role_permission_role'])
            ->addForeignKey('permission_id', 'permission', 'id', ['delete' => 'RESTRICT', 'constraint' => 'fk_role_permission_permission'])
            ->create();
    }
451658
public function change() {
		$table = $this->table('queued_tasks');

		$table->changeColumn('status', 'string', [
		    'length' => 255,
			'null' => true,
			'default' => null,
		]);

		$table->save();
	}
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');
        });
    }
852240
public function up()
    {
        if (Schema::hasTable('users')) {
            // Add remember_token column to existing table
            if (! Schema::hasColumn('users', 'remember_token')) {
                Schema::table('users', function($table) {
                    $table->rememberToken();
                });
            }
            
        }
    }
42145
public function change()
    {
        $table = $this->table('notices');
        $table->addColumn('author', 'string', array('limit' => 16))
              ->addColumn('text', 'integer')
              ->addColumn('start_time', 'datetime')
              ->addColumn('end_time', 'datetime')
              ->addColumn('hidden', 'boolean', array('null' => false, 'default' => 0))
              ->addColumn('frontpage', 'boolean', array('null' => false, 'default' => 1))
              ->addColumn('sort_order', 'integer')
              ->create();

        $table->addForeignKey('text', 'text_story', 'id', array('delete'=> 'CASCADE', 'update'=> 'CASCADE'))
              ->addForeignKey('author', 'user', 'user', array('delete'=> 'CASCADE', 'update'=> 'CASCADE'))
              ->save();

    }
116752
public function up()
    {
        Schema::table('users', function(Blueprint $table) {
            $table->renameColumn('name', 'username');
            $table->boolean('confirmed')->default(0);
            $table->string('confirmation_code')->nullable();
        });
    }
1107875
public function up()
    {
        $table = $this->table('users');

        if (!$table->hasColumn('firstname')) {
            $table->addColumn('firstname', 'string', ['limit' => 255, 'null' => true, 'default' => null, 'after' => 'language_id']);
        }

        if (!$table->hasColumn('lastname')) {
            $table->addColumn('lastname', 'string', ['limit' => 255, 'null' => true, 'default' => null, 'after' => 'firstname']);
        }

        $table->update();

        $this->clearModelCache();
    }