整理项目结构
Change-Id: I03d6160f2bafc0a3c70ca30d6ead505c3167a4d4
diff --git a/appeals/0a905651-b07b-418c-9256-561ffef6fd27_550e8400-e29b-41d4-a716-4466554400006127619759885714672C8-Main+Memory.pdf b/appeals/0a905651-b07b-418c-9256-561ffef6fd27_550e8400-e29b-41d4-a716-4466554400006127619759885714672C8-Main+Memory.pdf
deleted file mode 100644
index 4249fe9..0000000
--- a/appeals/0a905651-b07b-418c-9256-561ffef6fd27_550e8400-e29b-41d4-a716-4466554400006127619759885714672C8-Main+Memory.pdf
+++ /dev/null
Binary files differ
diff --git a/appeals/1ec0d417-3e95-4db5-a09f-c969e0750310_550e8400-e29b-41d4-a716-44665544000019228163651766111265555.png b/appeals/1ec0d417-3e95-4db5-a09f-c969e0750310_550e8400-e29b-41d4-a716-44665544000019228163651766111265555.png
deleted file mode 100644
index 2b1f4cd..0000000
--- a/appeals/1ec0d417-3e95-4db5-a09f-c969e0750310_550e8400-e29b-41d4-a716-44665544000019228163651766111265555.png
+++ /dev/null
Binary files differ
diff --git a/appeals/3cd801c1-21a5-4d2c-a2ad-c038d10337db_550e8400-e29b-41d4-a716-44665544000014156435666049132835C8-Main+Memory.pdf b/appeals/3cd801c1-21a5-4d2c-a2ad-c038d10337db_550e8400-e29b-41d4-a716-44665544000014156435666049132835C8-Main+Memory.pdf
deleted file mode 100644
index 4249fe9..0000000
--- a/appeals/3cd801c1-21a5-4d2c-a2ad-c038d10337db_550e8400-e29b-41d4-a716-44665544000014156435666049132835C8-Main+Memory.pdf
+++ /dev/null
Binary files differ
diff --git a/et --hard b0d52b6 b/et --hard b0d52b6
deleted file mode 100644
index 5dacbbe..0000000
--- a/et --hard b0d52b6
+++ /dev/null
@@ -1,58 +0,0 @@
-[33m9afbc55[m[33m ([m[1;36mHEAD[m[33m -> [m[1;32mmaster[m[33m)[m HEAD@{0}: pull --rebase (finish): returning to refs/heads/master
-[33m9afbc55[m[33m ([m[1;36mHEAD[m[33m -> [m[1;32mmaster[m[33m)[m HEAD@{1}: pull --rebase (pick): 修改cheat文件
-[33me8716ad[m[33m ([m[1;31morigin/master[m[33m, [m[1;31morigin/HEAD[m[33m)[m HEAD@{2}: pull --rebase (start): checkout e8716ada9fc18154108495d7c389b7fc0f269580
-[33mb0d52b6[m HEAD@{3}: commit (amend): 修改cheat文件
-[33m34caf7d[m HEAD@{4}: commit: 修改cheat文件
-[33m720e94e[m HEAD@{5}: commit (amend): Api修改暂存
-[33mba2cb98[m HEAD@{6}: pull: Fast-forward
-[33m26f66f5[m HEAD@{7}: pull: Fast-forward
-[33m7dc11a2[m HEAD@{8}: pull: Fast-forward
-[33mc69af0a[m HEAD@{9}: pull: Fast-forward
-[33medf430a[m HEAD@{10}: commit: 修复testGetAppealList函数
-[33m5ba779f[m HEAD@{11}: commit (amend): Cheat接口部分实现及测试代码
-[33m7a0803a[m HEAD@{12}: commit (amend): 函数拼写矫正&接口修改
-[33md4167c1[m HEAD@{13}: reset: moving to HEAD~1
-[33m56e3ca5[m HEAD@{14}: commit (amend): Cheat接口部分实现及测试代码
-[33m66c7797[m HEAD@{15}: commit (amend): 函数拼写矫正&接口修改
-[33m90f3d5d[m HEAD@{16}: reset: moving to HEAD~1
-[33m99eaef3[m HEAD@{17}: commit (amend): Cheat部分函数实现及测试代码
-[33m1775145[m HEAD@{18}: commit (amend): Cheat System部分功能实现及单元测试代码
-[33m80a7003[m HEAD@{19}: rebase (finish): returning to refs/heads/master
-[33m80a7003[m HEAD@{20}: commit (amend): CheatSystem开发
-[33m2a7ca56[m HEAD@{21}: pull --rebase (pick): Cheat接口改动
-[33m90f3d5d[m HEAD@{22}: pull --rebase (pick): 函数拼写矫正&接口修改
-[33md4167c1[m HEAD@{23}: pull --rebase (pick): 函数拼写矫正&接口修改
-[33m33a7d95[m HEAD@{24}: pull --rebase (start): checkout 33a7d95241577b2720875014004e0e9a1178e2a5
-[33md7dec5f[m HEAD@{25}: commit: CheatSystem开发
-[33ma9594e4[m HEAD@{26}: reset: moving to HEAD
-[33ma9594e4[m HEAD@{27}: rebase (finish): returning to refs/heads/master
-[33ma9594e4[m HEAD@{28}: rebase (pick): Cheat接口改动
-[33mb413180[m HEAD@{29}: rebase (continue): 函数拼写矫正&接口修改
-[33m21e8079[m HEAD@{30}: rebase (continue): 函数拼写矫正&接口修改
-[33mf35409f[m HEAD@{31}: pull --rebase (start): checkout f35409f7212fe81f9f656d45cd305bbf2207f92f
-[33mb97358d[m HEAD@{32}: commit (amend): 本地冲突暂存
-[33maa78bae[m HEAD@{33}: merge refs/remotes/origin/master: Merge made by the 'ort' strategy.
-[33m8b4f838[m HEAD@{34}: commit: Cheat接口改动
-[33m6f65699[m HEAD@{35}: commit: 函数拼写矫正&接口修改
-[33mc9d0644[m HEAD@{36}: commit (amend): 函数拼写矫正&接口修改
-[33m9b70bb3[m HEAD@{37}: commit: 改动Cheat接口
-[33m57f2bac[m HEAD@{38}: pull: Fast-forward
-[33m1d888e1[m HEAD@{39}: pull: Fast-forward
-[33ma912512[m HEAD@{40}: pull: Fast-forward
-[33ma8babc6[m HEAD@{41}: commit (merge): 处理冲突
-[33m0e21c14[m HEAD@{42}: commit: 处理更新
-[33m53e52fc[m HEAD@{43}: commit (amend): 更新API文档 by Raver
-[33mc5deb8f[m HEAD@{44}: commit (amend): 更新API文档 by Raver
-[33mbe6e3e1[m HEAD@{45}: commit: 更新API文档 by Raver
-[33mac1a633[m HEAD@{46}: pull: Fast-forward
-[33mb10834c[m HEAD@{47}: pull: Fast-forward
-[33maa249ae[m HEAD@{48}: pull: Fast-forward
-[33m1b9b88e[m HEAD@{49}: pull: Fast-forward
-[33m30e7379[m HEAD@{50}: pull: Fast-forward
-[33m5663419[m HEAD@{51}: commit (amend): Hello by Raver
-[33mf593971[m HEAD@{52}: commit: Hello by Raver
-[33mbab2b5c[m HEAD@{53}: pull: Fast-forward
-[33mfd27075[m[33m ([m[1;31morigin/Raver[m[33m)[m HEAD@{54}: checkout: moving from Raver to master
-[33maf22949[m[33m ([m[1;32mRaver[m[33m)[m HEAD@{55}: commit: Add user_torrent_stats table creation script
-[33mfd27075[m[33m ([m[1;31morigin/Raver[m[33m)[m HEAD@{56}: checkout: moving from master to Raver
-[33mfd27075[m[33m ([m[1;31morigin/Raver[m[33m)[m HEAD@{57}: clone: from ssh://gerrit.lilingkun.com:29418/G10-PT-TRM
diff --git a/migrations/1b19b0fa-c565-43c7-99f3-ed45f7df69e5_550e8400-e29b-41d4-a716-44665544000011275178369492505304C8-Main+Memory.pdf b/migrations/1b19b0fa-c565-43c7-99f3-ed45f7df69e5_550e8400-e29b-41d4-a716-44665544000011275178369492505304C8-Main+Memory.pdf
deleted file mode 100644
index 4249fe9..0000000
--- a/migrations/1b19b0fa-c565-43c7-99f3-ed45f7df69e5_550e8400-e29b-41d4-a716-44665544000011275178369492505304C8-Main+Memory.pdf
+++ /dev/null
Binary files differ
diff --git a/test b/test
deleted file mode 100644
index e69de29..0000000
--- a/test
+++ /dev/null
diff --git a/testdata.sql b/testdata.sql
deleted file mode 100644
index c1ad1e7..0000000
--- a/testdata.sql
+++ /dev/null
@@ -1,514 +0,0 @@
--- MySQL dump 10.13 Distrib 8.0.42, for Linux (x86_64)
---
--- Host: localhost Database: pt_database_test
--- ------------------------------------------------------
--- Server version 8.0.42-0ubuntu0.24.04.1
-
-/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
-/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
-/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
-/*!50503 SET NAMES utf8mb4 */;
-/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
-/*!40103 SET TIME_ZONE='+00:00' */;
-/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
-/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
-/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
-/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
-
---
--- Table structure for table `Announcement`
---
-
-DROP TABLE IF EXISTS `Announcement`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `Announcement` (
- `announce_id` varchar(64) NOT NULL,
- `content` text NOT NULL,
- `is_public` tinyint(1) NOT NULL DEFAULT '0',
- `tag` varchar(100) DEFAULT NULL,
- PRIMARY KEY (`announce_id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `Announcement`
---
-
-LOCK TABLES `Announcement` WRITE;
-/*!40000 ALTER TABLE `Announcement` DISABLE KEYS */;
-INSERT INTO `Announcement` VALUES ('a1b2c3d4-e5f6-4711-89ab-cdef01234567','系统升级将在今晚 23:00 开始,预计持续 2 小时,期间可能无法访问。',1,'系统通知'),('a7b8c9d0-e1f2-4d77-ef01-23456789abcd','新增帮助中心文章:如何重置密码以及常见问题解答。',1,'帮助文档'),('b2c3d4e5-f6a7-4822-9abc-def012345678','新版本发布:增加了用户头像上传功能和消息提醒。',1,'产品更新'),('b8c9d0e1-f2a3-4e88-f012-3456789abcde','安全提醒:请尽快启用双因素认证,保障账户安全。',1,'安全提醒'),('c3d4e5f6-a7b8-4933-abcd-ef0123456789','本周末例行数据库维护,可能会短暂影响服务稳定性。',0,'运维公告'),('c9d0e1f2-a3b4-4f99-0123-456789abcdef','服务器证书将于 6 月 15 日过期,请相关负责人及时更新。',0,'运维公告'),('d0e1f2a3-b4c5-4a10-1234-56789abcdef0','本月员工生日会定于 5 月 30 日举办,地点:公司大会议室。',1,'公司活动'),('d4e5f6a7-b8c9-4a44-bcde-f0123456789a','节假日放假通知:5 月 1 日—5 月 3 日放假,共 3 天。',1,'节假日'),('e5f6a7b8-c9d0-4b55-cdef-0123456789ab','用户调查问卷已上线,欢迎参与并反馈使用感受。',1,'用户调研'),('f6a7b8c9-d0e1-4c66-def0-123456789abc','API 接口将于下周三变更,旧版接口将在 6 月底下线。',0,'开发者公告');
-/*!40000 ALTER TABLE `Announcement` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `Appeal`
---
-
-DROP TABLE IF EXISTS `Appeal`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `Appeal` (
- `appeal_id` varchar(64) NOT NULL COMMENT '申诉ID',
- `user_id` varchar(36) NOT NULL COMMENT '申诉人(User.user_id)',
- `content` text NOT NULL COMMENT '申诉内容',
- `file_url` varchar(255) DEFAULT NULL COMMENT '申诉文件URL',
- `status` int NOT NULL DEFAULT '0' COMMENT '审核状态',
- PRIMARY KEY (`appeal_id`),
- KEY `fk_appeal_user` (`user_id`),
- CONSTRAINT `fk_appeal_user` FOREIGN KEY (`user_id`) REFERENCES `User` (`user_id`) ON DELETE CASCADE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='申诉表,记录用户的申诉信息';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `Appeal`
---
-
-LOCK TABLES `Appeal` WRITE;
-/*!40000 ALTER TABLE `Appeal` DISABLE KEYS */;
-INSERT INTO `Appeal` VALUES ('0307ad3c-09b5-40c0-8aa3-c5a8f0178f4c','550e8400-e29b-41d4-a716-446655440000','GetAppealList test content 9','http://example.com/file9',0),('202dd30a-3ee7-4d0f-a227-0a17325c9c68','550e8400-e29b-41d4-a716-446655440000','GetAppealList test content 8','http://example.com/file8',0),('212d0782-2ccb-4f25-876d-d4be990af7bc','550e8400-e29b-41d4-a716-446655440000','GetAppealList test content 6','http://example.com/file6',0),('4995a460-128e-4886-8682-e75bbb2dbce2','550e8400-e29b-41d4-a716-446655440000','GetAppealList test content 1','http://example.com/file1',0),('7b9c4044-39b6-41b5-8754-ff784788f116','550e8400-e29b-41d4-a716-446655440000','GetAppealList test content 2','http://example.com/file2',0),('a38fa86d-9bce-4342-852d-272566e46553','550e8400-e29b-41d4-a716-446655440000','GetAppealList test content 3','http://example.com/file3',0),('a6345f31-6938-4ff9-8c1e-0f5b3c9d6d56','550e8400-e29b-41d4-a716-446655440000','GetAppealList test content 5','http://example.com/file5',0),('b1c3fcdd-6c25-42d2-9782-cae4bd609368','550e8400-e29b-41d4-a716-446655440000','GetAppealList test content 0','http://example.com/file0',0),('bef4085a-1ec3-40ea-a43c-1964c9180e9d','550e8400-e29b-41d4-a716-446655440000','GetAppealList test content 7','http://example.com/file7',0),('ce843f31-eb01-4954-a234-d175d262bfdc','550e8400-e29b-41d4-a716-446655440000','GetAppealList test content 4','http://example.com/file4',0);
-/*!40000 ALTER TABLE `Appeal` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `BegSeed`
---
-
-DROP TABLE IF EXISTS `BegSeed`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `BegSeed` (
- `beg_id` varchar(64) NOT NULL,
- `beg_count` int NOT NULL DEFAULT '0',
- `reward_magic` int NOT NULL DEFAULT '0',
- `deadline` datetime NOT NULL,
- `has_match` tinyint(1) NOT NULL DEFAULT '0',
- PRIMARY KEY (`beg_id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `BegSeed`
---
-
-LOCK TABLES `BegSeed` WRITE;
-/*!40000 ALTER TABLE `BegSeed` DISABLE KEYS */;
-INSERT INTO `BegSeed` VALUES ('test_beg_settle_1749112257693',1,100,'2025-05-21 08:30:58',1),('test_beg_settle_1749113033612',1,100,'2025-05-21 08:43:54',1),('test_beg_settle_1749115170790',1,100,'2025-05-21 09:19:31',1);
-/*!40000 ALTER TABLE `BegSeed` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `Post`
---
-
-DROP TABLE IF EXISTS `Post`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `Post` (
- `post_id` varchar(64) NOT NULL,
- `title` varchar(255) NOT NULL,
- `content` text NOT NULL,
- `author_id` varchar(36) NOT NULL,
- `created_at` datetime NOT NULL,
- `reply_count` int NOT NULL DEFAULT '0',
- `view_count` int NOT NULL DEFAULT '0',
- PRIMARY KEY (`post_id`),
- KEY `fk_post_user` (`author_id`),
- CONSTRAINT `fk_post_user` FOREIGN KEY (`author_id`) REFERENCES `User` (`user_id`) ON DELETE CASCADE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `Post`
---
-
-LOCK TABLES `Post` WRITE;
-/*!40000 ALTER TABLE `Post` DISABLE KEYS */;
-/*!40000 ALTER TABLE `Post` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `PostReply`
---
-
-DROP TABLE IF EXISTS `PostReply`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `PostReply` (
- `reply_id` varchar(64) NOT NULL,
- `post_id` varchar(64) NOT NULL,
- `content` text NOT NULL,
- `author_id` varchar(36) NOT NULL,
- `created_at` datetime NOT NULL,
- PRIMARY KEY (`reply_id`),
- KEY `fk_pr_post` (`post_id`),
- KEY `fk_pr_user` (`author_id`),
- CONSTRAINT `fk_pr_post` FOREIGN KEY (`post_id`) REFERENCES `Post` (`post_id`) ON DELETE CASCADE,
- CONSTRAINT `fk_pr_user` FOREIGN KEY (`author_id`) REFERENCES `User` (`user_id`) ON DELETE CASCADE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `PostReply`
---
-
-LOCK TABLES `PostReply` WRITE;
-/*!40000 ALTER TABLE `PostReply` DISABLE KEYS */;
-/*!40000 ALTER TABLE `PostReply` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `Seed`
---
-
-DROP TABLE IF EXISTS `Seed`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `Seed` (
- `seed_id` varchar(64) NOT NULL,
- `owner_user_id` varchar(36) NOT NULL,
- `fake_hits` int NOT NULL DEFAULT '0',
- `last_fake_check` datetime DEFAULT NULL,
- `external_url` varchar(255) DEFAULT NULL,
- `title` varchar(255) NOT NULL,
- `subtitle` varchar(255) DEFAULT NULL,
- `size` varchar(50) NOT NULL,
- `tags` varchar(255) DEFAULT NULL,
- `popularity` int NOT NULL DEFAULT '0',
- `URL` text COMMENT 'TTorrent 文件在服务器上存储的 URL',
- PRIMARY KEY (`seed_id`),
- KEY `fk_seed_user` (`owner_user_id`),
- CONSTRAINT `fk_seed_user` FOREIGN KEY (`owner_user_id`) REFERENCES `User` (`user_id`) ON DELETE CASCADE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `Seed`
---
-
-LOCK TABLES `Seed` WRITE;
-/*!40000 ALTER TABLE `Seed` DISABLE KEYS */;
-INSERT INTO `Seed` VALUES ('exampleSeedId','550e8400-e29b-41d4-a716-446655440000',0,NULL,NULL,'test',NULL,'1GB','大陆',0,'torrents/exampleSeedId_exampleSeedId_test16436511100052430070.torrent'),('seed001','550e8400-e29b-41d4-a716-446655440000',10,'2025-05-19 10:00:00','http://example.com/seed001','Awesome Movie','Action Thriller','1.5GB','大陆',100,'torrents/seed001_seed001_test17718681796068962628.torrent'),('seed004','550e8400-e29b-41d4-a716-446655440003',8,'2025-05-19 11:00:00','http://example.com/seed004','Comedy Series','Season 1','700MB','大陆',75,'torrents/seed004_seed004_test2953554280018110244.torrent'),('seed009','550e8400-e29b-41d4-a716-446655440008',18,'2025-05-17 21:45:00','http://example.com/seed009','Sci-Fi Movie','Space Odyssey','2GB','港台',180,'torrents/seed009_seed009_test13451296490325930642.torrent'),('seed111','550e8400-e29b-41d4-a716-446655440003',0,NULL,NULL,'test2',NULL,'1',NULL,0,'torrents/seed111_seed111_test14021531522609506819.torrent'),('seed222','550e8400-e29b-41d4-a716-446655440003',0,NULL,NULL,'test3',NULL,'1','港剧',0,'torrents/seed222_seed222_test11259979984170882790.torrent'),('test_seed_settle_1749111508968','550e8400-e29b-41d4-a716-446655440000',0,NULL,NULL,'测试种子',NULL,'1',NULL,0,'torrents/test_seed_settle_1749111508968_test_seed_settle_1749111508968_test14644621044707116370.torrent'),('test_seed_settle_1749111581741','550e8400-e29b-41d4-a716-446655440000',0,NULL,NULL,'测试种子',NULL,'1',NULL,0,'torrents/test_seed_settle_1749111581741_test_seed_settle_1749111581741_test4953741892853909459.torrent'),('test_seed_settle_1749112208219','550e8400-e29b-41d4-a716-446655440000',0,NULL,NULL,'测试种子',NULL,'1',NULL,0,'torrents/test_seed_settle_1749112208219_test_seed_settle_1749112208219_test3659044688757063978.torrent'),('test_seed_settle_1749112257695','550e8400-e29b-41d4-a716-446655440000',0,NULL,NULL,'测试种子',NULL,'1',NULL,0,'torrents/test_seed_settle_1749112257695_test_seed_settle_1749112257695_test17979750181307660047.torrent'),('test_seed_settle_1749113033614','550e8400-e29b-41d4-a716-446655440000',0,NULL,NULL,'测试种子',NULL,'1',NULL,0,'torrents/test_seed_settle_1749113033614_test_seed_settle_1749113033614_test13945890241269543288.torrent'),('test_seed_settle_1749115170791','550e8400-e29b-41d4-a716-446655440000',0,NULL,NULL,'测试种子',NULL,'1',NULL,0,NULL);
-/*!40000 ALTER TABLE `Seed` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `SeedDownload`
---
-
-DROP TABLE IF EXISTS `SeedDownload`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `SeedDownload` (
- `task_id` varchar(64) NOT NULL,
- `user_id` varchar(36) NOT NULL,
- `seed_id` varchar(64) NOT NULL,
- `download_start` datetime NOT NULL,
- `download_end` datetime DEFAULT NULL,
- `is_dedicated` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0=普通,1=专线',
- `client_ip` varchar(45) DEFAULT NULL,
- PRIMARY KEY (`task_id`),
- KEY `fk_sd_user` (`user_id`),
- KEY `fk_sd_seed` (`seed_id`),
- CONSTRAINT `fk_sd_seed` FOREIGN KEY (`seed_id`) REFERENCES `Seed` (`seed_id`) ON DELETE CASCADE,
- CONSTRAINT `fk_sd_user` FOREIGN KEY (`user_id`) REFERENCES `User` (`user_id`) ON DELETE CASCADE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `SeedDownload`
---
-
-LOCK TABLES `SeedDownload` WRITE;
-/*!40000 ALTER TABLE `SeedDownload` DISABLE KEYS */;
-INSERT INTO `SeedDownload` VALUES ('3717648a-3ac0-11f0-b2ca-bc2411405807','550e8400-e29b-41d4-a716-446655440000','seed001','2025-05-01 09:12:34','2025-05-01 09:15:02',1,NULL),('3717762c-3ac0-11f0-b2ca-bc2411405807','550e8400-e29b-41d4-a716-446655440003','seed004','2025-05-04 07:30:10','2025-05-04 07:35:55',1,NULL),('3717806c-3ac0-11f0-b2ca-bc2411405807','550e8400-e29b-41d4-a716-446655440008','seed009','2025-05-09 05:05:05',NULL,0,NULL);
-/*!40000 ALTER TABLE `SeedDownload` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `SubmitSeed`
---
-
-DROP TABLE IF EXISTS `SubmitSeed`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `SubmitSeed` (
- `beg_id` varchar(64) NOT NULL,
- `seed_id` varchar(64) NOT NULL,
- `votes` int NOT NULL DEFAULT '0',
- PRIMARY KEY (`beg_id`,`seed_id`),
- KEY `fk_ss_seed` (`seed_id`),
- CONSTRAINT `fk_ss_beg` FOREIGN KEY (`beg_id`) REFERENCES `BegSeed` (`beg_id`) ON DELETE CASCADE,
- CONSTRAINT `fk_ss_seed` FOREIGN KEY (`seed_id`) REFERENCES `Seed` (`seed_id`) ON DELETE CASCADE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `SubmitSeed`
---
-
-LOCK TABLES `SubmitSeed` WRITE;
-/*!40000 ALTER TABLE `SubmitSeed` DISABLE KEYS */;
-INSERT INTO `SubmitSeed` VALUES ('test_beg_settle_1749112257693','test_seed_settle_1749112257695',1),('test_beg_settle_1749113033612','test_seed_settle_1749113033614',1),('test_beg_settle_1749115170790','test_seed_settle_1749115170791',1);
-/*!40000 ALTER TABLE `SubmitSeed` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `Transport`
---
-
-DROP TABLE IF EXISTS `Transport`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `Transport` (
- `task_id` varchar(64) NOT NULL,
- `uploader_id` varchar(36) NOT NULL,
- `downloader_id` varchar(36) NOT NULL,
- `seed_id` varchar(64) NOT NULL,
- `uploaded` bigint NOT NULL DEFAULT '0',
- `downloaded` bigint NOT NULL DEFAULT '0',
- `upload_peak` bigint NOT NULL DEFAULT '0',
- `download_peak` bigint NOT NULL DEFAULT '0',
- PRIMARY KEY (`task_id`,`uploader_id`,`downloader_id`),
- KEY `fk_tr_user_up` (`uploader_id`),
- KEY `fk_tr_user_down` (`downloader_id`),
- KEY `fk_tr_seed` (`seed_id`),
- CONSTRAINT `fk_tr_seed` FOREIGN KEY (`seed_id`) REFERENCES `Seed` (`seed_id`) ON DELETE CASCADE,
- CONSTRAINT `fk_tr_user_down` FOREIGN KEY (`downloader_id`) REFERENCES `User` (`user_id`) ON DELETE CASCADE,
- CONSTRAINT `fk_tr_user_up` FOREIGN KEY (`uploader_id`) REFERENCES `User` (`user_id`) ON DELETE CASCADE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `Transport`
---
-
-LOCK TABLES `Transport` WRITE;
-/*!40000 ALTER TABLE `Transport` DISABLE KEYS */;
-/*!40000 ALTER TABLE `Transport` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `User`
---
-
-DROP TABLE IF EXISTS `User`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `User` (
- `user_id` varchar(36) NOT NULL,
- `email` varchar(255) NOT NULL,
- `username` varchar(100) NOT NULL,
- `password` varchar(255) NOT NULL,
- `gender` enum('m','f') NOT NULL,
- `school` varchar(255) DEFAULT NULL,
- `avatar_url` varchar(255) DEFAULT NULL,
- `bio` text,
- `account_status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0=正常,1=被ban',
- `invite_left` int NOT NULL DEFAULT '0',
- `detectedCount` int NOT NULL DEFAULT '0',
- `lastDetectedTime` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
- `fake_detected_count` int NOT NULL DEFAULT '0',
- `fake_last_detected_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
- PRIMARY KEY (`user_id`,`email`),
- UNIQUE KEY `uniq_email` (`email`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `User`
---
-
-LOCK TABLES `User` WRITE;
-/*!40000 ALTER TABLE `User` DISABLE KEYS */;
-INSERT INTO `User` VALUES ('550e8400-e29b-41d4-a716-446655440000','alice@example.com','alice','$2y$10$abcdefghijklmnopqrstuv','f','Stanford University','https://cdn.example.com/avatars/alice.jpg','Passionate swimmer and coder.',0,5,0,'2025-05-20 12:29:40',0,'2025-05-27 09:37:46'),('550e8400-e29b-41d4-a716-446655440003','dave@example.net','dave','$2y$10$mnopqrstuvwxyzABCDEF','m','University of Oxford','https://cdn.example.com/avatars/dave.jpg','Guitarist in a jazz band.',0,0,0,'2025-05-20 12:29:40',0,'2025-05-27 09:37:46'),('550e8400-e29b-41d4-a716-446655440008','irene@example.org','irene','$2y$10$34567890abcdefghijklmn','f','National University of Singapore','https://cdn.example.com/avatars/irene.jpg','Time-lapse photographer and traveler.',0,0,0,'2025-05-20 12:29:40',0,'2025-05-27 09:37:46');
-/*!40000 ALTER TABLE `User` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `UserFavorite`
---
-
-DROP TABLE IF EXISTS `UserFavorite`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `UserFavorite` (
- `user_id` varchar(36) NOT NULL,
- `seed_id` varchar(64) NOT NULL,
- PRIMARY KEY (`user_id`,`seed_id`),
- UNIQUE KEY `UK_dqxat2yuess97ol62itck0bul` (`user_id`),
- UNIQUE KEY `UK_kf5p3eu6m26b6afhmmfcbdn8j` (`seed_id`),
- KEY `fk_uf_seed` (`seed_id`),
- CONSTRAINT `fk_uf_seed` FOREIGN KEY (`seed_id`) REFERENCES `Seed` (`seed_id`) ON DELETE CASCADE,
- CONSTRAINT `fk_uf_user` FOREIGN KEY (`user_id`) REFERENCES `User` (`user_id`) ON DELETE CASCADE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `UserFavorite`
---
-
-LOCK TABLES `UserFavorite` WRITE;
-/*!40000 ALTER TABLE `UserFavorite` DISABLE KEYS */;
-INSERT INTO `UserFavorite` VALUES ('550e8400-e29b-41d4-a716-446655440000','seed004'),('550e8400-e29b-41d4-a716-446655440003','seed009'),('550e8400-e29b-41d4-a716-446655440008','seed001');
-/*!40000 ALTER TABLE `UserFavorite` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `UserInvite`
---
-
-DROP TABLE IF EXISTS `UserInvite`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `UserInvite` (
- `user_id` varchar(36) NOT NULL,
- `inviter_email` varchar(255) NOT NULL,
- `inviter_registered` tinyint(1) NOT NULL DEFAULT '0',
- PRIMARY KEY (`user_id`,`inviter_email`),
- CONSTRAINT `fk_ui_user` FOREIGN KEY (`user_id`) REFERENCES `User` (`user_id`) ON DELETE CASCADE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `UserInvite`
---
-
-LOCK TABLES `UserInvite` WRITE;
-/*!40000 ALTER TABLE `UserInvite` DISABLE KEYS */;
-INSERT INTO `UserInvite` VALUES ('550e8400-e29b-41d4-a716-446655440000','user009@example.com',1),('550e8400-e29b-41d4-a716-446655440003','user002@example.com',1),('550e8400-e29b-41d4-a716-446655440008','user007@example.com',1);
-/*!40000 ALTER TABLE `UserInvite` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `UserMigration`
---
-
-DROP TABLE IF EXISTS `UserMigration`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `UserMigration` (
- `migration_id` varchar(64) NOT NULL,
- `user_id` varchar(36) NOT NULL,
- `application_url` varchar(255) NOT NULL,
- `approved` tinyint(1) NOT NULL DEFAULT '0',
- `pending_magic` int NOT NULL DEFAULT '0',
- `granted_magic` int NOT NULL DEFAULT '0',
- `pending_uploaded` bigint NOT NULL DEFAULT '0',
- `granted_uploaded` bigint NOT NULL DEFAULT '0',
- PRIMARY KEY (`migration_id`),
- KEY `fk_um_user` (`user_id`),
- CONSTRAINT `fk_um_user` FOREIGN KEY (`user_id`) REFERENCES `User` (`user_id`) ON DELETE CASCADE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `UserMigration`
---
-
-LOCK TABLES `UserMigration` WRITE;
-/*!40000 ALTER TABLE `UserMigration` DISABLE KEYS */;
-/*!40000 ALTER TABLE `UserMigration` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `UserPT`
---
-
-DROP TABLE IF EXISTS `UserPT`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `UserPT` (
- `user_id` varchar(36) NOT NULL,
- `magic` int NOT NULL DEFAULT '0',
- `uploaded` bigint NOT NULL DEFAULT '0',
- `downloaded` bigint NOT NULL DEFAULT '0',
- `ratio` decimal(5,2) NOT NULL DEFAULT '0.00',
- `default_seed_path` varchar(255) DEFAULT NULL,
- `vip_downloads` int NOT NULL DEFAULT '0',
- PRIMARY KEY (`user_id`),
- CONSTRAINT `fk_pt_user` FOREIGN KEY (`user_id`) REFERENCES `User` (`user_id`) ON DELETE CASCADE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `UserPT`
---
-
-LOCK TABLES `UserPT` WRITE;
-/*!40000 ALTER TABLE `UserPT` DISABLE KEYS */;
-INSERT INTO `UserPT` VALUES ('550e8400-e29b-41d4-a716-446655440000',0,0,0,0.00,'/data/seeds/550e8400-e29b-41d4-a716-446655440000',0),('550e8400-e29b-41d4-a716-446655440003',4096,4194304,2097152,2.00,'/data/seeds/550e8400-e29b-41d4-a716-446655440003',5),('550e8400-e29b-41d4-a716-446655440008',65536,65536000,32768000,2.00,'/data/seeds/550e8400-e29b-41d4-a716-446655440008',6);
-/*!40000 ALTER TABLE `UserPT` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `UserVotes`
---
-
-DROP TABLE IF EXISTS `UserVotes`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `UserVotes` (
- `user_id` varchar(36) NOT NULL,
- `beg_id` varchar(64) NOT NULL,
- `seed_id` varchar(64) NOT NULL,
- `created_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
- PRIMARY KEY (`user_id`,`beg_id`,`seed_id`),
- KEY `beg_id` (`beg_id`),
- KEY `seed_id` (`seed_id`),
- CONSTRAINT `UserVotes_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `User` (`user_id`) ON DELETE CASCADE,
- CONSTRAINT `UserVotes_ibfk_2` FOREIGN KEY (`beg_id`) REFERENCES `BegSeed` (`beg_id`) ON DELETE CASCADE,
- CONSTRAINT `UserVotes_ibfk_3` FOREIGN KEY (`seed_id`) REFERENCES `Seed` (`seed_id`) ON DELETE CASCADE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `UserVotes`
---
-
-LOCK TABLES `UserVotes` WRITE;
-/*!40000 ALTER TABLE `UserVotes` DISABLE KEYS */;
-INSERT INTO `UserVotes` VALUES ('550e8400-e29b-41d4-a716-446655440000','test_beg_settle_1749112257693','test_seed_settle_1749112257695','2025-06-05 08:30:58'),('550e8400-e29b-41d4-a716-446655440000','test_beg_settle_1749113033612','test_seed_settle_1749113033614','2025-06-05 08:43:54'),('550e8400-e29b-41d4-a716-446655440000','test_beg_settle_1749115170790','test_seed_settle_1749115170791','2025-06-05 09:19:31');
-/*!40000 ALTER TABLE `UserVotes` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `VipSeed`
---
-
-DROP TABLE IF EXISTS `VipSeed`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!50503 SET character_set_client = utf8mb4 */;
-CREATE TABLE `VipSeed` (
- `seed_id` varchar(64) NOT NULL,
- `seeder_count` int NOT NULL DEFAULT '0',
- `reward_magic` int NOT NULL DEFAULT '0',
- `stop_caching` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0=继续缓存,1=不缓存',
- `bonus` int NOT NULL,
- `cache_status` bit(1) NOT NULL,
- `farmer_number` int NOT NULL,
- PRIMARY KEY (`seed_id`),
- CONSTRAINT `fk_vip_seed` FOREIGN KEY (`seed_id`) REFERENCES `Seed` (`seed_id`) ON DELETE CASCADE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `VipSeed`
---
-
-LOCK TABLES `VipSeed` WRITE;
-/*!40000 ALTER TABLE `VipSeed` DISABLE KEYS */;
-INSERT INTO `VipSeed` VALUES ('seed001',5,50,0,10,_binary '',2),('seed004',8,80,0,15,_binary '',4),('seed009',30,300,0,60,_binary '\0',15);
-/*!40000 ALTER TABLE `VipSeed` ENABLE KEYS */;
-UNLOCK TABLES;
-/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
-
-/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
-/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
-/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
-/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-
--- Dump completed on 2025-06-05 9:45:32