begin; alter table user add column `sign_sum` int(11) NOT NULL DEFAULT '0' COMMENT '签到总天数'; alter table user add column `box_num` int(11) NOT NULL DEFAULT '0' COMMENT '空投宝箱数量'; CREATE TABLE `activity` ( `idx` int(11) NOT NULL AUTO_INCREMENT COMMENT '自增id', `accountid` varchar(60) NOT NULL DEFAULT '' COMMENT '账号id', `free_times` int(11) NOT NULL DEFAULT '0' COMMENT '免费抽奖次数', `video_times` int(11) NOT NULL DEFAULT '0' COMMENT '视频抽奖次数', `item_id` int(11) NOT NULL DEFAULT '0' COMMENT '物品id', `item_num` int(11) NOT NULL DEFAULT '0' COMMENT '物品数量', `create_time` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间', `modify_time` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间', PRIMARY KEY (`idx`), UNIQUE KEY `accountid` (`accountid`) ) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin; DROP TABLE IF EXISTS `sign`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `sign` ( `idx` int(11) NOT NULL AUTO_INCREMENT COMMENT '自增id', `accountid` varchar(60) NOT NULL DEFAULT '' COMMENT '账号id', `sign_id` int(11) NOT NULL DEFAULT '0' COMMENT '补签id', `signable` int(11) NOT NULL DEFAULT '0' COMMENT '是否签到', `create_time` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间', `modify_time` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间', `sign_time` int(11) NOT NULL DEFAULT '0' COMMENT '签到时间', PRIMARY KEY (`idx`), UNIQUE KEY `account_sign_id` (`accountid`, `sign_id`) ) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin; DELETE FROM share_achievement WHERE 1=1; commit;