wiki_api.sql 6.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175
  1. /*
  2. Navicat MySQL Data Transfer
  3. Source Server : 101.132.183.215-tossboy
  4. Source Server Version : 50556
  5. Source Host : 101.132.183.215:3306
  6. Source Database : wiki_api
  7. Target Server Type : MYSQL
  8. Target Server Version : 50556
  9. File Encoding : 65001
  10. Date: 2017-11-08 17:33:32
  11. */
  12. SET FOREIGN_KEY_CHECKS=0;
  13. -- ----------------------------
  14. -- Table structure for api_admin_user
  15. -- ----------------------------
  16. DROP TABLE IF EXISTS `api_admin_user`;
  17. CREATE TABLE `api_admin_user` (
  18. `id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '用户ID',
  19. `user_name` varchar(255) NOT NULL COMMENT '用户名',
  20. `user_password` char(32) NOT NULL COMMENT '密码',
  21. `user_login` int(10) unsigned NOT NULL DEFAULT '0' COMMENT '登录次数',
  22. `user_reg_ip` varchar(25) NOT NULL DEFAULT '0' COMMENT '注册IP',
  23. `user_mobile` varchar(20) DEFAULT '' COMMENT '用户手机',
  24. `last_login_ip` varchar(25) NOT NULL DEFAULT '0' COMMENT '最后登录IP',
  25. `user_header_img` varchar(255) DEFAULT '' COMMENT '用户头像160*160',
  26. `user_group` int(10) unsigned DEFAULT '0' COMMENT '用户所属权限组 对应auth_group id',
  27. `user_status` tinyint(1) DEFAULT '1' COMMENT '用户状态 1正常 2禁用',
  28. `create_time` int(11) unsigned zerofill NOT NULL COMMENT '创建时间',
  29. `update_time` int(11) unsigned zerofill NOT NULL COMMENT '更新时间',
  30. PRIMARY KEY (`id`)
  31. ) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8 COMMENT='后台用户表';
  32. -- ----------------------------
  33. -- Records of api_admin_user
  34. -- ----------------------------
  35. INSERT INTO `api_admin_user` VALUES ('1', 'admin', '3ad1e7e6d9e390e38ba304cfc5ddc977', '1', '0', '', '180.117.23.210', '/img/head.png', '0', '1', '00000000000', '01510133008');
  36. -- ----------------------------
  37. -- Table structure for api_date_type
  38. -- ----------------------------
  39. DROP TABLE IF EXISTS `api_date_type`;
  40. CREATE TABLE `api_date_type` (
  41. `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  42. `type_name` varchar(60) DEFAULT NULL COMMENT '数据类型',
  43. `create_time` int(11) unsigned DEFAULT NULL,
  44. `update_time` int(11) unsigned DEFAULT NULL,
  45. PRIMARY KEY (`id`)
  46. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='接口数据类型';
  47. -- ----------------------------
  48. -- Records of api_date_type
  49. -- ----------------------------
  50. -- ----------------------------
  51. -- Table structure for api_project
  52. -- ----------------------------
  53. DROP TABLE IF EXISTS `api_project`;
  54. CREATE TABLE `api_project` (
  55. `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  56. `project_name` varchar(30) DEFAULT '' COMMENT '项目名称',
  57. `project_icon` varchar(60) DEFAULT NULL COMMENT '项目图标',
  58. `project_about` varchar(60) DEFAULT '' COMMENT '项目简介',
  59. `create_time` int(11) unsigned DEFAULT '0',
  60. `update_time` int(11) unsigned DEFAULT '0',
  61. PRIMARY KEY (`id`)
  62. ) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8 COMMENT='项目表';
  63. -- ----------------------------
  64. -- Records of api_project
  65. -- ----------------------------
  66. INSERT INTO `api_project` VALUES ('1', '50°', '', '50度', '1510133036', '1510133036');
  67. -- ----------------------------
  68. -- Table structure for api_project_api
  69. -- ----------------------------
  70. DROP TABLE IF EXISTS `api_project_api`;
  71. CREATE TABLE `api_project_api` (
  72. `id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '接口编号',
  73. `project_module_id` int(11) DEFAULT NULL COMMENT '模块id',
  74. `project_id` int(11) DEFAULT NULL COMMENT '项目id',
  75. `project_cate_id` int(11) DEFAULT '0' COMMENT '接口分类id',
  76. `api_url` varchar(100) DEFAULT NULL COMMENT '请求地址',
  77. `api_name` varchar(100) DEFAULT NULL COMMENT '接口名',
  78. `api_des` varchar(300) DEFAULT NULL COMMENT '接口描述',
  79. `api_parameter` text COMMENT '请求参数{所有的主求参数,以json格式在此存放}',
  80. `api_parameter_json` text COMMENT '请求参数的json格式',
  81. `api_re` text COMMENT '返回值{以json格式在此存放}',
  82. `api_re_json` text COMMENT '返回数据的json格式',
  83. `api_isdel` tinyint(4) unsigned DEFAULT '0' COMMENT '{0:正常,1:删除}',
  84. `project_url_id` int(11) NOT NULL COMMENT '项目url域名前缀id',
  85. `api_oeder` int(11) DEFAULT '0' COMMENT '排序(值越大,越靠前)',
  86. `request_type_id` int(11) NOT NULL COMMENT '请求类型id',
  87. `api_memo` text COMMENT '备注',
  88. `update_time` int(11) unsigned DEFAULT NULL COMMENT '最后操作时间',
  89. `create_time` int(11) unsigned DEFAULT NULL,
  90. PRIMARY KEY (`id`)
  91. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='接口明细表';
  92. -- ----------------------------
  93. -- Records of api_project_api
  94. -- ----------------------------
  95. -- ----------------------------
  96. -- Table structure for api_project_cate
  97. -- ----------------------------
  98. DROP TABLE IF EXISTS `api_project_cate`;
  99. CREATE TABLE `api_project_cate` (
  100. `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  101. `cate_name` varchar(60) DEFAULT NULL,
  102. `project_id` int(11) NOT NULL COMMENT '项目id',
  103. `project_module_id` int(11) DEFAULT NULL,
  104. `create_time` int(11) unsigned DEFAULT '0',
  105. `update_time` int(11) unsigned DEFAULT '0',
  106. PRIMARY KEY (`id`)
  107. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='项目模块->分类表';
  108. -- ----------------------------
  109. -- Records of api_project_cate
  110. -- ----------------------------
  111. -- ----------------------------
  112. -- Table structure for api_project_module
  113. -- ----------------------------
  114. DROP TABLE IF EXISTS `api_project_module`;
  115. CREATE TABLE `api_project_module` (
  116. `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  117. `model_name` varchar(60) DEFAULT NULL COMMENT '项目模块名',
  118. `project_id` int(11) DEFAULT NULL COMMENT '项目id',
  119. `create_time` int(11) unsigned DEFAULT '0',
  120. `update_time` int(11) unsigned DEFAULT '0',
  121. PRIMARY KEY (`id`)
  122. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='项目模块表';
  123. -- ----------------------------
  124. -- Records of api_project_module
  125. -- ----------------------------
  126. -- ----------------------------
  127. -- Table structure for api_project_url
  128. -- ----------------------------
  129. DROP TABLE IF EXISTS `api_project_url`;
  130. CREATE TABLE `api_project_url` (
  131. `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  132. `project_id` int(11) NOT NULL COMMENT '项目id',
  133. `url_domain` varchar(60) NOT NULL COMMENT '项目域名',
  134. `create_time` int(11) unsigned DEFAULT '0',
  135. `update_time` int(11) unsigned DEFAULT '0',
  136. PRIMARY KEY (`id`)
  137. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='项目域名表';
  138. -- ----------------------------
  139. -- Records of api_project_url
  140. -- ----------------------------
  141. -- ----------------------------
  142. -- Table structure for api_request_type
  143. -- ----------------------------
  144. DROP TABLE IF EXISTS `api_request_type`;
  145. CREATE TABLE `api_request_type` (
  146. `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  147. `type_name` varchar(60) DEFAULT NULL COMMENT '请求类型',
  148. `create_time` int(11) unsigned DEFAULT NULL,
  149. `update_time` int(11) unsigned DEFAULT NULL,
  150. PRIMARY KEY (`id`)
  151. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='接口请求类型';
  152. -- ----------------------------
  153. -- Records of api_request_type
  154. -- ----------------------------