| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546 |
- <?php
- namespace app\migrations;
- use yii\db\Migration;
- /**
- * Class M230822094621UserBankAddColumnAddress
- */
- class M230822094621UserBankAddColumnAddress extends Migration
- {
- /**
- * {@inheritdoc}
- */
- public function safeUp()
- {
- $sql = "ALTER TABLE `qimall_user_bank_card` ADD COLUMN `bank_address` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '' COMMENT '开户行地址';";
- $this->execute($sql);
- }
- /**
- * {@inheritdoc}
- */
- public function safeDown()
- {
- echo "M230822094621UserBankAddColumnAddress cannot be reverted.\n";
- return false;
- }
- /*
- // Use up()/down() to run migration code without a transaction.
- public function up()
- {
- }
- public function down()
- {
- echo "M230822094621UserBankAddColumnAddress cannot be reverted.\n";
- return false;
- }
- */
- }
|