From 0546776bdfab17963c5a274d9c49da856d1c4869 Mon Sep 17 00:00:00 2001
From: bunny <1319900154@qq.com>
Date: Sat, 16 Dec 2023 19:19:22 +0800
Subject: [PATCH] =?UTF-8?q?=E5=95=86=E5=93=81=E7=AE=A1=E7=90=86=E6=B7=BB?=
=?UTF-8?q?=E5=8A=A0=E5=88=A0=E9=99=A4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.idea/dataSources.local.xml | 20 +
.../3eae447a-3ae1-4be3-aa70-1183cffb0765.xml | 3295 +++++++++++++++++
.../_src_/schema/db_spzx.fMWaVg.meta | 2 +
.../schema/information_schema.FNRwLQ.meta | 2 +
.../storage_v2/_src_/schema/mysql.osA4Bg.meta | 2 +
.../schema/performance_schema.kIw0nw.meta | 2 +
.../storage_v2/_src_/schema/sys.zb4BAA.meta | 2 +
.idea/inspectionProfiles/Project_Default.xml | 3 +
.idea/workspace.xml | 160 +
.../bunny/controller/ProductController.java | 27 +-
.../controller/ProductSpecController.java | 9 +
.../controller/ProductUntilController.java | 30 +
.../cn/bunny/mapper/ProductDetailMapper.java | 15 +
.../java/cn/bunny/mapper/ProductMapper.java | 9 +
.../cn/bunny/mapper/ProductSkuMapper.java | 17 +
.../cn/bunny/mapper/ProductSpecMapper.java | 3 +
.../cn/bunny/mapper/ProductUntilMapper.java | 12 +
.../java/cn/bunny/service/ProductService.java | 9 +
.../cn/bunny/service/ProductSpecService.java | 5 +
.../cn/bunny/service/ProductUntilService.java | 10 +
.../service/impl/ProductServiceImpl.java | 72 +
.../service/impl/ProductSpecServiceImpl.java | 6 +
.../service/impl/ProductUntilServiceImpl.java | 22 +
.../mapper/product/ProductDetailMapper.xml | 44 +
.../mapper/product/ProductMapper.xml | 81 +-
.../mapper/product/ProductSkuMapper.xml | 99 +
.../mapper/product/ProductSpecMapper.xml | 8 +-
.../mapper/product/ProductUntilMapper.xml | 17 +
28 files changed, 3977 insertions(+), 6 deletions(-)
create mode 100644 .idea/dataSources.local.xml
create mode 100644 .idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765.xml
create mode 100644 .idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/db_spzx.fMWaVg.meta
create mode 100644 .idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/information_schema.FNRwLQ.meta
create mode 100644 .idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/mysql.osA4Bg.meta
create mode 100644 .idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/performance_schema.kIw0nw.meta
create mode 100644 .idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/sys.zb4BAA.meta
create mode 100644 .idea/workspace.xml
create mode 100644 spzx-manager/src/main/java/cn/bunny/controller/ProductUntilController.java
create mode 100644 spzx-manager/src/main/java/cn/bunny/mapper/ProductDetailMapper.java
create mode 100644 spzx-manager/src/main/java/cn/bunny/mapper/ProductSkuMapper.java
create mode 100644 spzx-manager/src/main/java/cn/bunny/mapper/ProductUntilMapper.java
create mode 100644 spzx-manager/src/main/java/cn/bunny/service/ProductUntilService.java
create mode 100644 spzx-manager/src/main/java/cn/bunny/service/impl/ProductUntilServiceImpl.java
create mode 100644 spzx-manager/src/main/resources/mapper/product/ProductDetailMapper.xml
create mode 100644 spzx-manager/src/main/resources/mapper/product/ProductSkuMapper.xml
create mode 100644 spzx-manager/src/main/resources/mapper/product/ProductUntilMapper.xml
diff --git a/.idea/dataSources.local.xml b/.idea/dataSources.local.xml
new file mode 100644
index 0000000..408a33c
--- /dev/null
+++ b/.idea/dataSources.local.xml
@@ -0,0 +1,20 @@
+
+
+
+
+
+ #@
+ `
+ true
+
+
+ master_key
+ root
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765.xml b/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765.xml
new file mode 100644
index 0000000..e5cbcc3
--- /dev/null
+++ b/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765.xml
@@ -0,0 +1,3295 @@
+
+
+
+
+ exact
+ InnoDB
+ InnoDB
+ |root||root||ALTER|G
+|root||root||ALTER ROUTINE|G
+|root||mysql.infoschema|localhost|AUDIT_ABORT_EXEMPT|G
+|root||mysql.session|localhost|AUDIT_ABORT_EXEMPT|G
+|root||mysql.sys|localhost|AUDIT_ABORT_EXEMPT|G
+|root||mysql.session|localhost|BACKUP_ADMIN|G
+|root||mysql.session|localhost|CLONE_ADMIN|G
+|root||mysql.session|localhost|CONNECTION_ADMIN|G
+|root||root||CREATE|G
+|root||root||CREATE ROLE|G
+|root||root||CREATE ROUTINE|G
+|root||root||CREATE TABLESPACE|G
+|root||root||CREATE TEMPORARY TABLES|G
+|root||root||CREATE USER|G
+|root||root||CREATE VIEW|G
+|root||root||DELETE|G
+|root||root||DROP|G
+|root||root||DROP ROLE|G
+|root||root||EVENT|G
+|root||root||EXECUTE|G
+|root||root||FILE|G
+|root||root||INDEX|G
+|root||root||INSERT|G
+|root||root||LOCK TABLES|G
+|root||mysql.session|localhost|PERSIST_RO_VARIABLES_ADMIN|G
+|root||root||PROCESS|G
+|root||root||REFERENCES|G
+|root||root||RELOAD|G
+|root||root||REPLICATION CLIENT|G
+|root||root||REPLICATION SLAVE|G
+|root||mysql.infoschema|localhost|SELECT|G
+|root||root||SELECT|G
+|root||mysql.session|localhost|SESSION_VARIABLES_ADMIN|G
+|root||root||SHOW DATABASES|G
+|root||root||SHOW VIEW|G
+|root||mysql.session|localhost|SHUTDOWN|G
+|root||root||SHUTDOWN|G
+|root||mysql.session|localhost|SUPER|G
+|root||root||SUPER|G
+|root||mysql.infoschema|localhost|SYSTEM_USER|G
+|root||mysql.session|localhost|SYSTEM_USER|G
+|root||mysql.sys|localhost|SYSTEM_USER|G
+|root||mysql.session|localhost|SYSTEM_VARIABLES_ADMIN|G
+|root||root||TRIGGER|G
+|root||root||UPDATE|G
+|root||root||grant option|G
+gitea|schema||gitea||ALTER|G
+gitea|schema||gitea||ALTER ROUTINE|G
+gitea|schema||gitea||CREATE|G
+gitea|schema||gitea||CREATE ROUTINE|G
+gitea|schema||gitea||CREATE TEMPORARY TABLES|G
+gitea|schema||gitea||CREATE VIEW|G
+gitea|schema||gitea||DELETE|G
+gitea|schema||gitea||DROP|G
+gitea|schema||gitea||EVENT|G
+gitea|schema||gitea||EXECUTE|G
+gitea|schema||gitea||INDEX|G
+gitea|schema||gitea||INSERT|G
+gitea|schema||gitea||LOCK TABLES|G
+gitea|schema||gitea||REFERENCES|G
+gitea|schema||gitea||SELECT|G
+gitea|schema||gitea||SHOW VIEW|G
+gitea|schema||gitea||TRIGGER|G
+gitea|schema||gitea||UPDATE|G
+giteadb|schema||gitea||ALTER|G
+giteadb|schema||gitea||ALTER ROUTINE|G
+giteadb|schema||gitea||CREATE|G
+giteadb|schema||gitea||CREATE ROUTINE|G
+giteadb|schema||gitea||CREATE TEMPORARY TABLES|G
+giteadb|schema||gitea||CREATE VIEW|G
+giteadb|schema||gitea||DELETE|G
+giteadb|schema||gitea||DROP|G
+giteadb|schema||gitea||EVENT|G
+giteadb|schema||gitea||EXECUTE|G
+giteadb|schema||gitea||INDEX|G
+giteadb|schema||gitea||INSERT|G
+giteadb|schema||gitea||LOCK TABLES|G
+giteadb|schema||gitea||REFERENCES|G
+giteadb|schema||gitea||SELECT|G
+giteadb|schema||gitea||SHOW VIEW|G
+giteadb|schema||gitea||TRIGGER|G
+giteadb|schema||gitea||UPDATE|G
+performance_schema|schema||mysql.session|localhost|SELECT|G
+sys|schema||mysql.sys|localhost|TRIGGER|G
+ 8.0.28
+
+
+ armscii8
+
+
+ armscii8
+ 1
+
+
+ ascii
+
+
+ ascii
+ 1
+
+
+ big5
+
+
+ big5
+ 1
+
+
+ binary
+ 1
+
+
+ cp1250
+
+
+ cp1250
+
+
+ cp1250
+
+
+ cp1250
+ 1
+
+
+ cp1250
+
+
+ cp1251
+
+
+ cp1251
+
+
+ cp1251
+ 1
+
+
+ cp1251
+
+
+ cp1251
+
+
+ cp1256
+
+
+ cp1256
+ 1
+
+
+ cp1257
+
+
+ cp1257
+ 1
+
+
+ cp1257
+
+
+ cp850
+
+
+ cp850
+ 1
+
+
+ cp852
+
+
+ cp852
+ 1
+
+
+ cp866
+
+
+ cp866
+ 1
+
+
+ cp932
+
+
+ cp932
+ 1
+
+
+ dec8
+
+
+ dec8
+ 1
+
+
+ eucjpms
+
+
+ eucjpms
+ 1
+
+
+ euckr
+
+
+ euckr
+ 1
+
+
+ gb18030
+
+
+ gb18030
+ 1
+
+
+ gb18030
+
+
+ gb2312
+
+
+ gb2312
+ 1
+
+
+ gbk
+
+
+ gbk
+ 1
+
+
+ geostd8
+
+
+ geostd8
+ 1
+
+
+ greek
+
+
+ greek
+ 1
+
+
+ hebrew
+
+
+ hebrew
+ 1
+
+
+ hp8
+
+
+ hp8
+ 1
+
+
+ keybcs2
+
+
+ keybcs2
+ 1
+
+
+ koi8r
+
+
+ koi8r
+ 1
+
+
+ koi8u
+
+
+ koi8u
+ 1
+
+
+ latin1
+
+
+ latin1
+
+
+ latin1
+
+
+ latin1
+
+
+ latin1
+
+
+ latin1
+
+
+ latin1
+
+
+ latin1
+ 1
+
+
+ latin2
+
+
+ latin2
+
+
+ latin2
+
+
+ latin2
+ 1
+
+
+ latin2
+
+
+ latin5
+
+
+ latin5
+ 1
+
+
+ latin7
+
+
+ latin7
+
+
+ latin7
+ 1
+
+
+ latin7
+
+
+ macce
+
+
+ macce
+ 1
+
+
+ macroman
+
+
+ macroman
+ 1
+
+
+ sjis
+
+
+ sjis
+ 1
+
+
+ swe7
+
+
+ swe7
+ 1
+
+
+ tis620
+
+
+ tis620
+ 1
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+ 1
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ucs2
+
+
+ ujis
+
+
+ ujis
+ 1
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+ 1
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16
+
+
+ utf16le
+
+
+ utf16le
+ 1
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+ 1
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf32
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+ 1
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8
+
+
+ utf8mb4
+ 1
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ utf8mb4
+
+
+ 1
+ 2023-12-16.23:57:15
+ 2023-12-16.07:57:14
+ utf8_general_ci
+
+
+ utf8mb4_0900_ai_ci
+
+
+ utf8_general_ci
+
+
+ utf8mb4_0900_ai_ci
+
+
+ utf8mb4_0900_ai_ci
+
+
+ utf8mb4_0900_ai_ci
+
+
+ caching_sha2_password
+
+
+ 0
+ localhost
+ caching_sha2_password
+
+
+ 0
+ localhost
+ caching_sha2_password
+
+
+ 0
+ localhost
+ caching_sha2_password
+
+
+ caching_sha2_password
+
+
+ 分类品牌
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 商品分类
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 分类品牌
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 优惠券信息
+ InnoDB
+ utf8_general_ci
+
+
+ 优惠券范围表
+ InnoDB
+ utf8_general_ci
+
+
+ 优惠券领用表
+ InnoDB
+ utf8_general_ci
+
+
+ 订单
+ InnoDB
+ utf8_general_ci
+
+
+ 订单项信息
+ InnoDB
+ utf8_general_ci
+
+
+ 订单操作日志记录
+ InnoDB
+ utf8_general_ci
+
+
+ 订单统计
+ InnoDB
+ utf8_general_ci
+
+
+ 付款信息表
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 商品
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 商品属性表
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 商品sku属性表
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 商品sku
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 商品规格
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 商品单位
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 地区信息表
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 系统用户登录记录
+ InnoDB
+ utf8_general_ci
+
+
+ 菜单表
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 操作日志记录
+ InnoDB
+ utf8_general_ci
+
+
+ 角色
+ InnoDB
+ utf8_general_ci
+
+
+ 角色菜单
+ InnoDB
+ utf8_general_ci
+
+
+ 用户表
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 用户角色
+ InnoDB
+ utf8_general_ci
+
+
+ 用户地址表
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 用户浏览记录表
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 用户收藏表
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 会员表
+ InnoDB
+ utf8mb4_0900_ai_ci
+
+
+ 5
+ ID
+ bigint|0s
+ 1
+ 1
+
+
+ 品牌名称
+ varchar(100)|0s
+ 2
+ utf8_general_ci
+
+
+ 品牌图标
+ varchar(255)|0s
+ 3
+ utf8_general_ci
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 4
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 5
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 6
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 9992
+ 分类id
+ bigint|0s
+ 1
+ 1
+
+
+ 分类名称
+ varchar(50)|0s
+ 2
+
+
+ varchar(200)|0s
+ 3
+
+
+ 父分类id
+ bigint|0s
+ 4
+
+
+ 是否显示[0-不显示,1显示]
+ tinyint|0s
+ 5
+
+
+ 排序
+ int|0s
+ 6
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 7
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 8
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 9
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 7
+ ID
+ bigint|0s
+ 1
+ 1
+
+
+ 品牌ID
+ bigint|0s
+ 2
+
+
+ 分类ID
+ bigint|0s
+ 3
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 4
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 5
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 6
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 7
+ id
+ bigint|0s
+ 1
+ 1
+
+
+ 购物券类型 1 现金券 2 满减券
+ tinyint|0s
+ 1
+ 1
+ 2
+
+
+ 优惠卷名字
+ varchar(100)|0s
+ 3
+
+
+ 金额
+ decimal(10,2 digit)|0s
+ 0.00
+ 1
+ 4
+
+
+ 使用门槛 0->没门槛
+ decimal(10,2 digit)|0s
+ 0.00
+ 1
+ 5
+
+
+ 可以领取的开始日期
+ date|0s
+ 6
+
+
+ 可以领取的结束日期
+ date|0s
+ 7
+
+
+ 使用范围[1->全场通用;2->指定分类;3->指定商品]
+ tinyint|0s
+ 1
+ 1
+ 8
+
+
+ 使用范围描述
+ varchar(200)|0s
+ 9
+
+
+ 发行数量
+ int|0s
+ 1
+ 1
+ 10
+
+
+ 每人限领张数
+ int|0s
+ 1
+ 1
+ 11
+
+
+ 已使用数量
+ int|0s
+ 0
+ 1
+ 12
+
+
+ 领取数量
+ int|0s
+ 0
+ 1
+ 13
+
+
+ 过期时间
+ datetime|0s
+ 14
+
+
+ 发布状态[0-未发布,1-已发布]
+ tinyint(1)|0s
+ 15
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 16
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 17
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 18
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 7
+ 购物券编号
+ bigint|0s
+ 1
+ 1
+
+
+ 优惠券id
+ bigint|0s
+ 0
+ 1
+ 2
+
+
+ 范围类型; 1->商品(sku) ;2->分类
+ tinyint|0s
+ 1
+ 1
+ 3
+
+
+ bigint|0s
+ 0
+ 1
+ 4
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 5
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 6
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 7
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 17
+ 编号
+ bigint|0s
+ 1
+ 1
+
+
+ 购物券ID
+ bigint|0s
+ 2
+
+
+ 用户ID
+ bigint|0s
+ 3
+
+
+ 订单ID
+ bigint|0s
+ 4
+
+
+ 购物券状态(1:未使用 2:已使用)
+ tinyint|0s
+ 5
+
+
+ 获取类型(1:后台赠送;2:主动获取)
+ tinyint|0s
+ 2
+ 1
+ 6
+
+
+ 获取时间
+ datetime|0s
+ 7
+
+
+ 使用时间
+ datetime|0s
+ 8
+
+
+ 支付时间
+ datetime|0s
+ 9
+
+
+ 过期时间
+ datetime|0s
+ 10
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 11
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 12
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 13
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 210
+ id
+ bigint|0s
+ 1
+ 1
+
+
+ 会员_id
+ bigint|0s
+ 0
+ 1
+ 2
+
+
+ 昵称
+ varchar(200)|0s
+ 3
+
+
+ 订单号
+ char(64)|0s
+ ''
+ 1
+ 4
+
+
+ 使用的优惠券
+ bigint|0s
+ 5
+
+
+ 订单总额
+ decimal(10,2 digit)|0s
+ 0.00
+ 1
+ 6
+
+
+ 优惠券
+ decimal(10,2 digit)|0s
+ 0.00
+ 1
+ 7
+
+
+ 原价金额
+ decimal(10,2 digit)|0s
+ 0.00
+ 1
+ 8
+
+
+ 运费
+ decimal(10,2 digit)|0s
+ 0.00
+ 1
+ 9
+
+
+ 支付方式【1->微信 2->支付宝】
+ tinyint|0s
+ 10
+
+
+ 订单状态【0->待付款;1->待发货;2->已发货;3->待用户收货,已完成;-1->已取消】
+ tinyint|0s
+ 0
+ 1
+ 11
+
+
+ 收货人姓名
+ varchar(100)|0s
+ 12
+
+
+ 收货人电话
+ varchar(32)|0s
+ 13
+
+
+ 收货人地址标签
+ varchar(32)|0s
+ 14
+
+
+ 省份/直辖市
+ bigint|0s
+ 15
+
+
+ 城市
+ bigint|0s
+ 16
+
+
+ 区
+ bigint|0s
+ 17
+
+
+ 详细地址
+ varchar(200)|0s
+ 18
+
+
+ 支付时间
+ datetime|0s
+ 19
+
+
+ 发货时间
+ datetime|0s
+ 20
+
+
+ 确认收货时间
+ datetime|0s
+ 21
+
+
+ 订单备注
+ varchar(500)|0s
+ 22
+
+
+ 取消订单时间
+ datetime|0s
+ 23
+
+
+ 取消订单原因
+ varchar(255)|0s
+ 24
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 25
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 26
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 27
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 446
+ id
+ bigint|0s
+ 1
+ 1
+
+
+ order_id
+ bigint|0s
+ 2
+
+
+ 商品sku编号
+ bigint|0s
+ 3
+
+
+ 商品sku名字
+ varchar(255)|0s
+ 4
+
+
+ 商品sku图片
+ varchar(500)|0s
+ 5
+
+
+ 商品sku价格
+ decimal(10,2 digit)|0s
+ 6
+
+
+ 商品购买的数量
+ int|0s
+ 7
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 8
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 9
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 10
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 217
+ bigint|0s
+ 1
+ 1
+
+
+ 订单id
+ bigint|0s
+ 2
+
+
+ 操作人:用户;系统;后台管理员
+ varchar(100)|0s
+ 3
+
+
+ 订单状态
+ int|0s
+ 4
+
+
+ 备注
+ varchar(500)|0s
+ 5
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 6
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 7
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 8
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 289
+ bigint|0s
+ 1
+ 1
+
+
+ 省份
+ varchar(20)|0s
+ 2
+
+
+ 订单统计日期
+ date|0s
+ 3
+
+
+ 总金额
+ decimal(10,2 digit)|0s
+ 4
+
+
+ 订单总数
+ int|0s
+ 5
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 6
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 7
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 8
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 81
+ 编号
+ int|0s
+ 1
+ 1
+
+
+ 用户id
+ bigint|0s
+ 2
+
+
+ 订单号
+ varchar(50)|0s
+ ''
+ 1
+ 3
+
+
+ 付款方式:1-微信 2-支付宝
+ tinyint|0s
+ 0
+ 1
+ 4
+
+
+ 交易编号(微信或支付)
+ varchar(50)|0s
+ 5
+
+
+ 支付金额
+ decimal(10,2 digit)|0s
+ 6
+
+
+ 交易内容
+ varchar(200)|0s
+ 7
+
+
+ 支付状态:0-未支付 1-已支付
+ char(4)|0s
+ 8
+
+
+ 回调时间
+ datetime|0s
+ 9
+
+
+ 回调信息
+ text|0s
+ 10
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 11
+
+
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 12
+
+
+ tinyint|0s
+ 0
+ 1
+ 13
+
+
+ id
+ btree
+ 1
+
+
+ order_no
+ btree
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 4
+ ID
+ bigint|0s
+ 1
+ 1
+
+
+ 商品名称
+ varchar(255)|0s
+ 2
+ utf8_general_ci
+
+
+ 品牌ID
+ bigint|0s
+ 3
+
+
+ 一级分类id
+ bigint|0s
+ 4
+
+
+ 二级分类id
+ bigint|0s
+ 5
+
+
+ 三级分类id
+ bigint|0s
+ 6
+
+
+ 计量单位
+ varchar(50)|0s
+ 7
+ utf8_general_ci
+
+
+ 轮播图
+ text|0s
+ 8
+
+
+ 商品规格json
+ varchar(255)|0s
+ 9
+
+
+ 线上状态:0-初始值,1-上架,-1-自主下架
+ tinyint|0s
+ 0
+ 1
+ 10
+
+
+ 审核状态:0-初始值,1-通过,-1-未通过
+ tinyint|0s
+ 0
+ 1
+ 11
+
+
+ 审核信息
+ varchar(255)|0s
+ 12
+ utf8_general_ci
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 13
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 14
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 15
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 1
+ ID
+ bigint|0s
+ 1
+ 1
+
+
+ 商品id
+ bigint|0s
+ 2
+
+
+ 属性key
+ varchar(255)|0s
+ 3
+
+
+ 属性value
+ varchar(255)|0s
+ 4
+ utf8_general_ci
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 5
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 6
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 7
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 4
+ ID
+ bigint|0s
+ 1
+ 1
+
+
+ 商品id
+ bigint|0s
+ 2
+
+
+ 详情图片地址
+ text|0s
+ 3
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 4
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 5
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 6
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 11
+ ID
+ bigint|0s
+ 1
+ 1
+
+
+ 商品编号
+ varchar(30)|0s
+ 2
+ utf8_general_ci
+
+
+ varchar(255)|0s
+ 3
+
+
+ 商品ID
+ bigint|0s
+ 4
+
+
+ 缩略图路径
+ varchar(255)|0s
+ 5
+ utf8_general_ci
+
+
+ 售价
+ decimal(10,2 digit)|0s
+ 6
+
+
+ 市场价
+ decimal(10,2 digit)|0s
+ 7
+
+
+ 成本价
+ decimal(10,2 digit)|0s
+ 8
+
+
+ 库存数
+ int|0s
+ 9
+
+
+ 销量
+ int|0s
+ 0
+ 1
+ 10
+
+
+ sku规格信息json
+ varchar(255)|0s
+ ''
+ 11
+ utf8_general_ci
+
+
+ 重量
+ decimal(10,2 digit)|0s
+ 12
+
+
+ 体积
+ decimal(10,2 digit)|0s
+ 13
+
+
+ 线上状态:0-初始值,1-上架,-1-自主下架
+ tinyint|0s
+ 14
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 15
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 16
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 17
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 9
+ ID
+ bigint|0s
+ 1
+ 1
+
+
+ 规格名称
+ varchar(100)|0s
+ 2
+ utf8_general_ci
+
+
+ 规格值:"[{"key":"颜色","valueList":["蓝","白","红"]]"
+ text|0s
+ 3
+ utf8_general_ci
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 4
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 5
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 6
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 6
+ ID
+ bigint|0s
+ 1
+ 1
+
+
+ 名称
+ varchar(255)|0s
+ 2
+ utf8_general_ci
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 3
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 4
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 5
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 3712
+ 地区id
+ bigint|0s
+ 1
+ 1
+
+
+ 地区编码
+ varchar(10)|0s
+ 2
+
+
+ 上级地区code
+ bigint|0s
+ 3
+
+
+ 地区名称
+ varchar(20)|0s
+ 4
+
+
+ 地区级别:1-省、自治区、直辖市 2-地级市、地区、自治州、盟 3-市辖区、县级市、县
+ int|0s
+ 5
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 6
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 7
+
+
+ 逻辑删除(1:已删除,0:未删除)
+ tinyint|0s
+ 0
+ 1
+ 8
+
+
+ id
+ btree
+ 1
+
+
+ code
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ idx_code
+
+
+ 4
+ 访问ID
+ bigint|0s
+ 1
+ 1
+
+
+ 用户账号
+ varchar(50)|0s
+ ''
+ 2
+
+
+ 登录IP地址
+ varchar(128)|0s
+ ''
+ 3
+
+
+ 登录状态(0成功 1失败)
+ tinyint(1)|0s
+ 0
+ 4
+
+
+ 提示信息
+ varchar(255)|0s
+ ''
+ 5
+
+
+ 访问时间
+ datetime|0s
+ 6
+
+
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 7
+
+
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 8
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 9
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 31
+ 编号
+ bigint|0s
+ 1
+ 1
+
+
+ 所属上级
+ bigint|0s
+ 0
+ 1
+ 2
+
+
+ 菜单标题
+ varchar(20)|0s
+ ''
+ 1
+ 3
+
+
+ 组件名称
+ varchar(100)|0s
+ 4
+
+
+ 排序
+ int|0s
+ 1
+ 1
+ 5
+
+
+ 状态(0:禁止,1:正常)
+ tinyint|0s
+ 1
+ 1
+ 6
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 7
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 8
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 9
+
+
+ id
+ btree
+ 1
+
+
+ parent_id
+ btree
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 80
+ 日志主键
+ bigint|0s
+ 1
+ 1
+
+
+ 模块标题
+ varchar(50)|0s
+ ''
+ 2
+
+
+ 方法名称
+ varchar(100)|0s
+ ''
+ 3
+
+
+ 请求方式
+ varchar(10)|0s
+ ''
+ 4
+
+
+ 操作类别(0其它 1后台用户 2手机端用户)
+ varchar(20)|0s
+ '0'
+ 5
+
+
+ 操作人员
+ varchar(50)|0s
+ ''
+ 6
+
+
+ 请求URL
+ varchar(255)|0s
+ ''
+ 7
+
+
+ 主机地址
+ varchar(128)|0s
+ ''
+ 8
+
+
+ 请求参数
+ varchar(2000)|0s
+ ''
+ 9
+
+
+ 返回参数
+ varchar(2000)|0s
+ ''
+ 10
+
+
+ 操作状态(0正常 1异常)
+ int|0s
+ 0
+ 11
+
+
+ 错误消息
+ varchar(2000)|0s
+ ''
+ 12
+
+
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 13
+
+
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 14
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 15
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 41
+ 角色id
+ bigint|0s
+ 1
+ 1
+
+
+ 角色名称
+ varchar(20)|0s
+ ''
+ 1
+ 2
+
+
+ 角色编码
+ varchar(20)|0s
+ 3
+
+
+ 描述
+ varchar(255)|0s
+ 4
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 5
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 6
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 7
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 257
+ bigint|0s
+ 1
+ 1
+
+
+ bigint|0s
+ 0
+ 1
+ 2
+
+
+ bigint|0s
+ 0
+ 1
+ 3
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 4
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 5
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 6
+
+
+ tinyint|0s
+ 7
+
+
+ id
+ btree
+ 1
+
+
+ role_id
+ btree
+
+
+ menu_id
+ btree
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 16
+ 会员id
+ bigint|0s
+ 1
+ 1
+
+
+ 用户名
+ varchar(20)|0s
+ ''
+ 1
+ 2
+
+
+ 密码
+ varchar(32)|0s
+ ''
+ 1
+ 3
+
+
+ 姓名
+ varchar(50)|0s
+ 4
+
+
+ 手机
+ varchar(11)|0s
+ 5
+
+
+ 头像
+ varchar(255)|0s
+ 6
+
+
+ 描述
+ varchar(255)|0s
+ 7
+
+
+ 状态(1:正常 0:停用)
+ tinyint|0s
+ 1
+ 1
+ 8
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 9
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 10
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 11
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 53
+ 主键id
+ bigint|0s
+ 1
+ 1
+
+
+ 角色id
+ bigint|0s
+ 0
+ 1
+ 2
+
+
+ 用户id
+ bigint|0s
+ 0
+ 1
+ 3
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 4
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 5
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 6
+
+
+ id
+ btree
+ 1
+
+
+ role_id
+ btree
+
+
+ user_id
+ btree
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 4
+ int|0s
+ 1
+ 1
+
+
+ 用户ID
+ int|0s
+ 0
+ 1
+ 2
+
+
+ varchar(20)|0s
+ ''
+ 1
+ 3
+
+
+ 电话
+ varchar(11)|0s
+ ''
+ 1
+ 4
+
+
+ 标签名称
+ varchar(20)|0s
+ 5
+
+
+ varchar(20)|0s
+ 6
+
+
+ varchar(20)|0s
+ 7
+
+
+ varchar(20)|0s
+ 8
+
+
+ 详细地址
+ varchar(100)|0s
+ ''
+ 1
+ 9
+
+
+ 完整地址
+ varchar(500)|0s
+ 10
+
+
+ 是否默认地址(0:否 1:是)
+ tinyint|0s
+ 1
+ 1
+ 11
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 12
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 13
+
+
+ 删除标识(0:否 1:是)
+ tinyint|0s
+ 0
+ 1
+ 14
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 10
+ 主键
+ bigint|0s
+ 1
+ 1
+
+
+ 用户ID
+ bigint|0s
+ 1
+ 2
+
+
+ 商品skuID
+ bigint|0s
+ 0
+ 1
+ 3
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 4
+
+
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 5
+
+
+ tinyint|0s
+ 0
+ 1
+ 6
+
+
+ id
+ btree
+ 1
+
+
+ user_id
+ btree
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 4
+ 主键
+ bigint|0s
+ 1
+ 1
+
+
+ 用户ID
+ bigint|0s
+ 1
+ 2
+
+
+ 商品skuID
+ bigint|0s
+ 0
+ 1
+ 3
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 4
+
+
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 5
+
+
+ tinyint|0s
+ 0
+ 1
+ 6
+
+
+ id
+ btree
+ 1
+
+
+ user_id
+ btree
+
+
+ 1
+ 1
+ PRIMARY
+
+
+ 33
+ id
+ bigint|0s
+ 1
+ 1
+
+
+ 用户名
+ varchar(50)|0s
+ 2
+
+
+ 密码
+ varchar(500)|0s
+ 3
+
+
+ 昵称
+ varchar(100)|0s
+ 4
+
+
+ 电话号码
+ varchar(17)|0s
+ 5
+
+
+ 头像
+ varchar(200)|0s
+ 6
+
+
+ 性别
+ tinyint(1)|0s
+ 7
+
+
+ 备注
+ varchar(100)|0s
+ 8
+
+
+ 微信open id
+ varchar(45)|0s
+ 9
+
+
+ 微信开放平台unionID
+ varchar(45)|0s
+ 10
+
+
+ 最后一次登录ip
+ varchar(50)|0s
+ 11
+
+
+ 最后一次登录时间
+ datetime|0s
+ 12
+
+
+ 状态:1为正常,0为禁止
+ tinyint|0s
+ 13
+
+
+ 创建时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ 14
+
+
+ 更新时间
+ timestamp|0s
+ CURRENT_TIMESTAMP
+ 1
+ CURRENT_TIMESTAMP
+ 15
+
+
+ 删除标记(0:不可用 1:可用)
+ tinyint|0s
+ 0
+ 1
+ 16
+
+
+ id
+ btree
+ 1
+
+
+ 1
+ 1
+ PRIMARY
+
+
+
\ No newline at end of file
diff --git a/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/db_spzx.fMWaVg.meta b/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/db_spzx.fMWaVg.meta
new file mode 100644
index 0000000..52b6b8b
--- /dev/null
+++ b/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/db_spzx.fMWaVg.meta
@@ -0,0 +1,2 @@
+#n:db_spzx
+! [1702742235000, 0, null, null, -2147483648, -2147483648]
diff --git a/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/information_schema.FNRwLQ.meta b/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/information_schema.FNRwLQ.meta
new file mode 100644
index 0000000..1ff3db2
--- /dev/null
+++ b/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/information_schema.FNRwLQ.meta
@@ -0,0 +1,2 @@
+#n:information_schema
+! [null, 0, null, null, -2147483648, -2147483648]
diff --git a/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/mysql.osA4Bg.meta b/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/mysql.osA4Bg.meta
new file mode 100644
index 0000000..86a53f1
--- /dev/null
+++ b/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/mysql.osA4Bg.meta
@@ -0,0 +1,2 @@
+#n:mysql
+! [null, 0, null, null, -2147483648, -2147483648]
diff --git a/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/performance_schema.kIw0nw.meta b/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/performance_schema.kIw0nw.meta
new file mode 100644
index 0000000..9394db1
--- /dev/null
+++ b/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/performance_schema.kIw0nw.meta
@@ -0,0 +1,2 @@
+#n:performance_schema
+! [null, 0, null, null, -2147483648, -2147483648]
diff --git a/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/sys.zb4BAA.meta b/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/sys.zb4BAA.meta
new file mode 100644
index 0000000..2f4470b
--- /dev/null
+++ b/.idea/dataSources/3eae447a-3ae1-4be3-aa70-1183cffb0765/storage_v2/_src_/schema/sys.zb4BAA.meta
@@ -0,0 +1,2 @@
+#n:sys
+! [null, 0, null, null, -2147483648, -2147483648]
diff --git a/.idea/inspectionProfiles/Project_Default.xml b/.idea/inspectionProfiles/Project_Default.xml
index 30e75dc..a147371 100644
--- a/.idea/inspectionProfiles/Project_Default.xml
+++ b/.idea/inspectionProfiles/Project_Default.xml
@@ -1,6 +1,9 @@
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
new file mode 100644
index 0000000..7cd660c
--- /dev/null
+++ b/.idea/workspace.xml
@@ -0,0 +1,160 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {
+ "customColor": "",
+ "associatedIndex": 5
+}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 1702710124940
+
+
+ 1702710124940
+
+
+
+
+
+ 1702714985398
+
+
+
+ 1702714985398
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ file://$PROJECT_DIR$/spzx-manager/src/main/java/cn/bunny/mapper/ProductSpecMapper.java
+ 22
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/spzx-manager/src/main/java/cn/bunny/controller/ProductController.java b/spzx-manager/src/main/java/cn/bunny/controller/ProductController.java
index 8d48742..c49c0ca 100644
--- a/spzx-manager/src/main/java/cn/bunny/controller/ProductController.java
+++ b/spzx-manager/src/main/java/cn/bunny/controller/ProductController.java
@@ -9,10 +9,7 @@ import com.github.pagehelper.PageInfo;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.web.bind.annotation.GetMapping;
-import org.springframework.web.bind.annotation.PathVariable;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RestController;
+import org.springframework.web.bind.annotation.*;
import java.util.List;
@@ -23,6 +20,28 @@ public class ProductController {
@Autowired
private ProductService productService;
+ @Operation(summary = "保存修改数据",description = "保存修改数据")
+ @PostMapping("updateById")
+ public Result updateById(@RequestBody Product product) {
+ productService.updateById(product);
+ return Result.build(null, ResultCodeEnum.SUCCESS);
+ }
+
+ @Operation(summary = "根据id查询商品信息",description = "根据id查询商品信息")
+ @GetMapping("getById/{id}")
+ public Result getById(@PathVariable("id") Long id) {
+ Product product = productService.getById(id);
+ return Result.build(product, ResultCodeEnum.SUCCESS);
+ }
+
+ @Operation(summary = "保存商品数据接口",description = "保存商品数据接口")
+ @PostMapping("save")
+ public Result save(@RequestBody Product product) {
+ productService.save(product);
+ return Result.build(null, ResultCodeEnum.SUCCESS);
+ }
+
+
@Operation(summary = "商品管理查询分页", description = "商品管理查询分页")
@GetMapping("/{page}/{limit}")
public Result findByPage(@PathVariable("page") Integer page,
diff --git a/spzx-manager/src/main/java/cn/bunny/controller/ProductSpecController.java b/spzx-manager/src/main/java/cn/bunny/controller/ProductSpecController.java
index 2cc16c0..0ac4445 100644
--- a/spzx-manager/src/main/java/cn/bunny/controller/ProductSpecController.java
+++ b/spzx-manager/src/main/java/cn/bunny/controller/ProductSpecController.java
@@ -10,6 +10,8 @@ import io.swagger.v3.oas.annotations.tags.Tag;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
+import java.util.List;
+
@Tag(name = "商品规格列表接口")
@RestController
@RequestMapping("/admin/product/productSpec")
@@ -17,6 +19,13 @@ public class ProductSpecController {
@Autowired
private ProductSpecService productSpecService;
+ @Operation(summary = "加载商品单元数据",description = "加载商品单元数据")
+ @GetMapping("findAll")
+ public Result findAll() {
+ List productSpecList= productSpecService.findAll();
+ return Result.build(productSpecList, ResultCodeEnum.SUCCESS);
+ }
+
@Operation(summary = "分页查询商品规格列表", description = "分页查询商品规格列表")
@GetMapping("{page}/{limit}")
public Result lis(@PathVariable("page") Integer page, @PathVariable("limit") Integer limit) {
diff --git a/spzx-manager/src/main/java/cn/bunny/controller/ProductUntilController.java b/spzx-manager/src/main/java/cn/bunny/controller/ProductUntilController.java
new file mode 100644
index 0000000..ce2b3b6
--- /dev/null
+++ b/spzx-manager/src/main/java/cn/bunny/controller/ProductUntilController.java
@@ -0,0 +1,30 @@
+package cn.bunny.controller;
+
+
+import cn.bunny.common.spzx.model.entity.base.ProductUnit;
+import cn.bunny.common.spzx.model.vo.common.Result;
+import cn.bunny.common.spzx.model.vo.common.ResultCodeEnum;
+import cn.bunny.service.ProductUntilService;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+import java.util.List;
+
+@Tag(name = "商品管理添加功能")
+@RestController
+@RequestMapping("/admin/product/productUnit")
+public class ProductUntilController {
+ @Autowired
+ private ProductUntilService productUntilService;
+
+ @Operation(summary = "加载商品单元数据", description = "加载商品单元数据")
+ @GetMapping("findAll")
+ public Result findAll() {
+ List productUnitList= productUntilService.findAll();
+ return Result.build(productUnitList, ResultCodeEnum.SUCCESS);
+ }
+}
diff --git a/spzx-manager/src/main/java/cn/bunny/mapper/ProductDetailMapper.java b/spzx-manager/src/main/java/cn/bunny/mapper/ProductDetailMapper.java
new file mode 100644
index 0000000..f5dcebd
--- /dev/null
+++ b/spzx-manager/src/main/java/cn/bunny/mapper/ProductDetailMapper.java
@@ -0,0 +1,15 @@
+package cn.bunny.mapper;
+
+import cn.bunny.common.spzx.model.entity.product.ProductDetails;
+import org.apache.ibatis.annotations.Mapper;
+
+@Mapper
+public interface ProductDetailMapper {
+ void save(ProductDetails productDetails);
+
+ // 根据id查询商品信息
+ ProductDetails findProductDetailsById(Long id);
+
+ // 修改product_details表
+ void updateById(ProductDetails productDetails);
+}
diff --git a/spzx-manager/src/main/java/cn/bunny/mapper/ProductMapper.java b/spzx-manager/src/main/java/cn/bunny/mapper/ProductMapper.java
index 70e4750..393fbaa 100644
--- a/spzx-manager/src/main/java/cn/bunny/mapper/ProductMapper.java
+++ b/spzx-manager/src/main/java/cn/bunny/mapper/ProductMapper.java
@@ -10,4 +10,13 @@ import java.util.List;
public interface ProductMapper {
// 查询分页
public List findByPage(ProductDto productDto);
+
+ // 保存商品数据接口
+ void save(Product product);
+
+ // 1. 根据id查询商品基本信息
+ Product findProductById(Long id);
+
+ // 修改product表
+ void updateProduct(Product product);
}
diff --git a/spzx-manager/src/main/java/cn/bunny/mapper/ProductSkuMapper.java b/spzx-manager/src/main/java/cn/bunny/mapper/ProductSkuMapper.java
new file mode 100644
index 0000000..1a5c16d
--- /dev/null
+++ b/spzx-manager/src/main/java/cn/bunny/mapper/ProductSkuMapper.java
@@ -0,0 +1,17 @@
+package cn.bunny.mapper;
+
+import cn.bunny.common.spzx.model.entity.product.ProductSku;
+import org.apache.ibatis.annotations.Mapper;
+
+import java.util.List;
+
+@Mapper
+public interface ProductSkuMapper {
+ void save(ProductSku productSku);
+
+ // 根据id查询商品信息
+ List findProductSkuByProductId(Long id);
+
+ // 修改product_sku表
+ void updateById(ProductSku productSku);
+}
diff --git a/spzx-manager/src/main/java/cn/bunny/mapper/ProductSpecMapper.java b/spzx-manager/src/main/java/cn/bunny/mapper/ProductSpecMapper.java
index 18565ce..40f946f 100644
--- a/spzx-manager/src/main/java/cn/bunny/mapper/ProductSpecMapper.java
+++ b/spzx-manager/src/main/java/cn/bunny/mapper/ProductSpecMapper.java
@@ -18,4 +18,7 @@ public interface ProductSpecMapper {
// 商品规格删除
void deleteById(Integer id);
+
+ // 加载商品单元数据
+ List findAll();
}
diff --git a/spzx-manager/src/main/java/cn/bunny/mapper/ProductUntilMapper.java b/spzx-manager/src/main/java/cn/bunny/mapper/ProductUntilMapper.java
new file mode 100644
index 0000000..e05362e
--- /dev/null
+++ b/spzx-manager/src/main/java/cn/bunny/mapper/ProductUntilMapper.java
@@ -0,0 +1,12 @@
+package cn.bunny.mapper;
+
+import cn.bunny.common.spzx.model.entity.base.ProductUnit;
+import org.apache.ibatis.annotations.Mapper;
+
+import java.util.List;
+
+@Mapper
+public interface ProductUntilMapper {
+ // 加载商品单元数据
+ List findAll();
+}
diff --git a/spzx-manager/src/main/java/cn/bunny/service/ProductService.java b/spzx-manager/src/main/java/cn/bunny/service/ProductService.java
index a8bab09..76be039 100644
--- a/spzx-manager/src/main/java/cn/bunny/service/ProductService.java
+++ b/spzx-manager/src/main/java/cn/bunny/service/ProductService.java
@@ -9,4 +9,13 @@ import java.util.List;
public interface ProductService {
// 查询分页
PageInfo findByPage(Integer page, Integer limit, ProductDto productDto);
+
+ // 保存商品数据接口
+ void save(Product product);
+
+ // 根据id查询商品信息
+ Product getById(Long id);
+
+ // 保存修改数据
+ void updateById(Product product);
}
diff --git a/spzx-manager/src/main/java/cn/bunny/service/ProductSpecService.java b/spzx-manager/src/main/java/cn/bunny/service/ProductSpecService.java
index 0c9ef1b..bae6ff9 100644
--- a/spzx-manager/src/main/java/cn/bunny/service/ProductSpecService.java
+++ b/spzx-manager/src/main/java/cn/bunny/service/ProductSpecService.java
@@ -3,6 +3,8 @@ package cn.bunny.service;
import cn.bunny.common.spzx.model.entity.product.ProductSpec;
import com.github.pagehelper.PageInfo;
+import java.util.List;
+
public interface ProductSpecService {
// 分页查询商品规格列表
PageInfo findByPage(Integer page, Integer limit);
@@ -15,4 +17,7 @@ public interface ProductSpecService {
// 商品规格删除
void deleteById(Integer id);
+
+ // 加载商品单元数据
+ List findAll();
}
diff --git a/spzx-manager/src/main/java/cn/bunny/service/ProductUntilService.java b/spzx-manager/src/main/java/cn/bunny/service/ProductUntilService.java
new file mode 100644
index 0000000..cde86eb
--- /dev/null
+++ b/spzx-manager/src/main/java/cn/bunny/service/ProductUntilService.java
@@ -0,0 +1,10 @@
+package cn.bunny.service;
+
+import cn.bunny.common.spzx.model.entity.base.ProductUnit;
+
+import java.util.List;
+
+public interface ProductUntilService {
+ // 加载商品单元数据
+ List findAll();
+}
diff --git a/spzx-manager/src/main/java/cn/bunny/service/impl/ProductServiceImpl.java b/spzx-manager/src/main/java/cn/bunny/service/impl/ProductServiceImpl.java
index fee4de7..6688fa1 100644
--- a/spzx-manager/src/main/java/cn/bunny/service/impl/ProductServiceImpl.java
+++ b/spzx-manager/src/main/java/cn/bunny/service/impl/ProductServiceImpl.java
@@ -2,7 +2,11 @@ package cn.bunny.service.impl;
import cn.bunny.common.spzx.model.dto.product.ProductDto;
import cn.bunny.common.spzx.model.entity.product.Product;
+import cn.bunny.common.spzx.model.entity.product.ProductDetails;
+import cn.bunny.common.spzx.model.entity.product.ProductSku;
+import cn.bunny.mapper.ProductDetailMapper;
import cn.bunny.mapper.ProductMapper;
+import cn.bunny.mapper.ProductSkuMapper;
import cn.bunny.service.ProductService;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
@@ -16,6 +20,12 @@ public class ProductServiceImpl implements ProductService {
@Autowired
private ProductMapper productMapper;
+ @Autowired
+ private ProductSkuMapper productSkuMapper;
+
+ @Autowired
+ private ProductDetailMapper productDetailMapper;
+
// 查询分页
@Override
public PageInfo findByPage(Integer page, Integer limit, ProductDto productDto) {
@@ -23,4 +33,66 @@ public class ProductServiceImpl implements ProductService {
List productList = productMapper.findByPage(productDto);
return new PageInfo<>(productList);
}
+
+ // 保存商品数据接口
+ @Override
+ public void save(Product product) {
+ product.setStatus(0);
+ product.setAuditStatus(0);
+ productMapper.save(product);
+
+ List productSkuList = product.getProductSkuList();
+ for (int i = 0; i < productSkuList.size(); i++) {
+ ProductSku productSku = productSkuList.get(i);
+ // 商品编号
+ productSku.setSkuCode(product.getId() + "_" + i);
+ // 商品Id
+ productSku.setProductId(product.getId());
+ // skuName
+ productSku.setSkuName(product.getName() + productSku.getSkuSpec());
+ productSkuMapper.save(productSku);
+ }
+
+ ProductDetails productDetails = new ProductDetails();
+ productDetails.setProductId(product.getId());
+ productDetails.setImageUrls(product.getDetailsImageUrls());
+ productDetailMapper.save(productDetails);
+ }
+
+ // 根据id查询商品信息
+ @Override
+ public Product getById(Long id) {
+ // 1. 根据id查询商品基本信息
+ Product product = productMapper.findProductById(id);
+
+ // 2. 根据id查询商品sku信息列表 product——sku
+ List productSkuList = productSkuMapper.findProductSkuByProductId(id);
+ product.setProductSkuList(productSkuList);
+
+ // 3. 根据id查询商品详情信息 product——details
+ ProductDetails productDetails = productDetailMapper.findProductDetailsById(id);
+ String imageUrls = productDetails.getImageUrls();
+ product.setDetailsImageUrls(imageUrls);
+
+ return product;
+ }
+
+ // 保存修改数据
+ @Override
+ public void updateById(Product product) {
+ // 修改product表
+ productMapper.updateProduct(product);
+
+ // 修改product_sku表
+ List productSkuList = product.getProductSkuList();
+ for (ProductSku productSku : productSkuList) {
+ productSkuMapper.updateById(productSku);
+ }
+
+ // 修改product_details表
+ String detailsImageUrls = product.getDetailsImageUrls();
+ ProductDetails productDetails= productDetailMapper.findProductDetailsById(product.getId());
+ productDetails.setImageUrls(detailsImageUrls);
+ productDetailMapper.updateById(productDetails);
+ }
}
diff --git a/spzx-manager/src/main/java/cn/bunny/service/impl/ProductSpecServiceImpl.java b/spzx-manager/src/main/java/cn/bunny/service/impl/ProductSpecServiceImpl.java
index f882801..be8c711 100644
--- a/spzx-manager/src/main/java/cn/bunny/service/impl/ProductSpecServiceImpl.java
+++ b/spzx-manager/src/main/java/cn/bunny/service/impl/ProductSpecServiceImpl.java
@@ -40,4 +40,10 @@ public class ProductSpecServiceImpl implements ProductSpecService {
public void deleteById(Integer id) {
productSpecMapper.deleteById(id);
}
+
+ // 加载商品单元数据
+ @Override
+ public List findAll() {
+ return productSpecMapper.findAll();
+ }
}
diff --git a/spzx-manager/src/main/java/cn/bunny/service/impl/ProductUntilServiceImpl.java b/spzx-manager/src/main/java/cn/bunny/service/impl/ProductUntilServiceImpl.java
new file mode 100644
index 0000000..50981ea
--- /dev/null
+++ b/spzx-manager/src/main/java/cn/bunny/service/impl/ProductUntilServiceImpl.java
@@ -0,0 +1,22 @@
+package cn.bunny.service.impl;
+
+import cn.bunny.common.spzx.model.entity.base.ProductUnit;
+import cn.bunny.mapper.ProductUntilMapper;
+import cn.bunny.service.ProductUntilService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class ProductUntilServiceImpl implements ProductUntilService {
+ @Autowired
+ private ProductUntilMapper productUnitMapper;
+
+ // 加载商品单元数据
+ @Override
+ public List findAll() {
+ return productUnitMapper.findAll();
+
+ }
+}
diff --git a/spzx-manager/src/main/resources/mapper/product/ProductDetailMapper.xml b/spzx-manager/src/main/resources/mapper/product/ProductDetailMapper.xml
new file mode 100644
index 0000000..43571ef
--- /dev/null
+++ b/spzx-manager/src/main/resources/mapper/product/ProductDetailMapper.xml
@@ -0,0 +1,44 @@
+
+
+
+
+
+ id,product_id,image_urls,create_time,update_time,is_deleted
+
+
+
+ insert into product_details (id,
+ product_id,
+ image_urls,
+ create_time, update_time, is_deleted)
+ values (#{id},
+ #{productId},
+ #{imageUrls},
+ now(),
+ now(),
+ 0)
+
+
+
+
+ update product_details set
+
+ product_id = #{productId},
+
+
+ image_urls = #{imageUrls},
+
+ update_time = now()
+ where
+ id = #{id}
+
+
+
+
+
diff --git a/spzx-manager/src/main/resources/mapper/product/ProductMapper.xml b/spzx-manager/src/main/resources/mapper/product/ProductMapper.xml
index ff4e82a..d11eeff 100644
--- a/spzx-manager/src/main/resources/mapper/product/ProductMapper.xml
+++ b/spzx-manager/src/main/resources/mapper/product/ProductMapper.xml
@@ -27,11 +27,61 @@
+
+
+ insert into product (id, name, brand_id, category1_id, category2_id, category3_id, unit_name, slider_urls,
+ spec_value, status, audit_status, audit_message, create_time, update_time, is_deleted)
+ values (#{id}, #{name}, #{brandId}, #{category1Id}, #{category2Id}, #{category3Id}, #{unitName}, #{sliderUrls},
+ #{specValue}, #{status}, #{auditStatus}, #{auditMessage}, now(), now(), 0)
+
+
+
+
+ update product set
+
+ name = #{name},
+
+
+ brand_id = #{brandId},
+
+
+ category1_id = #{category1Id},
+
+
+ category2_id = #{category2Id},
+
+
+ category3_id = #{category3Id},
+
+
+ unit_name = #{unitName},
+
+
+ slider_urls = #{sliderUrls},
+
+
+ spec_value = #{specValue},
+
+
+ status = #{status},
+
+
+ audit_status = #{auditStatus},
+
+
+ audit_message = #{auditMessage},
+
+ update_time = now()
+ where
+ id = #{id}
+
+
+
+
+
diff --git a/spzx-manager/src/main/resources/mapper/product/ProductSkuMapper.xml b/spzx-manager/src/main/resources/mapper/product/ProductSkuMapper.xml
new file mode 100644
index 0000000..198c8b7
--- /dev/null
+++ b/spzx-manager/src/main/resources/mapper/product/ProductSkuMapper.xml
@@ -0,0 +1,99 @@
+
+
+
+
+
+
+ id,sku_code,sku_name,product_id,thumb_img,sale_price,market_price,cost_price,stock_num,sku_spec,weight,volume,status,create_time,update_time,is_deleted
+
+
+
+ insert into product_sku (id,
+ sku_code,
+ sku_name,
+ product_id,
+ thumb_img,
+ sale_price,
+ market_price,
+ cost_price,
+ stock_num,
+ sku_spec,
+ weight,
+ volume,
+ status,
+ sale_num,
+ create_time,
+ update_time,
+ is_deleted)
+ values (#{id},
+ #{skuCode},
+ #{skuName},
+ #{productId},
+ #{thumbImg},
+ #{salePrice},
+ #{marketPrice},
+ #{costPrice},
+ #{stockNum},
+ #{skuSpec},
+ #{weight},
+ #{volume},
+ #{status},
+ #{saleNum},
+ now(),
+ now(),
+ 0)
+
+
+
+
+ update product_sku set
+
+ sku_code = #{skuCode},
+
+
+ sku_name = #{skuName},
+
+
+ product_id = #{productId},
+
+
+ thumb_img = #{thumbImg},
+
+
+ sale_price = #{salePrice},
+
+
+ market_price = #{marketPrice},
+
+
+ cost_price = #{costPrice},
+
+
+ stock_num = #{stockNum},
+
+
+ sku_spec = #{skuSpec},
+
+
+ weight = #{weight},
+
+
+ volume = #{volume},
+
+
+ status = #{status},
+
+ update_time = now()
+ where
+ id = #{id}
+
+
+
+
+
diff --git a/spzx-manager/src/main/resources/mapper/product/ProductSpecMapper.xml b/spzx-manager/src/main/resources/mapper/product/ProductSpecMapper.xml
index da61274..fa1a77e 100644
--- a/spzx-manager/src/main/resources/mapper/product/ProductSpecMapper.xml
+++ b/spzx-manager/src/main/resources/mapper/product/ProductSpecMapper.xml
@@ -44,4 +44,10 @@
where is_deleted = 0
order by id desc
-
+
+
+
\ No newline at end of file
diff --git a/spzx-manager/src/main/resources/mapper/product/ProductUntilMapper.xml b/spzx-manager/src/main/resources/mapper/product/ProductUntilMapper.xml
new file mode 100644
index 0000000..ae613cc
--- /dev/null
+++ b/spzx-manager/src/main/resources/mapper/product/ProductUntilMapper.xml
@@ -0,0 +1,17 @@
+
+
+
+
+
+
+ id,name,create_time,update_time,is_deleted
+
+
+
+
+