-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathcheemshappypay.sql
More file actions
172 lines (159 loc) · 6.45 KB
/
cheemshappypay.sql
File metadata and controls
172 lines (159 loc) · 6.45 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
/*
Navicat Premium Dump SQL
Source Server : 45.207.207.178
Source Server Type : MySQL
Source Server Version : 50744 (5.7.44)
Source Host : 45.207.207.178:7002
Source Schema : cheemshappypay
Target Server Type : MySQL
Target Server Version : 50744 (5.7.44)
File Encoding : 65001
Date: 24/02/2025 11:40:22
*/
SET NAMES utf8mb4;
SET FOREIGN_KEY_CHECKS = 0;
-- ----------------------------
-- Table structure for merchants
-- ----------------------------
DROP TABLE IF EXISTS `merchants`;
CREATE TABLE `merchants` (
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
`nickname` text NOT NULL COMMENT '昵称',
`avatar` text COMMENT '头像',
`introduction` text COMMENT '简介',
`password` longtext NOT NULL,
`email` longtext NOT NULL,
`phone` text,
`created_by` varchar(255) DEFAULT NULL,
`created_at` datetime(3) DEFAULT NULL,
`updated_at` datetime(3) DEFAULT NULL,
`deleted_at` datetime(3) DEFAULT NULL,
PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=30 DEFAULT CHARSET=utf8mb4;
-- ----------------------------
-- Table structure for merchants_api
-- ----------------------------
DROP TABLE IF EXISTS `merchants_api`;
CREATE TABLE `merchants_api` (
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
`m_id` bigint(20) unsigned NOT NULL,
`apikey` text NOT NULL COMMENT 'Token',
`callback_url` text NOT NULL COMMENT '回调url',
`secret_key` text NOT NULL COMMENT '回调加密参数',
`remark` text COMMENT '备注',
`created_at` datetime(3) DEFAULT NULL,
`updated_at` datetime(3) DEFAULT NULL,
`deleted_at` datetime(3) DEFAULT NULL,
PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb4;
-- ----------------------------
-- Table structure for merchants_meta
-- ----------------------------
DROP TABLE IF EXISTS `merchants_meta`;
CREATE TABLE `merchants_meta` (
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
`m_id` bigint(20) unsigned NOT NULL,
`ac` text COMMENT '钱包地址',
`created_at` datetime(3) DEFAULT NULL,
`updated_at` datetime(3) DEFAULT NULL,
`deleted_at` datetime(3) DEFAULT NULL,
PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=8 DEFAULT CHARSET=utf8mb4;
-- ----------------------------
-- Table structure for order
-- ----------------------------
DROP TABLE IF EXISTS `order`;
CREATE TABLE `order` (
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
`m_id` bigint(20) unsigned NOT NULL,
`no` text NOT NULL COMMENT '订单no',
`c_no` text NOT NULL COMMENT '用户no',
`amount` text NOT NULL COMMENT '价格',
`coin` text NOT NULL COMMENT '数字币类型',
`chain` text NOT NULL COMMENT '链',
`notify_url` text COMMENT '回调url',
`return_url` text COMMENT '前端重定向url',
`pay_url` text COMMENT '支付地址',
`tx_hash` text COMMENT '交易hash',
`ac` text COMMENT '钱包地址',
`api_key` text COMMENT '商户apikey',
`time_out` int(11) DEFAULT NULL COMMENT '超时时间',
`status` varchar(255) DEFAULT NULL COMMENT '订单状态',
`notify_status` varchar(255) DEFAULT NULL COMMENT '订单回调结果',
`remark` text COMMENT '备注',
`created_at` datetime(3) DEFAULT NULL,
`updated_at` datetime(3) DEFAULT NULL,
`deleted_at` datetime(3) DEFAULT NULL,
PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8mb4;
-- ----------------------------
-- Table structure for sys_config
-- ----------------------------
DROP TABLE IF EXISTS `sys_config`;
CREATE TABLE `sys_config` (
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
`domain` text NOT NULL COMMENT '项目域名',
`created_at` datetime(3) DEFAULT NULL,
`updated_at` datetime(3) DEFAULT NULL,
`deleted_at` datetime(3) DEFAULT NULL,
PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb4;
-- ----------------------------
-- Table structure for sys_wallet
-- ----------------------------
DROP TABLE IF EXISTS `sys_wallet`;
CREATE TABLE `sys_wallet` (
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
`ac` text NOT NULL COMMENT '钱包地址',
`pri_key` text NOT NULL COMMENT '私钥',
`mnemonic` varchar(255) NOT NULL COMMENT '助记词',
`path` text NOT NULL COMMENT '钱包路径',
`remark` text COMMENT '备注',
`created_at` datetime(3) DEFAULT NULL,
`updated_at` datetime(3) DEFAULT NULL,
`deleted_at` datetime(3) DEFAULT NULL,
`current_index` int(10) unsigned NOT NULL DEFAULT '0' COMMENT '当前派生索引',
`version` int(11) NOT NULL DEFAULT '0',
PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb4;
-- ----------------------------
-- Table structure for user
-- ----------------------------
DROP TABLE IF EXISTS `user`;
CREATE TABLE `user` (
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
`user_type` varchar(191) NOT NULL,
`user_id` varchar(191) NOT NULL,
`nickname` text NOT NULL COMMENT '昵称',
`avatar` text NOT NULL COMMENT '头像',
`introduction` text COMMENT '简介',
`password` longtext NOT NULL,
`email` longtext NOT NULL,
`phone` text,
`login_at` datetime(3) DEFAULT NULL ON UPDATE CURRENT_TIMESTAMP(3),
`created_at` datetime(3) DEFAULT NULL,
`updated_at` datetime(3) DEFAULT NULL,
`deleted_at` datetime(3) DEFAULT NULL,
PRIMARY KEY (`id`) USING BTREE,
UNIQUE KEY `user_id` (`user_type`) USING BTREE,
KEY `idx_users_deleted_at` (`deleted_at`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=174 DEFAULT CHARSET=utf8mb4;
INSERT INTO `user` (`id`, `user_type`, `user_id`, `nickname`, `avatar`, `introduction`, `password`, `email`, `phone`, `login_at`, `created_at`, `updated_at`, `deleted_at`) VALUES (1, 'admin', '123456', '123', '1', NULL, '$2a$10$1DpQrC8M8iL7tOI3JFan7eu4Is7XgUdIXEy6zKK/wV8I3VzMqVgJe', 'ch@cheemshappy.com', NULL, '2025-02-18 06:14:40.264', NULL, '2025-02-25 16:43:53.518', NULL);
-- ----------------------------
-- Table structure for wallet
-- ----------------------------
DROP TABLE IF EXISTS `wallet`;
CREATE TABLE `wallet` (
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
`m_id` bigint(20) unsigned NOT NULL,
`ac` text NOT NULL COMMENT '钱包地址',
`pri_key` text NOT NULL COMMENT '私钥',
`mnemonic` text NOT NULL COMMENT '助词器',
`path` text NOT NULL COMMENT '钱包路径',
`remark` text COMMENT '备注',
`created_at` datetime(3) DEFAULT NULL,
`updated_at` datetime(3) DEFAULT NULL,
`deleted_at` datetime(3) DEFAULT NULL,
PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=25 DEFAULT CHARSET=utf8mb4;
SET FOREIGN_KEY_CHECKS = 1;