| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051 |
- <?php
- namespace addons\Rebate\console\migrations;
- use common\models\common\Addons;
- use yii\db\Migration;
- /**
- * Class M240120165423AlertQimallAddonsRebateBuy
- */
- class M240120165423AlertQimallAddonsRebateBuy extends Migration
- {
- /**
- * {@inheritdoc}
- */
- public function safeUp()
- {
- try {
- $sql="ALTER TABLE `qimall_addons_rebate_buy` ADD COLUMN `reward_id` int(10) NULL DEFAULT 0 COMMENT '对应结算的奖励id';";
- $this->execute($sql);
- } catch (\Exception $e) {
- }
- }
- /**
- * {@inheritdoc}
- */
- public function safeDown()
- {
- echo "M240120165423AlertQimallAddonsRebateBuy cannot be reverted.\n";
- return false;
- }
- /*
- // Use up()/down() to run migration code without a transaction.
- public function up()
- {
- }
- public function down()
- {
- echo "M240120165423AlertQimallAddonsRebateBuy cannot be reverted.\n";
- return false;
- }
- */
- }
|