| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849 |
- <?php
- namespace addons\Coupon\console\migrations;
- use addons\Coupon\common\models\AddonsCouponUserRelate;
- use yii\db\Migration;
- /**
- * Class M240508222704AlterQimallAddonsCouponUserRelate
- */
- class M240508222704AlterQimallAddonsCouponUserRelate extends Migration
- {
- /**
- * {@inheritdoc}
- */
- public function safeUp()
- {
- $sql="ALTER TABLE qimall_addons_coupon add give_time int(11) not null default 0 COMMENT '转赠次数'";
- $this->execute($sql);
- $sql="ALTER TABLE qimall_addons_coupon_user_relate add give_time int(11) not null default 0 COMMENT '转赠次数'";
- $this->execute($sql);
- }
- /**
- * {@inheritdoc}
- */
- public function safeDown()
- {
- echo "M240508222704AlterQimallAddonsCouponUserRelate cannot be reverted.\n";
- return false;
- }
- /*
- // Use up()/down() to run migration code without a transaction.
- public function up()
- {
- }
- public function down()
- {
- echo "M231212062704AlterQimallAddonsCouponUserRelate cannot be reverted.\n";
- return false;
- }
- */
- }
|