game2006api/sql/marketdb.sql
2023-07-10 20:01:15 +08:00

619 lines
30 KiB
SQL
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

-- MySQL dump 10.14 Distrib 5.5.41-MariaDB, for Linux (x86_64)
--
-- Host: localhost Database: marketdb
-- ------------------------------------------------------
-- Server version 5.5.41-MariaDB
--
-- Table structure for table `version`
--
DROP TABLE IF EXISTS `version`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `version` (
`idx` int(11) NOT NULL AUTO_INCREMENT COMMENT '自增id',
`version` int(11) NOT NULL DEFAULT '0' COMMENT '版本号',
PRIMARY KEY (`idx`),
UNIQUE KEY `version` (`version`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_parameter`
--
DROP TABLE IF EXISTS `t_parameter`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_parameter` (
`idx` int(11) NOT NULL AUTO_INCREMENT COMMENT '自增id',
`name` varchar(255) NOT NULL DEFAULT '' COMMENT 'name',
`value` mediumblob COMMENT 'value',
PRIMARY KEY (`idx`),
UNIQUE KEY `name` (`name`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_box_order`
--
DROP TABLE IF EXISTS `t_box_order`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_box_order` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`game_id` int(11) NOT NULL DEFAULT '0' COMMENT 'game id',
`func_id` int(11) NOT NULL DEFAULT '0' COMMENT 'func_id 1:预售 2:商店',
`batch_idx` int(11) NOT NULL DEFAULT '0' COMMENT '批次号idx',
`order_id` varchar(60) NOT NULL DEFAULT '' COMMENT '订单id',
`type` varchar(60) NOT NULL DEFAULT '' COMMENT 'type',
`buyer_address` varchar(60) NOT NULL DEFAULT '' COMMENT '购买者',
`raw_buyer_address` varchar(60) NOT NULL DEFAULT '' COMMENT 'raw购买者',
`price` varchar(60) NOT NULL DEFAULT '' COMMENT 'price',
`payment_token_address` varchar(60) NOT NULL DEFAULT '' COMMENT '货币地址',
`nonce` varchar(60) NOT NULL DEFAULT '' COMMENT 'nonce',
`signature` varchar(255) NOT NULL DEFAULT '' COMMENT '签名',
`net_id` varchar(60) NOT NULL DEFAULT '' COMMENT 'net_id',
`bc_pay_txhash` varchar(255) NOT NULL DEFAULT '' COMMENT 'bc_pay_txhash',
`bc_paid` int(11) NOT NULL DEFAULT '0' COMMENT '是否已支付',
`bc_pay_count` int(11) NOT NULL DEFAULT '0' COMMENT '支付次数',
`bc_pay_time` int(11) NOT NULL DEFAULT '0' COMMENT '本节点最后一次支付时间',
`bc_pay_prepare_block_number` varchar(60) NOT NULL DEFAULT '' COMMENT '支付准备前块id',
`bc_pay_success_block_number` varchar(60) NOT NULL DEFAULT '' COMMENT '支付成功块id',
`bc_pay_confirm_time` int(11) NOT NULL DEFAULT '0' COMMENT '支付成功被确认时间',
`bc_minted1` int(11) NOT NULL DEFAULT '0' COMMENT 'nft是否已创建',
`bc_mint_txhash1` varchar(255) NOT NULL DEFAULT '' COMMENT 'bc_mint_txhash',
`bc_mint_tokenid1` varchar(60) NOT NULL DEFAULT '' COMMENT 'token_id',
`bc_mint_need1` int(11) NOT NULL DEFAULT '0' COMMENT 'need',
`bc_mint_itemid1` int(11) NOT NULL DEFAULT '0' COMMENT '道具id',
`bc_mint_token_type1` int(11) NOT NULL DEFAULT '0' COMMENT 'nft类型 1:英雄 2:枪支 3:芯片',
`bc_mint_tags1` varchar(60) NOT NULL DEFAULT '' COMMENT 'tags',
`bc_mint_count1` int(11) NOT NULL DEFAULT '0' COMMENT '生成nft次数',
`bc_mint_time1` int(11) NOT NULL DEFAULT '0' COMMENT '最后一次生成nft时间',
`bc_mint_prepare_block_number1` varchar(60) NOT NULL DEFAULT '' COMMENT 'nft生成准备前块id',
`bc_mint_success_block_number1` varchar(60) NOT NULL DEFAULT '' COMMENT 'nft生成成功块id',
`bc_mint_confirm_time1` int(11) NOT NULL DEFAULT '0' COMMENT 'nft生成被确认时间',
`bc_minted2` int(11) NOT NULL DEFAULT '0' COMMENT 'nft是否已创建',
`bc_mint_txhash2` varchar(255) NOT NULL DEFAULT '' COMMENT 'bc_mint_txhash',
`bc_mint_tokenid2` varchar(60) NOT NULL DEFAULT '' COMMENT 'token_id',
`bc_mint_need2` int(11) NOT NULL DEFAULT '0' COMMENT 'need',
`bc_mint_itemid2` int(11) NOT NULL DEFAULT '0' COMMENT '道具id',
`bc_mint_token_type2` int(11) NOT NULL DEFAULT '0' COMMENT 'nft类型 1:英雄 2:枪支 3:芯片',
`bc_mint_tags2` varchar(60) NOT NULL DEFAULT '' COMMENT 'tags',
`bc_mint_count2` int(11) NOT NULL DEFAULT '0' COMMENT '生成nft次数',
`bc_mint_time2` int(11) NOT NULL DEFAULT '0' COMMENT '最后一次生成nft时间',
`bc_mint_prepare_block_number2` varchar(60) NOT NULL DEFAULT '' COMMENT 'nft生成准备前块id',
`bc_mint_success_block_number2` varchar(60) NOT NULL DEFAULT '' COMMENT 'nft生成成功块id',
`bc_mint_confirm_time2` int(11) NOT NULL DEFAULT '0' COMMENT 'nft生成被确认时间',
`bc_minted3` int(11) NOT NULL DEFAULT '0' COMMENT 'nft是否已创建',
`bc_mint_txhash3` varchar(255) NOT NULL DEFAULT '' COMMENT 'bc_mint_txhash',
`bc_mint_tokenid3` varchar(60) NOT NULL DEFAULT '' COMMENT 'token_id',
`bc_mint_need3` int(11) NOT NULL DEFAULT '0' COMMENT 'need',
`bc_mint_itemid3` int(11) NOT NULL DEFAULT '0' COMMENT '道具id',
`bc_mint_token_type3` int(11) NOT NULL DEFAULT '0' COMMENT 'nft类型 1:英雄 2:枪支 3:芯片',
`bc_mint_tags3` varchar(60) NOT NULL DEFAULT '' COMMENT 'tags',
`bc_mint_count3` int(11) NOT NULL DEFAULT '0' COMMENT '生成nft次数',
`bc_mint_time3` int(11) NOT NULL DEFAULT '0' COMMENT '最后一次生成nft时间',
`bc_mint_prepare_block_number3` varchar(60) NOT NULL DEFAULT '' COMMENT 'nft生成准备前块id',
`bc_mint_success_block_number3` varchar(60) NOT NULL DEFAULT '' COMMENT 'nft生成成功块id',
`bc_mint_confirm_time3` int(11) NOT NULL DEFAULT '0' COMMENT 'nft生成被确认时间',
`suspend` int(11) NOT NULL DEFAULT '0' COMMENT '挂起',
`suspend_reason` mediumblob COMMENT '挂起原因',
`done` int(11) NOT NULL DEFAULT '0' COMMENT '是否已完成',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
UNIQUE KEY `order_id` (`order_id`),
UNIQUE KEY `signature` (`signature`),
KEY `batch_idx` (`batch_idx`),
KEY `bc_paid` (`bc_paid`),
KEY `done` (`done`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_mint`
--
DROP TABLE IF EXISTS `t_mint`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_mint` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`unikey` varchar(60) COMMENT 'unikey',
`account` varchar(60) NOT NULL DEFAULT '' COMMENT 'account',
`game_id` int(11) NOT NULL DEFAULT '0' COMMENT 'game id',
`ignore` int(11) NOT NULL DEFAULT '0' COMMENT '忽略',
`bc_minted` int(11) NOT NULL DEFAULT '0' COMMENT 'nft是否已创建',
`bc_mint_txhash` varchar(255) NOT NULL DEFAULT '' COMMENT 'bc_mint_txhash',
`bc_mint_itemid` int(11) NOT NULL DEFAULT '0' COMMENT '道具id',
`bc_mint_tokenid` varchar(60) NOT NULL DEFAULT '' COMMENT 'token_id',
`bc_mint_token_type` int(11) NOT NULL DEFAULT '0' COMMENT 'nft类型 1:英雄 2:枪支 3:芯片',
`bc_mint_tags` varchar(60) NOT NULL DEFAULT '' COMMENT 'tags',
`bc_mint_count` int(11) NOT NULL DEFAULT '0' COMMENT '生成nft次数',
`bc_mint_time` int(11) NOT NULL DEFAULT '0' COMMENT '最后一次生成nft时间',
`bc_mint_prepare_block_number` varchar(60) NOT NULL DEFAULT '' COMMENT 'nft生成准备前块id',
`bc_mint_success_block_number` varchar(60) NOT NULL DEFAULT '' COMMENT 'nft生成成功块id',
`bc_mint_confirm_time` int(11) NOT NULL DEFAULT '0' COMMENT 'nft生成被确认时间',
`suspend` int(11) NOT NULL DEFAULT '0' COMMENT '挂起',
`suspend_reason` mediumblob COMMENT '挂起原因',
`done` int(11) NOT NULL DEFAULT '0' COMMENT '是否已完成',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
UNIQUE KEY `unikey` (`unikey`),
UNIQUE KEY `bc_mint_tokenid` (`bc_mint_tokenid`),
KEY `account` (`account`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_nft`
--
DROP TABLE IF EXISTS `t_nft`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_nft` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`owner_address` varchar(60) NOT NULL DEFAULT '' COMMENT 'owner_address',
`creator_address` varchar(60) NOT NULL DEFAULT '' COMMENT 'creator_address',
`token_id` varchar(60) NOT NULL DEFAULT '' COMMENT 'token_id',
`token_type` int(11) NOT NULL DEFAULT '0' COMMENT 'nft类型 1:英雄 2:枪支 3:芯片 6:荣誉',
`token_state` int(11) NOT NULL DEFAULT '0' COMMENT '0:正常状态 1:出售中 2:出租中',
`game_id` int(11) NOT NULL DEFAULT '0' COMMENT 'game id',
`item_id` int(11) NOT NULL DEFAULT '0' COMMENT '道具id',
`deleted` int(11) NOT NULL DEFAULT '0' COMMENT 'deleted',
`opened` int(11) NOT NULL DEFAULT '0' COMMENT 'opened',
`confirm_count` int(11) NOT NULL DEFAULT '0' COMMENT 'confirm_count',
`confirm_block_number` bigint NOT NULL DEFAULT '0' COMMENT 'confirm_block_number',
`rand_attr` mediumblob COMMENT '随机属性',
`tags` varchar(60) NOT NULL DEFAULT '' COMMENT 'tags',
`param1` int(11) NOT NULL DEFAULT '0' COMMENT 'param1',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
UNIQUE KEY `token_id` (`token_id`),
KEY `owner_address_token_type` (`owner_address`, `token_type`),
KEY `owner_address` (`owner_address`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_nft1155`
--
DROP TABLE IF EXISTS `t_nft1155`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_nft1155` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`owner_address` varchar(60) NOT NULL DEFAULT '' COMMENT 'owner_address',
`token_id` varchar(60) NOT NULL DEFAULT '' COMMENT 'token_id',
`item_id` int(11) NOT NULL DEFAULT '0' COMMENT '道具id',
`balance` bigint NOT NULL DEFAULT '0' COMMENT '余额',
`item_uniid` bigint NOT NULL DEFAULT '0' COMMENT 'item_uniid',
`confirm_count` int(11) NOT NULL DEFAULT '0' COMMENT 'confirm_count',
`confirm_block_number` bigint NOT NULL DEFAULT '0' COMMENT 'confirm_block_number',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
UNIQUE KEY `owner_address_token_id` (`owner_address`, `token_id`),
KEY `owner_address` (`owner_address`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_lucky_box`
--
DROP TABLE IF EXISTS `t_lucky_box`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_lucky_box` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`box_token_id` varchar(60) NOT NULL DEFAULT '' COMMENT 'box_token_id',
`account` varchar(60) NOT NULL DEFAULT '' COMMENT 'account',
`token_id1` varchar(60) NOT NULL DEFAULT '' COMMENT 'token_id1',
`token_id2` varchar(60) NOT NULL DEFAULT '' COMMENT 'token_id2',
`token_id3` varchar(60) NOT NULL DEFAULT '' COMMENT 'token_id3',
`token_type1` int(11) NOT NULL DEFAULT '0' COMMENT 'token_type1',
`token_type2` int(11) NOT NULL DEFAULT '0' COMMENT 'token_type2',
`token_type3` int(11) NOT NULL DEFAULT '0' COMMENT 'token_type3',
`nonce` varchar(60) NOT NULL DEFAULT '' COMMENT 'nonce',
`signature` varchar(255) NOT NULL DEFAULT '' COMMENT '签名',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
UNIQUE KEY `box_token_id` (`box_token_id`),
UNIQUE KEY `token_id1` (`token_id1`),
UNIQUE KEY `token_id2` (`token_id2`),
UNIQUE KEY `token_id3` (`token_id3`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_activate_nft`
--
DROP TABLE IF EXISTS `t_activate_nft`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_activate_nft` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`account` varchar(60) NOT NULL DEFAULT '' COMMENT 'account',
`old_token_id` varchar(60) NOT NULL DEFAULT '' COMMENT 'box_token_id',
`old_token_type` varchar(60) NOT NULL DEFAULT '' COMMENT 'old_token_type',
`new_token_id` varchar(60) NOT NULL DEFAULT '' COMMENT 'new_token_id',
`nonce` varchar(60) NOT NULL DEFAULT '' COMMENT 'nonce',
`signature` varchar(255) NOT NULL DEFAULT '' COMMENT '签名',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
UNIQUE KEY `old_token_id` (`old_token_id`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_activate_event`
--
DROP TABLE IF EXISTS `t_activate_event`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_activate_event` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`old_token_id` varchar(60) NOT NULL DEFAULT '' COMMENT 'old_token_id',
`new_token_id` varchar(60) NOT NULL DEFAULT '' COMMENT 'new_token_id',
`old_token_type` int(11) NOT NULL DEFAULT '0' COMMENT 'old_token_type',
`txhash` varchar(255) NOT NULL DEFAULT '' COMMENT 'txhash',
`block_number` bigint NOT NULL DEFAULT '0' COMMENT 'block_number',
`log_index` bigint NOT NULL DEFAULT '0' COMMENT 'log_index',
`_to` varchar(60) NOT NULL DEFAULT '' COMMENT '_to',
`raw_data` mediumblob COMMENT 'raw_data',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
KEY `old_token_id` (`old_token_id`),
KEY `new_token_id` (`new_token_id`),
KEY `txhash` (`txhash`),
KEY `block_number` (`block_number`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_boxopened_event`
--
DROP TABLE IF EXISTS `t_boxopened_event`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_boxopened_event` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`box_token_id` varchar(60) NOT NULL DEFAULT '' COMMENT 'box_token_id',
`txhash` varchar(255) NOT NULL DEFAULT '' COMMENT 'txhash',
`block_number` bigint NOT NULL DEFAULT '0' COMMENT 'block_number',
`log_index` bigint NOT NULL DEFAULT '0' COMMENT 'log_index',
`_to` varchar(60) NOT NULL DEFAULT '' COMMENT '_to',
`token_id1` varchar(60) NOT NULL DEFAULT '' COMMENT 'token_id1',
`token_id2` varchar(60) NOT NULL DEFAULT '' COMMENT 'token_id2',
`token_id3` varchar(60) NOT NULL DEFAULT '' COMMENT 'token_id3',
`token_type1` int(11) NOT NULL DEFAULT '0' COMMENT 'token_type1',
`token_type2` int(11) NOT NULL DEFAULT '0' COMMENT 'token_type2',
`token_type3` int(11) NOT NULL DEFAULT '0' COMMENT 'token_type3',
`raw_data` mediumblob COMMENT 'raw_data',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
KEY `box_token_id` (`box_token_id`),
KEY `token_id1` (`token_id1`),
KEY `token_id2` (`token_id2`),
KEY `token_id3` (`token_id3`),
KEY `txhash` (`txhash`),
KEY `block_number` (`block_number`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_nft_transfer`
--
DROP TABLE IF EXISTS `t_nft_transfer`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_nft_transfer` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`token_id` varchar(60) NOT NULL DEFAULT '' COMMENT 'token_id',
`txhash` varchar(255) NOT NULL DEFAULT '' COMMENT 'txhash',
`block_number` bigint NOT NULL DEFAULT '0' COMMENT 'block_number',
`log_index` bigint NOT NULL DEFAULT '0' COMMENT 'log_index',
`_from` varchar(60) NOT NULL DEFAULT '' COMMENT '_from',
`_to` varchar(60) NOT NULL DEFAULT '' COMMENT '_to',
`raw_data` mediumblob COMMENT 'raw_data',
`owner_confirmed` int(11) NOT NULL DEFAULT '0' COMMENT 'owner_confirmed',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
UNIQUE KEY `txhash_log_index` (`txhash`, `log_index`),
KEY `token_id` (`token_id`),
KEY `_from` (`_from`),
KEY `_to` (`_to`),
KEY `txhash` (`txhash`),
KEY `block_number` (`block_number`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_nft1155_transfer`
--
DROP TABLE IF EXISTS `t_nft1155_transfer`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_nft1155_transfer` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`event_name` varchar(255) NOT NULL DEFAULT '' COMMENT 'event_name',
`instance_name` varchar(255) NOT NULL DEFAULT '' COMMENT 'instance_name',
`txhash` varchar(255) NOT NULL DEFAULT '' COMMENT 'txhash',
`block_number` bigint NOT NULL DEFAULT '0' COMMENT 'block_number',
`log_index` bigint NOT NULL DEFAULT '0' COMMENT 'log_index',
`_from` varchar(60) NOT NULL DEFAULT '' COMMENT '_from',
`_to` varchar(60) NOT NULL DEFAULT '' COMMENT '_to',
`return_values` mediumblob COMMENT 'return_values',
`raw_data` mediumblob COMMENT 'raw_data',
`owner_confirmed` int(11) NOT NULL DEFAULT '0' COMMENT 'owner_confirmed',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
UNIQUE KEY `txhash_log_index` (`txhash`, `log_index`),
KEY `_from` (`_from`),
KEY `_to` (`_to`),
KEY `txhash` (`txhash`),
KEY `block_number` (`block_number`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_buy_record`
--
DROP TABLE IF EXISTS `t_buy_record`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_buy_record` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`blobdata` mediumblob COMMENT 'blobdata',
`buyer_address` mediumblob COMMENT 'buyer_address',
`order_id` varchar(60) COMMENT '订单id',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
KEY `order_id` (`order_id`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_block_number`
--
DROP TABLE IF EXISTS `t_block_number`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_block_number` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`block_number` varchar(60) NOT NULL DEFAULT '' COMMENT '块id',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_withdrawal`
--
DROP TABLE IF EXISTS `t_withdrawal`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_withdrawal` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`account` varchar(255) NOT NULL DEFAULT '' COMMENT 'account',
`type` int(11) NOT NULL DEFAULT '0' COMMENT '货币类型 1:金币 2钻石',
`net_id` int(11) NOT NULL DEFAULT '0' COMMENT 'net_id',
`amount` varchar(100) NOT NULL DEFAULT '' COMMENT 'amount',
`state` int(11) NOT NULL DEFAULT '0' COMMENT 'state 0:等待上链 1:上链中2:上链成功 3:提现失败',
`bc_block_number` varchar(60) NOT NULL DEFAULT '' COMMENT '支付准备前块id',
`bc_txhash` varchar(255) COMMENT 'bc_txhash',
`bc_time` int(11) NOT NULL DEFAULT '0' COMMENT '本节点最后一次支付时间',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
UNIQUE KEY `bc_txhash` (`bc_txhash`),
KEY `account` (`account`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_transfer`
--
DROP TABLE IF EXISTS `t_transfer`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_transfer` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`txhash` varchar(255) NOT NULL DEFAULT '' COMMENT 'txhash',
`block_number` varchar(60) NOT NULL DEFAULT '' COMMENT '块id',
`type` int(11) NOT NULL DEFAULT '0' COMMENT 'type',
`_from` varchar(255) NOT NULL DEFAULT '' COMMENT '_from',
`_to` varchar(255) NOT NULL DEFAULT '' COMMENT '_to',
`value` varchar(255) NOT NULL DEFAULT '' COMMENT 'value',
`state` int(11) NOT NULL DEFAULT '0' COMMENT '0:未同步 1:同步成功 2:失败',
`reason` mediumblob COMMENT 'reason',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
UNIQUE KEY `txhash` (`txhash`),
KEY `_from` (`_from`),
KEY `_to` (`_to`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_user_wallet_offline_temp`
--
DROP TABLE IF EXISTS `t_user_wallet_offline_temp`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_user_wallet_offline_temp` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`account_id` varchar(60) NOT NULL DEFAULT '' COMMENT '账号id(channel + "_" + gameid + "_" + openid)',
`gold` bigint NOT NULL DEFAULT '0' COMMENT '金币',
`diamond` bigint NOT NULL DEFAULT '0' COMMENT '钻石',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
UNIQUE KEY `account_id` (`account_id`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_transaction`
--
DROP TABLE IF EXISTS `t_transaction`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_transaction` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`account` varchar(60) NOT NULL DEFAULT '' COMMENT '账号id(channel + "_" + gameid + "_" + openid)',
`trans_id` varchar(255) COMMENT '事务id',
`data` mediumblob COMMENT 'data',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
UNIQUE KEY `trans_id` (`trans_id`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_chip_plugin`
--
DROP TABLE IF EXISTS `t_chip_plugin`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_chip_plugin` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`token_id` varchar(60) NOT NULL DEFAULT '' COMMENT 'token_id',
`chip1` varchar(60) NOT NULL DEFAULT '' COMMENT 'chip1',
`chip2` varchar(60) NOT NULL DEFAULT '' COMMENT 'chip2',
`chip3` varchar(60) NOT NULL DEFAULT '' COMMENT 'chip3',
`chip4` varchar(60) NOT NULL DEFAULT '' COMMENT 'chip4',
`confirm_count` int(11) NOT NULL DEFAULT '0' COMMENT 'confirm_count',
`confirm_block_number` bigint NOT NULL DEFAULT '0' COMMENT 'confirm_block_number',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
UNIQUE KEY `token_id` (`token_id`),
KEY `chip1` (`chip1`),
KEY `chip2` (`chip2`),
KEY `chip3` (`chip3`),
KEY `chip4` (`chip4`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_blockchain_event`
--
DROP TABLE IF EXISTS `t_blockchain_event`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_blockchain_event` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`instance_name` varchar(60) NOT NULL DEFAULT '' COMMENT 'instance_name',
`event_name` varchar(60) NOT NULL DEFAULT '' COMMENT 'event_name',
`txhash` varchar(255) NOT NULL DEFAULT '' COMMENT 'txhash',
`log_index` bigint NOT NULL DEFAULT '0' COMMENT 'log_index',
`block_number` bigint NOT NULL DEFAULT '0' COMMENT 'block_number',
`raw_data` mediumblob COMMENT 'raw_data',
`return_values` mediumblob COMMENT 'return_values',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`),
KEY `instance_name` (`instance_name`),
KEY `event_name` (`event_name`),
KEY `txhash` (`txhash`),
KEY `txhash_log_index` (`txhash`, `log_index`),
KEY `block_number` (`block_number`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `t_log`
--
DROP TABLE IF EXISTS `t_log`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `t_log` (
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
`type` varchar(255) NOT NULL DEFAULT '' COMMENT '日志类型',
`subtype` varchar(255) NOT NULL DEFAULT '' COMMENT '日志子类型',
`param1` mediumblob COMMENT 'param1',
`param2` mediumblob COMMENT 'param2',
`param3` mediumblob COMMENT 'param3',
`param4` mediumblob COMMENT 'param4',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
PRIMARY KEY (`idx`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
/*!40101 SET character_set_client = @saved_cs_client */;
-- Dump completed on 2015-08-19 18:51:22
DROP TABLE IF EXISTS `t_market_store`;
CREATE TABLE `t_market_store` (
`idx` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '自增id',
`o_link` varchar(64) DEFAULT NULL COMMENT '关联的链上上架单号',
`status` int(11) NOT NULL COMMENT '订单状态 0:出售中 1:已下架 2:已售出',
`owner_address` varchar(60) NOT NULL COMMENT '当前拥有者',
`token_id` varchar(80) DEFAULT NULL COMMENT 'token_id',
`nft_token` varchar(64) DEFAULT NULL COMMENT 'nftToken',
`token_type` int(11) NOT NULL COMMENT 'nft类型 1:英雄 2:枪支 3:芯片',
`item_id` int(11) DEFAULT NULL COMMENT '特殊字段,用于标记中心化道具,用于交易金币',
`amount` int(11) NOT NULL DEFAULT '1' COMMENT '堆叠数量',
`createtime` int(11) NOT NULL COMMENT '创建时间(上架时间)',
`modifytime` int(11) NOT NULL COMMENT '修改时间(更新价格等)',
`s_currency` varchar(255) NOT NULL COMMENT '出售时选择的币种地址',
`s_price` varchar(64) NOT NULL COMMENT '出售价格',
`c_name` varchar(32) NOT NULL COMMENT '缓存-名称',
`c_job` int(11) NOT NULL COMMENT '缓存-职业',
`c_type` int(11) NOT NULL COMMENT '缓存-碎片类型',
`c_lv` int(11) NOT NULL COMMENT '缓存-级别',
`c_quality` int(11) NOT NULL COMMENT '缓存-品阶',
`c_durability` float NOT NULL COMMENT '缓存-能量',
`c_id` int(11) NOT NULL COMMENT '缓存-id',
PRIMARY KEY (`idx`) USING BTREE,
UNIQUE KEY `idx` (`idx`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8;
DROP TABLE IF EXISTS `t_market_transaction_record`;
CREATE TABLE `t_market_transaction_record` (
`idx` bigint(20) NOT NULL AUTO_INCREMENT,
`createtime` int(11) NOT NULL COMMENT '交易成功时间',
`orderid` bigint(20) NOT NULL COMMENT 'market 订单id',
`o_link` varchar(64) NOT NULL COMMENT '合约订单id',
`seller` varchar(64) NOT NULL COMMENT '卖家',
`buyer` varchar(64) NOT NULL COMMENT '买家',
`tokenid` int(64) NOT NULL COMMENT 'tokenid',
`item_id` int(11) DEFAULT NULL COMMENT '如果有,说明是中心化道具交易',
`amount` int(11) NOT NULL COMMENT '堆叠数量',
`name` varchar(64) NOT NULL COMMENT '商品名称',
`type` int(11) NOT NULL COMMENT '商品类型',
PRIMARY KEY (`idx`)
) ENGINE=InnoDB AUTO_INCREMENT=10001 DEFAULT CHARSET=utf8;