代码拉取完成,页面将自动刷新
/*
Navicat Premium Data Transfer
Source Server : 本机
Source Server Type : MySQL
Source Server Version : 80030 (8.0.30)
Source Host : localhost:3306
Source Schema : jinju
Target Server Type : MySQL
Target Server Version : 80030 (8.0.30)
File Encoding : 65001
Date: 21/05/2024 10:29:11
*/
SET NAMES utf8mb4;
SET FOREIGN_KEY_CHECKS = 0;
-- ----------------------------
-- Table structure for goods
-- ----------------------------
DROP TABLE IF EXISTS `goods`;
CREATE TABLE `goods` (
`id` int UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '商品id',
`name` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NOT NULL COMMENT '商品名称',
`image` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NOT NULL COMMENT '图像',
`category` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NOT NULL COMMENT '商品类别',
`price` double NOT NULL COMMENT '价格',
`introduction` varchar(500) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NOT NULL COMMENT '商品简介',
`status` tinyint UNSIGNED NOT NULL DEFAULT 0 COMMENT '商品状态:0 待审核 1 已通过 2 已下架',
`number` tinyint UNSIGNED NOT NULL COMMENT '库存',
`p_id` int UNSIGNED NOT NULL COMMENT '用户id',
`create_time` datetime NOT NULL COMMENT '创建时间',
`update_time` datetime NOT NULL COMMENT '修改时间',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 9 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_0900_ai_ci COMMENT = '商品表' ROW_FORMAT = Dynamic;
-- ----------------------------
-- Table structure for orders
-- ----------------------------
DROP TABLE IF EXISTS `orders`;
CREATE TABLE `orders` (
`id` int UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '订单id',
`total_price` double NOT NULL COMMENT '总价',
`status` tinyint UNSIGNED NOT NULL DEFAULT 0 COMMENT '状态:0 待支付 1 已支付 2 已取消',
`g_id` int UNSIGNED NOT NULL COMMENT '商品id',
`b_id` int UNSIGNED NOT NULL COMMENT '买家id',
`s_id` int UNSIGNED NOT NULL COMMENT '卖家id',
`number` tinyint UNSIGNED NOT NULL COMMENT '商品数量',
`create_time` datetime NOT NULL COMMENT '创建时间',
`finish_time` datetime NULL DEFAULT NULL COMMENT '完成时间',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 9 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_0900_ai_ci COMMENT = '订单表' ROW_FORMAT = Dynamic;
-- ----------------------------
-- Table structure for people
-- ----------------------------
DROP TABLE IF EXISTS `people`;
CREATE TABLE `people` (
`id` int UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '人员id',
`username` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NOT NULL COMMENT '用户名',
`password` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NOT NULL COMMENT '密码',
`name` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '姓名',
`gender` tinyint UNSIGNED NULL DEFAULT NULL COMMENT '性别:0 男 1 女',
`image` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '头像',
`phone` char(11) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '联系电话',
`money` double NULL DEFAULT 0 COMMENT '钱包',
`role` tinyint UNSIGNED NOT NULL DEFAULT 1 COMMENT '角色:0 管理员 1 用户',
`create_time` datetime NOT NULL COMMENT '创建时间',
`update_time` datetime NOT NULL COMMENT '修改时间',
PRIMARY KEY (`id`) USING BTREE,
UNIQUE INDEX `username`(`username` ASC) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 7 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_0900_ai_ci COMMENT = '人员表' ROW_FORMAT = Dynamic;
-- ----------------------------
-- Table structure for shoppingcart
-- ----------------------------
DROP TABLE IF EXISTS `shoppingcart`;
CREATE TABLE `shoppingcart` (
`id` int UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '购物车id',
`g_id` int UNSIGNED NOT NULL COMMENT '商品id',
`b_id` int UNSIGNED NOT NULL COMMENT '买家id',
`s_id` int UNSIGNED NOT NULL COMMENT '卖家id',
`number` tinyint UNSIGNED NOT NULL COMMENT '数量',
`total_price` double NOT NULL COMMENT '总价',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 4 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_0900_ai_ci COMMENT = '购物车表' ROW_FORMAT = Dynamic;
SET FOREIGN_KEY_CHECKS = 1;
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。