php-censor/src/PHPCI/Migrations/20150203105015_fix_column_types.php
Dmitry Khomutov ca2f5ed197 Fixes
2016-06-23 21:26:13 +06:00

28 lines
696 B
PHP

<?php
use Phinx\Migration\AbstractMigration;
use Phinx\Db\Adapter\MysqlAdapter;
class FixColumnTypes extends AbstractMigration
{
/**
* Migrate Up.
*/
public function up()
{
// Update the build log column to MEDIUMTEXT:
$build = $this->table('build');
$build->changeColumn('log', 'text', [
'null' => true,
'limit' => MysqlAdapter::TEXT_MEDIUM,
]);
// Update the build meta value column to MEDIUMTEXT:
$buildMeta = $this->table('build_meta');
$buildMeta->changeColumn('meta_value', 'text', [
'null' => false,
'limit' => MysqlAdapter::TEXT_MEDIUM,
]);
}
}