createTable( '{{%consent}}', [ 'id' => $this->primaryKey(), 'enable_consent' => $this->integer()->notNull()->defaultValue(0), 'enable_sandbox' => $this->integer()->notNull()->defaultValue(0) ] ); $this->insert( '{{%consent}}', [ 'enable_consent' => 0, 'enable_sandbox' => 0 ] ); Yii::$app->db->schema->refresh(); } public function down() { $this->dropTable('{{%consent}}'); Yii::$app->db->schema->refresh(); } }