waline.tidb 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. CREATE DATABASE `waline`;
  2. USE waline;
  3. CREATE TABLE `wl_Comment` (
  4. `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  5. `user_id` int(11) DEFAULT NULL,
  6. `comment` text,
  7. `insertedAt` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
  8. `ip` varchar(100) DEFAULT '',
  9. `link` varchar(255) DEFAULT NULL,
  10. `mail` varchar(255) DEFAULT NULL,
  11. `nick` varchar(255) DEFAULT NULL,
  12. `pid` int(11) DEFAULT NULL,
  13. `rid` int(11) DEFAULT NULL,
  14. `sticky` boolean DEFAULT NULL,
  15. `status` varchar(50) NOT NULL DEFAULT '',
  16. `like` int(11) DEFAULT NULL,
  17. `ua` text,
  18. `url` varchar(255) DEFAULT NULL,
  19. `createdAt` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
  20. `updatedAt` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
  21. PRIMARY KEY (`id`)
  22. ) CHARSET=utf8mb4;
  23. CREATE TABLE `wl_Counter` (
  24. `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  25. `time` int(11) DEFAULT NULL,
  26. `reaction0` int(11) DEFAULT NULL,
  27. `reaction1` int(11) DEFAULT NULL,
  28. `reaction2` int(11) DEFAULT NULL,
  29. `reaction3` int(11) DEFAULT NULL,
  30. `reaction4` int(11) DEFAULT NULL,
  31. `reaction5` int(11) DEFAULT NULL,
  32. `reaction6` int(11) DEFAULT NULL,
  33. `reaction7` int(11) DEFAULT NULL,
  34. `reaction8` int(11) DEFAULT NULL,
  35. `url` varchar(255) NOT NULL DEFAULT '',
  36. `createdAt` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
  37. `updatedAt` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
  38. PRIMARY KEY (`id`)
  39. ) CHARSET=utf8mb4;
  40. CREATE TABLE `wl_Users` (
  41. `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  42. `display_name` varchar(255) NOT NULL DEFAULT '',
  43. `email` varchar(255) NOT NULL DEFAULT '',
  44. `password` varchar(255) NOT NULL DEFAULT '',
  45. `type` varchar(50) NOT NULL DEFAULT '',
  46. `label` varchar(255) DEFAULT NULL,
  47. `url` varchar(255) DEFAULT NULL,
  48. `avatar` varchar(255) DEFAULT NULL,
  49. `github` varchar(255) DEFAULT NULL,
  50. `twitter` varchar(255) DEFAULT NULL,
  51. `facebook` varchar(255) DEFAULT NULL,
  52. `google` varchar(255) DEFAULT NULL,
  53. `weibo` varchar(255) DEFAULT NULL,
  54. `qq` varchar(255) DEFAULT NULL,
  55. `2fa` varchar(32) DEFAULT NULL,
  56. `createdAt` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
  57. `updatedAt` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
  58. PRIMARY KEY (`id`)
  59. ) CHARSET=utf8mb4;