portal.mkgtu.ru/common/migrations/db/m221122_085651_rename_colum...

21 lines
596 B
PHP
Raw Permalink Normal View History

2024-03-28 09:51:45 +03:00
<?php
use common\components\Migration\MigrationWithDefaultOptions;
use common\modules\abiturient\models\bachelor\AdmissionCampaign;
class m221122_085651_rename_column extends MigrationWithDefaultOptions
{
public function safeUp()
{
if ($this->db->getTableSchema(AdmissionCampaign::tableName())->getColumn('count_target_specs_separately_regardless_of_multiprofile_competition')) {
$this->renameColumn(AdmissionCampaign::tableName(), 'count_target_specs_separately_regardless_of_multiprofile_competition', 'count_target_specs_separately');
}
}
}