| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
- <?php
- namespace addons\ElectronCoupon\console\migrations;
- use addons\ElectronCoupon\common\models\ElectronCouponCode;
- use yii\db\Migration;
- /**
- * Class M240307014153UpdateQimallAddonsElectronCouponCode
- */
- class M240307014153UpdateQimallAddonsElectronCouponCode extends Migration
- {
- /**
- * {@inheritdoc}
- */
- public function safeUp()
- {
- return true;
- ElectronCouponCode::updateCode();
- ElectronCouponCode::updateOldData();
- }
- /**
- * {@inheritdoc}
- */
- public function safeDown()
- {
- echo "M240307014153UpdateQimallAddonsElectronCouponCode cannot be reverted.\n";
- return false;
- }
- /*
- // Use up()/down() to run migration code without a transaction.
- public function up()
- {
- }
- public function down()
- {
- echo "M240307014153UpdateQimallAddonsElectronCouponCode cannot be reverted.\n";
- return false;
- }
- */
- }
|