| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475 |
- <?php
- namespace addons\Store\console\migrations;
- use yii\db\Migration;
- /**
- * Class M220812090912InsertQimallLinkCategory
- */
- class M220812090912InsertQimallLinkCategory extends Migration
- {
- /**
- * {@inheritdoc}
- */
- public function safeUp()
- {
- }
- /**
- * {@inheritdoc}
- */
- public function safeDown()
- {
- echo "M220812090912InsertQimallLinkCategory cannot be reverted.\n";
- return false;
- }
- // Use up()/down() to run migration code without a transaction.
- public function up()
- {
- $table ='qimall_link_category';
- $this->insert($table, [
- 'name' => 'store',
- 'title' => 'O2O门店',
- 'pid' => 19,
- 'is_list' => 1,
- 'remark' => '',
- 'status' => 1,
- 'created_at' => 1659584481,
- 'updated_at' => 1659584481,
- ]);
- $this->insert($table, [
- 'name' => 'store_cate',
- 'title' => 'O2O门店分类',
- 'pid' => 19,
- 'is_list' => 1,
- 'remark' => '',
- 'status' => 1,
- 'created_at' => 1659584481,
- 'updated_at' => 1659584481,
- ]);
- $this->insert($table, [
- 'name' => 'store_goods',
- 'title' => 'O2O门店商品',
- 'pid' => 19,
- 'is_list' => 1,
- 'remark' => '',
- 'status' => 1,
- 'created_at' => 1659584481,
- 'updated_at' => 1659584481,
- ]);
- }
- public function down()
- {
- echo "M220812090912InsertQimallLinkCategory cannot be reverted.\n";
- return false;
- }
- }
|