| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
- <?php
- namespace addons\Store\console\migrations;
- use yii\db\Migration;
- /**
- * Class M250108104255AddMallAttrIdToStoreGoodsAttr
- */
- class M250108104255AddMallAttrIdToStoreGoodsAttr extends Migration
- {
- /**
- * {@inheritdoc}
- */
- public function safeUp()
- {
- $sql = <<<SQL
- ALTER TABLE `qimall_addons_store_goods_attr` ADD COLUMN `mall_attr_id` INT ( 11 ) NOT NULL DEFAULT '0' COMMENT '商城规格id';
- SQL;
- $this->execute($sql);
- }
- /**
- * {@inheritdoc}
- */
- public function safeDown()
- {
- echo "M250108104255AddMallAttrIdToStoreGoodsAttr cannot be reverted.\n";
- return false;
- }
- /*
- // Use up()/down() to run migration code without a transaction.
- public function up()
- {
- }
- public function down()
- {
- echo "M250108104255AddMallAttrIdToStoreGoodsAttr cannot be reverted.\n";
- return false;
- }
- */
- }
|