1
0
Fork 0
mirror of https://github.com/janickiy/yii2-nomer synced 2025-03-09 15:39:59 +00:00
yii2-nomer/migrations/m170906_141917_add_status_to_wallets.php
2020-02-05 06:34:26 +03:00

31 lines
616 B
PHP

<?php
use yii\db\Migration;
class m170906_141917_add_status_to_wallets extends Migration
{
public function safeUp()
{
$this->addColumn(\app\models\Wallet::tableName(), "status", $this->boolean()->defaultValue(true));
}
public function safeDown()
{
$this->dropColumn(\app\models\Wallet::tableName(), "status");
}
/*
// Use up()/down() to run migration code without a transaction.
public function up()
{
}
public function down()
{
echo "m170906_141917_add_status_to_wallets cannot be reverted.\n";
return false;
}
*/
}