demofancyecommerce.sql 7.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153
  1. CREATE TABLE IF NOT EXISTS `admin_menu` (
  2. `id` int(15) NOT NULL AUTO_INCREMENT,
  3. `name` varchar(150) DEFAULT NULL,
  4. `level` int(5) DEFAULT NULL,
  5. `parent_id` int(15) DEFAULT NULL,
  6. `url_key` varchar(255) DEFAULT NULL,
  7. `role_key` varchar(150) DEFAULT NULL COMMENT '权限key,也就是controller的路径,譬如/fecadmin/menu/managere,controller 是MenuController,当前的值为:/fecadmin/menu',
  8. `created_at` datetime DEFAULT NULL,
  9. `updated_at` datetime DEFAULT NULL,
  10. `sort_order` int(10) NOT NULL DEFAULT '0',
  11. `can_delete` int(5) DEFAULT '2' COMMENT '是否可以被删除,1代表不可以删除,2代表可以删除',
  12. PRIMARY KEY (`id`)
  13. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=177 ;
  14. --
  15. -- 转存表中的数据 `admin_menu`
  16. --
  17. INSERT INTO `admin_menu` (`id`, `name`, `level`, `parent_id`, `url_key`, `role_key`, `created_at`, `updated_at`, `sort_order`, `can_delete`) VALUES
  18. (164, '控制面板', 1, 0, '/ddd', NULL, '2016-01-15 10:21:36', '2016-01-15 10:21:36', 0, 1),
  19. (165, '用户管理', 2, 164, '/ddd', NULL, '2016-01-15 10:23:01', '2016-01-15 10:23:01', 0, 1),
  20. (166, '菜单管理', 2, 164, '/fecadmin/menu/manager', '/fecadmin/menu', '2016-01-15 10:23:22', '2016-01-16 16:45:23', 0, 1),
  21. (167, '我的账户', 3, 165, '/fecadmin/myaccount/index', '/fecadmin/myaccount', '2016-01-15 10:24:29', '2016-01-16 16:07:58', 0, 1),
  22. (168, '账户管理', 3, 165, '/fecadmin/account/manager', '/fecadmin/account', '2016-01-15 10:24:51', '2016-01-21 15:24:18', 0, 1),
  23. (169, '权限管理', 3, 165, '/fecadmin/role/manager', '/fecadmin/role', '2016-01-15 10:25:10', '2016-01-21 13:22:39', 0, 1),
  24. (170, '操作日志', 2, 164, '/fecadmin/log/index', '/fecadmin/log', '2016-01-15 10:35:19', '2016-01-16 16:45:18', 0, 1),
  25. (171, '缓存管理', 2, 164, '/fecadmin/cache/index', '/fecadmin/cache', '2016-01-15 10:35:40', '2016-01-16 16:45:14', 0, 1),
  26. (172, '后台管理应用Example', 1, 0, '/manager/admin', '/manager', '2016-01-18 10:59:51', '2016-01-18 10:59:51', 0, 2),
  27. (173, 'grid示例', 2, 172, '/fecadmin/grid/example', '/fecadmin/grid', '2016-01-18 11:00:36', '2016-01-18 11:00:36', 0, 2),
  28. (176, 'sd', 1, 0, 'asd', '', '2016-01-21 15:36:28', '2016-01-21 15:36:28', 0, 2);
  29. -- --------------------------------------------------------
  30. --
  31. -- 表的结构 `admin_role`
  32. --
  33. CREATE TABLE IF NOT EXISTS `admin_role` (
  34. `role_id` int(15) NOT NULL AUTO_INCREMENT,
  35. `role_name` varchar(100) CHARACTER SET utf8 DEFAULT NULL COMMENT '权限名字',
  36. `role_description` varchar(255) CHARACTER SET utf8 DEFAULT NULL COMMENT '权限描述',
  37. PRIMARY KEY (`role_id`)
  38. ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=14 ;
  39. --
  40. -- 转存表中的数据 `admin_role`
  41. --
  42. INSERT INTO `admin_role` (`role_id`, `role_name`, `role_description`) VALUES
  43. (4, 'admin', '超级用户'),
  44. (12, '账户管理员', '账户管理员'),
  45. (13, 'ceshi', 'ceshi');
  46. -- --------------------------------------------------------
  47. --
  48. -- 表的结构 `admin_role_menu`
  49. --
  50. CREATE TABLE IF NOT EXISTS `admin_role_menu` (
  51. `id` int(15) NOT NULL AUTO_INCREMENT,
  52. `menu_id` int(15) NOT NULL,
  53. `role_id` int(15) NOT NULL,
  54. `created_at` datetime DEFAULT NULL,
  55. `updated_at` datetime DEFAULT NULL,
  56. PRIMARY KEY (`id`)
  57. ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=61 ;
  58. --
  59. -- 转存表中的数据 `admin_role_menu`
  60. --
  61. INSERT INTO `admin_role_menu` (`id`, `menu_id`, `role_id`, `created_at`, `updated_at`) VALUES
  62. (4, 164, 4, '2016-01-16 11:19:15', '2016-01-16 11:19:15'),
  63. (33, 165, 12, '2016-01-16 12:05:01', '2016-01-16 12:05:01'),
  64. (34, 167, 12, '2016-01-16 12:05:01', '2016-01-16 12:05:01'),
  65. (36, 169, 12, '2016-01-16 12:05:01', '2016-01-16 12:05:01'),
  66. (37, 164, 12, '2016-01-16 12:05:01', '2016-01-16 12:05:01'),
  67. (38, 165, 4, '2016-01-16 14:46:17', '2016-01-16 14:46:17'),
  68. (39, 167, 4, '2016-01-16 14:46:17', '2016-01-16 14:46:17'),
  69. (41, 169, 4, '2016-01-16 14:46:17', '2016-01-16 14:46:17'),
  70. (43, 171, 4, '2016-01-16 14:46:17', '2016-01-16 14:46:17'),
  71. (46, 166, 4, '2016-01-16 17:47:30', '2016-01-16 17:47:30'),
  72. (49, 168, 4, '2016-01-18 12:16:49', '2016-01-18 12:16:49'),
  73. (50, 170, 4, '2016-01-18 12:16:49', '2016-01-18 12:16:49'),
  74. (51, 164, 13, '2016-01-21 14:12:09', '2016-01-21 14:12:09'),
  75. (52, 165, 13, '2016-01-21 14:12:09', '2016-01-21 14:12:09'),
  76. (53, 167, 13, '2016-01-21 14:12:09', '2016-01-21 14:12:09'),
  77. (54, 168, 13, '2016-01-21 14:12:09', '2016-01-21 14:12:09'),
  78. (55, 169, 13, '2016-01-21 14:12:09', '2016-01-21 14:12:09'),
  79. (56, 166, 13, '2016-01-21 14:12:09', '2016-01-21 14:12:09'),
  80. (57, 170, 13, '2016-01-21 14:12:09', '2016-01-21 14:12:09'),
  81. (58, 171, 13, '2016-01-21 14:12:09', '2016-01-21 14:12:09');
  82. -- --------------------------------------------------------
  83. --
  84. -- 表的结构 `admin_user`
  85. --
  86. CREATE TABLE IF NOT EXISTS `admin_user` (
  87. `id` int(20) unsigned NOT NULL AUTO_INCREMENT,
  88. `username` varchar(50) DEFAULT NULL COMMENT '用户名',
  89. `password_hash` varchar(80) DEFAULT NULL COMMENT '密码',
  90. `password_reset_token` varchar(60) DEFAULT NULL COMMENT '密码token',
  91. `email` varchar(60) DEFAULT NULL COMMENT '邮箱',
  92. `person` varchar(100) DEFAULT NULL COMMENT '用户姓名',
  93. `auth_key` varchar(60) DEFAULT NULL,
  94. `status` int(5) DEFAULT NULL COMMENT '状态',
  95. `created_at` int(18) DEFAULT NULL COMMENT '创建时间',
  96. `updated_at` int(18) DEFAULT NULL COMMENT '更新时间',
  97. `password` varchar(50) DEFAULT NULL COMMENT '密码',
  98. `role` varchar(50) DEFAULT NULL COMMENT 'role',
  99. `access_token` varchar(60) DEFAULT NULL,
  100. `allowance` int(20) DEFAULT NULL,
  101. `allowance_updated_at` int(20) DEFAULT NULL,
  102. `created_at_datetime` datetime DEFAULT NULL,
  103. `updated_at_datetime` datetime DEFAULT NULL,
  104. `birth_date` datetime DEFAULT NULL COMMENT '出生日期',
  105. PRIMARY KEY (`id`),
  106. UNIQUE KEY `username` (`username`),
  107. UNIQUE KEY `access_token` (`access_token`)
  108. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=3 ;
  109. --
  110. -- 转存表中的数据 `admin_user`
  111. --
  112. INSERT INTO `admin_user` (`id`, `username`, `password_hash`, `password_reset_token`, `email`, `person`, `auth_key`, `status`, `created_at`, `updated_at`, `password`, `role`, `access_token`, `allowance`, `allowance_updated_at`, `created_at_datetime`, `updated_at_datetime`, `birth_date`) VALUES
  113. (1, 'terry', '$2y$13$EyK1HyJtv4A/19Jb8gB5y.4SQm5y93eMeHjUf35ryLyd2dWPJlh8y', NULL, 'zqy234@126.com', NULL, 'HH-ZlZXirlG-egyz8OTtl9EVj9fvKW00', 1, 1441763620, 1452928074, '', '12', 'yrYWR7kY-A9bUAP6UUZgCR3yi3ALtUh-', 599, 1452491877, '2016-01-12 09:41:44', '2016-01-16 15:07:54', NULL),
  114. (2, 'admin', '$2y$13$GRSm4Tyd5nQ0hYkTB9B2eOW0uJcmV.PMAVHiC3oFYoDjsRiahaCte', NULL, '3727@qq.com', '超级管理员', '_PYjb4PdIIY332LquBRC5tClZUXV0zm_', 1, NULL, 1453361905, '', '4', '1Gk6ZNn-QaBaKFI4uE2bSw0w3N7ej72q', NULL, NULL, '2016-01-11 09:41:52', '2016-01-18 15:06:25', NULL);
  115. -- --------------------------------------------------------
  116. --
  117. -- 表的结构 `admin_visit_log`
  118. --
  119. CREATE TABLE IF NOT EXISTS `admin_visit_log` (
  120. `id` int(15) NOT NULL AUTO_INCREMENT,
  121. `account` varchar(25) DEFAULT NULL COMMENT '操作账号',
  122. `person` varchar(25) DEFAULT NULL COMMENT '操作人姓名',
  123. `created_at` datetime DEFAULT NULL COMMENT '操作时间',
  124. `menu` varchar(100) DEFAULT NULL COMMENT '菜单',
  125. `url` varchar(255) DEFAULT NULL COMMENT 'URL',
  126. `url_key` varchar(150) DEFAULT NULL COMMENT '参数',
  127. PRIMARY KEY (`id`)
  128. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
  129. --
  130. -- 转存表中的数据 `admin_visit_log`
  131. --