| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657 |
- <?php
- namespace addons\Achievement\console\migrations;
- use yii\db\Migration;
- /**
- * Class M250524065841CreateQimallAddonsAchievementAwardLogExtra
- */
- class M250524065841CreateQimallAddonsAchievementAwardLogExtra extends Migration
- {
- /**
- * {@inheritdoc}
- */
- public function safeUp()
- {
- $sql = "CREATE TABLE `qimall_addons_achievement_award_log_extra` (
- `id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT 'id',
- `mall_id` int(11) NOT NULL COMMENT '商城id',
- `user_id` int(11) NOT NULL COMMENT '用户id',
- `grant_id` int(11) NOT NULL COMMENT '发放规则日志id',
- `team_achievement` decimal(10,2) NOT NULL COMMENT '团队业绩',
- `created_at` int(11) DEFAULT NULL COMMENT '添加时间',
- `updated_at` int(11) DEFAULT NULL COMMENT '修改时间',
- `equal_first` decimal(10,2) NOT NULL COMMENT '一层平级奖励',
- `equal_second` decimal(10,2) NOT NULL COMMENT '二层平级奖励',
- PRIMARY KEY (`id`)
- ) ENGINE=InnoDB AUTO_INCREMENT=2186 DEFAULT CHARSET=utf8mb4 COMMENT='奖励明细拓展表';";
- $this->execute($sql);
- }
- /**
- * {@inheritdoc}
- */
- public function safeDown()
- {
- echo "M250524065841CreateQimallAddonsAchievementAwardLogExtra cannot be reverted.\n";
- return false;
- }
- /*
- // Use up()/down() to run migration code without a transaction.
- public function up()
- {
- }
- public function down()
- {
- echo "M250524065841CreateQimallAddonsAchievementAwardLogExtra cannot be reverted.\n";
- return false;
- }
- */
- }
|