text: /*
   Navicat Premium Data Transfer
  
   Source Server         : local
   Source Server Type    : MySQL
   Source Server Version : 50722
   Source Host           : localhost:3306
   Source Schema         : laravel-shop
  
   Target Server Type    : MySQL
   Target Server Version : 50722
   File Encoding         : 65001
  
   Date: 22/01/2019 10:07:12
  */
  
  SET NAMES utf8mb4;
  SET FOREIGN_KEY_CHECKS = 0;
  
  -- ----------------------------
  -- Table structure for admin_menu
  -- ----------------------------
  DROP TABLE IF EXISTS `admin_menu`;
  CREATE TABLE `admin_menu`  (
    `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT,
    `parent_id` int(11) NOT NULL DEFAULT 0,
    `order` int(11) NOT NULL DEFAULT 0,
    `title` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
    `icon` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
    `uri` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NULL DEFAULT NULL,
    `permission` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NULL DEFAULT NULL,
    `created_at` timestamp(0) NULL DEFAULT NULL,
    `updated_at` timestamp(0) NULL DEFAULT NULL,
    PRIMARY KEY (`id`) USING BTREE
  ) ENGINE = InnoDB AUTO_INCREMENT = 16 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic;
  
  -- ----------------------------
  -- Records of admin_menu
  -- ----------------------------
  INSERT INTO `admin_menu` VALUES (1, 0, 1, '首页', 'fa-bar-chart', '/', NULL, NULL, NULL);
  INSERT INTO `admin_menu` VALUES (2, 0, 8, '系统管理', 'fa-tasks', '', NULL, NULL, '2019-01-17 11:51:35');
  INSERT INTO `admin_menu` VALUES (3, 2, 9, '管理员', 'fa-users', 'auth/users', NULL, NULL, '2019-01-17 11:51:35');
  INSERT INTO `admin_menu` VALUES (4, 2, 10, '角色', 'fa-user', 'auth/roles', NULL, NULL, '2019-01-17 11:51:35');
  INSERT INTO `admin_menu` VALUES (5, 2, 11, '权限', 'fa-ban', 'auth/permissions', NULL, NULL, '2019-01-17 11:51:35');
  INSERT INTO `admin_menu` VALUES (6, 2, 12, '菜单', 'fa-bars', 'auth/menu', NULL, NULL, '2019-01-17 11:51:35');
  INSERT INTO `admin_menu` VALUES (7, 2, 13, '操作日志', 'fa-history', 'auth/logs', NULL, NULL, '2019-01-17 11:51:35');
  INSERT INTO `admin_menu` VALUES (8, 0, 2, '用户管理', 'fa-users', '/users', NULL, '2019-01-10 14:28:25', '2019-01-10 14:28:39');
  INSERT INTO `admin_menu` VALUES (9, 0, 3, '商品管理', 'fa-cubes', '/products', NULL, '2019-01-10 14:41:53', '2019-01-10 14:42:11');
  INSERT INTO `admin_menu` VALUES (10, 0, 6, '订单管理', 'fa-rmb', '/orders', NULL, '2019-01-11 16:41:56', '2019-01-17 11:51:35');
  INSERT INTO `admin_menu` VALUES (11, 0, 7, '优惠券菜单', 'fa-tags', '/coupon_codes', NULL, '2019-01-12 11:02:54', '2019-01-17 11:51:35');
  INSERT INTO `admin_menu` VALUES (12, 0, 5, '类目管理', 'fa-bars', '/categories', NULL, '2019-01-16 17:18:43', '2019-01-17 11:51:35');
  INSERT INTO `admin_menu` VALUES (13, 9, 4, '众筹商品', 'fa-flag-checkered', '/crowdfunding_products', NULL, '2019-01-17 11:50:31', '2019-01-17 11:51:35');
  INSERT INTO `admin_menu` VALUES (14, 9, 0, '普通商品', 'fa-cubes', '/products', NULL, '2019-01-17 11:52:05', '2019-01-17 11:52:05');
  INSERT INTO `admin_menu` VALUES (15, 9, 0, '秒杀商品', 'fa-bolt', '/seckill_products', NULL, '2019-01-22 10:03:07', '2019-01-22 10:03:07');
  
  -- ----------------------------
  -- Table structure for admin_permissions
  -- ----------------------------
  DROP TABLE IF EXISTS `admin_permissions`;
  CREATE TABLE `admin_permissions`  (
    `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT,
    `name` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
    `slug` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
    `http_method` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NULL DEFAULT NULL,
    `http_path` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NULL,
    `created_at` timestamp(0) NULL DEFAULT NULL,
    `updated_at` timestamp(0) NULL DEFAULT NULL,
    PRIMARY KEY (`id`) USING BTREE,
    UNIQUE INDEX `admin_permissions_name_unique`(`name`) USING BTREE
  ) ENGINE = InnoDB AUTO_INCREMENT = 7 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic;
  
  -- ----------------------------
  -- Records of admin_permissions
  -- ----------------------------
  INSERT INTO `admin_permissions` VALUES (1, '所有权限', '*', '', '*', NULL, NULL);
  INSERT INTO `admin_permissions` VALUES (2, '仪表盘', 'dashboard', 'GET', '/', NULL, NULL);
  INSERT INTO `admin_permissions` VALUES (3, '登录', 'auth.login', '', '/auth/login\r\n/auth/logout', NULL, NULL);
  INSERT INTO `admin_permissions` VALUES (4, '个人设置', 'auth.setting', 'GET,PUT', '/auth/setting', NULL, NULL);
  INSERT INTO `admin_permissions` VALUES (5, '权限管理', 'auth.management', '', '/auth/roles\r\n/auth/permissions\r\n/auth/menu\r\n/auth/logs', NULL, NULL);
  INSERT INTO `admin_permissions` VALUES (6, '用户管理', 'users', '', '/users*', '2019-01-10 14:30:03', '2019-01-10 14:33:51');
  
  -- ----------------------------
  -- Table structure for admin_role_menu
  -- ----------------------------
  DROP TABLE IF EXISTS `admin_role_menu`;
  CREATE TABLE `admin_role_menu`  (
    `role_id` int(11) NOT NULL,
    `menu_id` int(11) NOT NULL,
    `created_at` timestamp(0) NULL DEFAULT NULL,
    `updated_at` timestamp(0) NULL DEFAULT NULL,
    INDEX `admin_role_menu_role_id_menu_id_index`(`role_id`, `menu_id`) USING BTREE
  ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic;
  
  -- ----------------------------
  -- Records of admin_role_menu
  -- ----------------------------
  INSERT INTO `admin_role_menu` VALUES (1, 2, NULL, NULL);
  
  -- ----------------------------
  -- Table structure for admin_role_permissions
  -- ----------------------------
  DROP TABLE IF EXISTS `admin_role_permissions`;
  CREATE TABLE `admin_role_permissions`  (
    `role_id` int(11) NOT NULL,
    `permission_id` int(11) NOT NULL,
    `created_at` timestamp(0) NULL DEFAULT NULL,
    `updated_at` timestamp(0) NULL DEFAULT NULL,
    INDEX `admin_role_permissions_role_id_permission_id_index`(`role_id`, `permission_id`) USING BTREE
  ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic;
  
  -- ----------------------------
  -- Records of admin_role_permissions
  -- ----------------------------
  INSERT INTO `admin_role_permissions` VALUES (1, 1, NULL, NULL);
  INSERT INTO `admin_role_permissions` VALUES (2, 2, NULL, NULL);
  INSERT INTO `admin_role_permissions` VALUES (2, 3, NULL, NULL);
  INSERT INTO `admin_role_permissions` VALUES (2, 4, NULL, NULL);
  INSERT INTO `admin_role_permissions` VALUES (2, 6, NULL, NULL);
  
  -- ----------------------------
  -- Table structure for admin_role_users
  -- ----------------------------
  DROP TABLE IF EXISTS `admin_role_users`;
  CREATE TABLE `admin_role_users`  (
    `role_id` int(11) NOT NULL,
    `user_id` int(11) NOT NULL,
    `created_at` timestamp(0) NULL DEFAULT NULL,
    `updated_at` timestamp(0) NULL DEFAULT NULL,
    INDEX `admin_role_users_role_id_user_id_index`(`role_id`, `user_id`) USING BTREE
  ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic;
  
  -- ----------------------------
  -- Records of admin_role_users
  -- ----------------------------
  INSERT INTO `admin_role_users` VALUES (1, 1, NULL, NULL);
  INSERT INTO `admin_role_users` VALUES (2, 2, NULL, NULL);
  
  -- ----------------------------
  -- Table structure for admin_roles
  -- ----------------------------
  DROP TABLE IF EXISTS `admin_roles`;
  CREATE TABLE `admin_roles`  (
    `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT,
    `name` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
    `slug` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
    `created_at` timestamp(0) NULL DEFAULT NULL,
    `updated_at` timestamp(0) NULL DEFAULT NULL,
    PRIMARY KEY (`id`) USING BTREE,
    UNIQUE INDEX `admin_roles_name_unique`(`name`) USING BTREE
  ) ENGINE = InnoDB AUTO_INCREMENT = 3 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic;
  
  -- ----------------------------
  -- Records of admin_roles
  -- ----------------------------
  INSERT INTO `admin_roles` VALUES (1, 'Administrator', 'administrator', '2019-01-10 13:43:06', '2019-01-10 13:43:06');
  INSERT INTO `admin_roles` VALUES (2, '运营', 'operator', '2019-01-10 14:31:11', '2019-01-10 14:31:11');
  
  -- ----------------------------
  -- Table structure for admin_user_permissions
  -- ----------------------------
  DROP TABLE IF EXISTS `admin_user_permissions`;
  CREATE TABLE `admin_user_permissions`  (
    `user_id` int(11) NOT NULL,
    `permission_id` int(11) NOT NULL,
    `created_at` timestamp(0) NULL DEFAULT NULL,
    `updated_at` timestamp(0) NULL DEFAULT NULL,
    INDEX `admin_user_permissions_user_id_permission_id_index`(`user_id`, `permission_id`) USING BTREE
  ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic;
  
  -- ----------------------------
  -- Table structure for admin_users
  -- ----------------------------
  DROP TABLE IF EXISTS `admin_users`;
  CREATE TABLE `admin_users`  (
    `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT,
    `username` varchar(190) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
    `password` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
    `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
    `avatar` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NULL DEFAULT NULL,
    `remember_token` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NULL DEFAULT NULL,
    `created_at` timestamp(0) NULL DEFAULT NULL,
    `updated_at` timestamp(0) NULL DEFAULT NULL,
    PRIMARY KEY (`id`) USING BTREE,
    UNIQUE INDEX `admin_users_username_unique`(`username`) USING BTREE
  ) ENGINE = InnoDB AUTO_INCREMENT = 3 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci ROW_FORMAT = Dynamic;
  
  -- ----------------------------
  -- Records of admin_users
  -- ----------------------------
  INSERT INTO `admin_users` VALUES (1, 'admin', '$2y$10$LG1MIZk.1tDi5La1EU/toOuCJV.u.CzNy1I7Pxz3xzwZCcjeoqtQW', 'Administrator', NULL, 'Xv0r0CufM0sFX8sbjlZ7lqj2INfQqhbQqiHNHvm0Ah107ZzSBftyZgRrWpcc', '2019-01-10 13:43:06', '2019-01-10 13:43:06');
  INSERT INTO `admin_users` VALUES (2, 'operator', '$2y$10$FZBBIK6PPGM2.GGDgKEbzeLpIASQKl1RKDEFKruI/j.gkbtxxu7/e', '运营', NULL, 'ZJtAauiayKsuOsNDxZbMlEf5HqcbiSx0nqJt9hxjMrWYHGzBNZLMzPxKSdn1', '2019-01-10 14:32:12', '2019-01-10 14:32:12');
  
  SET FOREIGN_KEY_CHECKS = 1;
  