-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathnetmusic.sql
136 lines (121 loc) · 5.19 KB
/
netmusic.sql
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
SET NAMES utf8mb4;
SET FOREIGN_KEY_CHECKS = 0;
-- ----------------------------
-- Table structure for subscribe
-- ----------------------------
DROP TABLE IF EXISTS `subscribe`;
CREATE TABLE `subscribe`
(
`id` bigint NOT NULL AUTO_INCREMENT,
`remark` varchar(256) NOT NULL DEFAULT '',
`reg_name` varchar(256) NOT NULL DEFAULT '',
`user_id` bigint NOT NULL DEFAULT '0',
`voice_list_id` bigint NOT NULL,
`target_id` varchar(256) NOT NULL DEFAULT '',
`type` varchar(128) NOT NULL DEFAULT '',
`process_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
`from_time` datetime DEFAULT NULL,
`to_time` datetime DEFAULT NULL,
`key_word` varchar(256) NOT NULL DEFAULT '',
`limit_sec` int NOT NULL DEFAULT '0',
`video_order` varchar(128) DEFAULT 'PUB_NEW_FIRST_THEN_OLD',
`net_cover` varchar(256) NOT NULL DEFAULT '',
`enable` tinyint NOT NULL DEFAULT '1',
`crack` tinyint NOT NULL DEFAULT '0',
`use_video_cover` tinyint NOT NULL DEFAULT '0',
`priority` int NOT NULL DEFAULT '0',
`log` varchar(8192) DEFAULT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `subscribe_pk` (`user_id`, `target_id`, `key_word`)
) ENGINE = InnoDB
AUTO_INCREMENT = 60
DEFAULT CHARSET = utf8mb4
COLLATE = utf8mb4_unicode_ci;
-- ----------------------------
-- Table structure for subscribe_reg
-- ----------------------------
DROP TABLE IF EXISTS `subscribe_reg`;
CREATE TABLE `subscribe_reg`
(
`id` bigint NOT NULL AUTO_INCREMENT,
`subscribe_id` bigint NOT NULL DEFAULT '0',
`regex` varchar(512) NOT NULL DEFAULT '',
`pos` int NOT NULL DEFAULT '0',
PRIMARY KEY (`id`),
UNIQUE KEY `subscribe_reg_pk_2` (`subscribe_id`, `pos`)
) ENGINE = InnoDB
AUTO_INCREMENT = 9
DEFAULT CHARSET = utf8mb4
COLLATE = utf8mb4_general_ci;
-- ----------------------------
-- Table structure for sys_user
-- ----------------------------
DROP TABLE IF EXISTS `sys_user`;
CREATE TABLE `sys_user`
(
`id` bigint NOT NULL AUTO_INCREMENT,
`username` varchar(256) NOT NULL,
`password` varchar(256) NOT NULL,
`net_cookies` varchar(8192) NOT NULL DEFAULT '',
`bili_cookies` varchar(4096) NOT NULL DEFAULT '',
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
`visit_times` int NOT NULL DEFAULT 0,
PRIMARY KEY (`id`),
UNIQUE KEY `sys_user_pk` (`username`)
) ENGINE = InnoDB
AUTO_INCREMENT = 53
DEFAULT CHARSET = utf8mb4
COLLATE = utf8mb4_general_ci;
-- ----------------------------
-- Table structure for upload_detail
-- ----------------------------
DROP TABLE IF EXISTS `upload_detail`;
CREATE TABLE `upload_detail`
(
`id` bigint NOT NULL AUTO_INCREMENT,
`subscribe_id` bigint NOT NULL DEFAULT '0',
`user_id` bigint NOT NULL DEFAULT '0',
`upload_name` varchar(512) NOT NULL DEFAULT '',
`create_time` datetime(3) NOT NULL DEFAULT CURRENT_TIMESTAMP(3),
`update_time` datetime(3) NOT NULL DEFAULT CURRENT_TIMESTAMP(3) ON UPDATE CURRENT_TIMESTAMP(3),
`offset` decimal(10, 2) NOT NULL DEFAULT '0.00',
`begin_sec` decimal(10, 2) NOT NULL DEFAULT '0.00',
`end_sec` decimal(10, 2) NOT NULL DEFAULT '0.00',
`voice_id` bigint NOT NULL DEFAULT '0',
`voice_list_id` bigint NOT NULL DEFAULT '0',
`privacy` tinyint NOT NULL DEFAULT '0',
`bvid` varchar(256) NOT NULL DEFAULT '',
`cid` varchar(256) NOT NULL DEFAULT '',
`title` varchar(256) NOT NULL DEFAULT '',
`retry_times` int NOT NULL DEFAULT '0',
`status` varchar(64) NOT NULL DEFAULT 'WAIT',
`use_video_cover` tinyint NOT NULL DEFAULT '0',
`crack` tinyint NOT NULL DEFAULT '0',
`priority` int NOT NULL DEFAULT '0',
`instance_id` bigint NOT NULL DEFAULT '0',
`log` varchar(8192) NOT NULL DEFAULT '',
PRIMARY KEY (`id`)
) ENGINE = InnoDB
AUTO_INCREMENT = 12745
DEFAULT CHARSET = utf8mb4
COLLATE = utf8mb4_general_ci;
SET FOREIGN_KEY_CHECKS = 1;
create index upload_detail_crack_index
on upload_detail (crack);
create index upload_detail_priority_index
on upload_detail (priority);
create index upload_detail_privacy_index
on upload_detail (privacy);
create index upload_detail_retry_times_index
on upload_detail (retry_times);
create index upload_detail_status_index
on upload_detail (status);
create index upload_detail_subscribe_id_index
on upload_detail (subscribe_id);
create index upload_detail_use_video_cover_index
on upload_detail (use_video_cover);
create index upload_detail_user_id_index
on upload_detail (user_id);
create index upload_detail_voice_list_id_index
on upload_detail (voice_list_id);