Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
custom-server
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lizhonghong
custom-server
Commits
f5dd4bff
Commit
f5dd4bff
authored
Jun 03, 2026
by
Lizh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
重新生成商品相关的entity对象和vo对象
parent
65aef922
Hide whitespace changes
Inline
Side-by-side
Showing
50 changed files
with
371 additions
and
370 deletions
+371
-370
.gitignore
+1
-0
custom-server-app/src/main/java/com/jomalls/custom/app/annotation/RepeatSubmit.java
+9
-1
custom-server-app/src/main/java/com/jomalls/custom/app/annotation/RequiresPermissions.java
+18
-0
custom-server-app/src/main/java/com/jomalls/custom/app/annotation/RequiresRoles.java
+53
-0
custom-server-app/src/main/java/com/jomalls/custom/app/aspect/PermissionAspect.java
+55
-1
custom-server-app/src/main/java/com/jomalls/custom/app/aspect/RepeatSubmitAspect.java
+3
-7
custom-server-app/src/main/java/com/jomalls/custom/app/exception/InvalidTokenException.java
+35
-0
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductBlacklistPageVO.java
+1
-1
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductBlacklistVO.java
+7
-4
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductCnRemarkPageVO.java
+1
-1
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductCnRemarkVO.java
+7
-5
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductCraftRelPageVO.java
+1
-1
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductCraftRelVO.java
+7
-4
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductDiyUserRelPageVO.java
+2
-2
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductDiyUserRelVO.java
+7
-4
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductFactoryPriceIntervalRelPageVO.java
+1
-1
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductFactoryPriceIntervalRelVO.java
+7
-5
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductFactoryPriceRelPageVO.java
+1
-1
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductFactoryPriceRelVO.java
+7
-5
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductImagePageVO.java
+1
-1
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductImageVO.java
+7
-5
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductInfoPageVO.java
+5
-29
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductInfoPropertyPageVO.java
+1
-1
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductInfoPropertyVO.java
+7
-4
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductInfoVO.java
+11
-33
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductItemPageVO.java
+1
-7
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductItemVO.java
+7
-11
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductRemarkPageVO.java
+1
-1
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductRemarkVO.java
+7
-5
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductWarehouseRelPageVO.java
+1
-1
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductWarehouseRelVO.java
+7
-4
custom-server-app/src/main/java/com/jomalls/custom/app/vo/LogCustomProductPageVO.java
+1
-7
custom-server-app/src/main/java/com/jomalls/custom/app/vo/LogCustomProductVO.java
+7
-11
custom-server-core/src/main/java/com/jomalls/custom/security/TokenHandle.java
+24
-22
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductBlacklistEntity.java
+2
-5
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductCnRemarkEntity.java
+1
-4
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductCraftRelEntity.java
+3
-4
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductDiyUserRelEntity.java
+3
-5
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductFactoryPriceIntervalRelEntity.java
+3
-6
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductFactoryPriceRelEntity.java
+5
-14
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductImageEntity.java
+4
-8
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductInfoEntity.java
+4
-63
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductInfoPropertyEntity.java
+1
-6
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductItemEntity.java
+2
-37
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductRemarkEntity.java
+2
-4
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductWarehouseRelEntity.java
+2
-4
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/LogCustomProductEntity.java
+2
-12
custom-server-starter/src/main/java/com/jomalls/custom/config/CommonExceptionHandlerAdvice.java
+10
-0
custom-server-starter/src/main/java/com/jomalls/custom/config/SecurityInterceptor.java
+14
-13
custom-server-webapp/src/main/java/com/jomalls/custom/webapp/controller/CustomProductCraftRelController.java
+2
-0
No files found.
.gitignore
View file @
f5dd4bff
...
...
@@ -13,4 +13,5 @@
.trae/
.vscode/
CLAUDE.md
docs
custom-server-app/src/main/java/com/jomalls/custom/app/annotation/RepeatSubmit.java
View file @
f5dd4bff
...
...
@@ -3,9 +3,17 @@ package com.jomalls.custom.app.annotation;
import
java.lang.annotation.*
;
/**
* 防重复提交切面
* 基于Redis SET NX EX实现,在指定时间间隔(毫秒)内同一用户对同一接口的相同参数请求只允许执行一次
* 使用方法:
* 在需要防止重复提交的方法上添加@RepeatSubmit注解,指定间隔时间(毫秒)和提示消息
* 示例:
* @RepeatSubmit(interval = 5000, message = "请勿重复提交")
* @PostMapping("/save")
* public R<Void> save(@RequestBody XxxVO vo) { ... }
*
* @Author: Lizh
* @Date: 2026/6/2 10:58
* @Description: 需要验证重复提交的注解
* @Version: 1.0
*/
@Inherited
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/annotation/RequiresPermissions.java
View file @
f5dd4bff
...
...
@@ -9,6 +9,24 @@ import java.lang.annotation.Target;
/**
* 权限控制注解
* 用于标注需要权限校验的 Controller 方法
* 新老用法对照
* ┌─────────────────────────────────────────┬──────────────────────────────────────────────────────────────┐
* ├ custom-back │ custom-server(迁移后) │
* ├─────────────────────────────────────────┼──────────────────────────────────────────────────────────────┼
* │ @PreAuthorize("@ss.hasPermi('x')") │ @RequiresPermissions("x") │
* ├─────────────────────────────────────────┼──────────────────────────────────────────────────────────────┼
* │ @PreAuthorize("@ss.hasAnyPermi('a,b')") │ @RequiresPermissions(value="a,b", mode=ANY) │
* ├─────────────────────────────────────────┼──────────────────────────────────────────────────────────────┼
* │ @PreAuthorize("@ss.hasRole('admin')") │ @RequiresRoles("admin") │
* ├─────────────────────────────────────────┼──────────────────────────────────────────────────────────────┤
* │ @PreAuthorize("@ss.hasAnyRoles('a,b')") │ @RequiresRoles(value="a,b", mode=ANY) │
* ├─────────────────────────────────────────┼──────────────────────────────────────────────────────────────┤
* │ 权限+角色 AND 组合 │ @RequiresPermissions("x") + @RequiresRoles("admin") 同时使用 │
* └─────────────────────────────────────────┴──────────────────────────────────────────────────────────────┴
*
* @author Lizh
* @version 0.01
* @date 2026-06-03
*/
@Target
(
ElementType
.
METHOD
)
@Retention
(
RetentionPolicy
.
RUNTIME
)
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/annotation/RequiresRoles.java
0 → 100644
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
annotation
;
import
java.lang.annotation.Documented
;
import
java.lang.annotation.ElementType
;
import
java.lang.annotation.Retention
;
import
java.lang.annotation.RetentionPolicy
;
import
java.lang.annotation.Target
;
/**
* 角色校验注解 — 等价于 @PreAuthorize("@ss.hasRole('xxx')") / @PreAuthorize("@ss.hasAnyRoles('xxx')")
* 用于标注需要角色校验的 Controller 方法
* 新老用法对照
* ┌─────────────────────────────────────────┬──────────────────────────────────────────────────────────────┐
* ├ custom-back │ custom-server(迁移后) │
* ├─────────────────────────────────────────┼──────────────────────────────────────────────────────────────┼
* │ @PreAuthorize("@ss.hasPermi('x')") │ @RequiresPermissions("x") │
* ├─────────────────────────────────────────┼──────────────────────────────────────────────────────────────┼
* │ @PreAuthorize("@ss.hasAnyPermi('a,b')") │ @RequiresPermissions(value="a,b", mode=ANY) │
* ├─────────────────────────────────────────┼──────────────────────────────────────────────────────────────┼
* │ @PreAuthorize("@ss.hasRole('admin')") │ @RequiresRoles("admin") │
* ├─────────────────────────────────────────┼──────────────────────────────────────────────────────────────┤
* │ @PreAuthorize("@ss.hasAnyRoles('a,b')") │ @RequiresRoles(value="a,b", mode=ANY) │
* ├─────────────────────────────────────────┼──────────────────────────────────────────────────────────────┤
* │ 权限+角色 AND 组合 │ @RequiresPermissions("x") + @RequiresRoles("admin") 同时使用 │
* └─────────────────────────────────────────┴──────────────────────────────────────────────────────────────┴
*
* @author Lizh
* @version 0.01
* @date 2026-06-03
*/
@Target
(
ElementType
.
METHOD
)
@Retention
(
RetentionPolicy
.
RUNTIME
)
@Documented
public
@interface
RequiresRoles
{
/**
* 角色标识,支持多个角色(逗号分隔)
* 例如: "admin" 或 "admin,system:dept:manager"
*/
String
value
();
/**
* 角色校验模式
* ALL - 必须拥有所有角色
* ANY - 拥有任意一个角色即可
*/
RequiresPermissions
.
RequireMode
mode
()
default
RequiresPermissions
.
RequireMode
.
ANY
;
/**
* 角色校验失败时的错误信息
*/
String
message
()
default
"无访问权限,角色不匹配"
;
}
custom-server-app/src/main/java/com/jomalls/custom/app/aspect/PermissionAspect.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
aspect
;
import
com.jomalls.custom.app.annotation.RequiresPermissions
;
import
com.jomalls.custom.app.annotation.RequiresRoles
;
import
com.jomalls.custom.app.enums.CodeEnum
;
import
com.jomalls.custom.app.exception.ServiceException
;
import
com.jomalls.custom.app.service.PermissionService
;
...
...
@@ -15,7 +16,11 @@ import org.springframework.stereotype.Component;
import
java.lang.reflect.Method
;
/**
* 权限校验切面
* 操作权限校验切面
*
* @author Lizh
* @version 0.01
* @date 2026-05-29 10:43:28
*/
@Slf4j
@Aspect
...
...
@@ -31,6 +36,15 @@ public class PermissionAspect {
}
/**
* 角色校验切点 — 拦截 @RequiresRoles 注解
* 等价于 @PreAuthorize("@ss.hasRole('xxx')") 和 @PreAuthorize("@ss.hasAnyRoles('xxx')")
*/
@Before
(
"@annotation(com.jomalls.custom.app.annotation.RequiresRoles)"
)
public
void
doBeforeRoles
(
JoinPoint
point
)
throws
Throwable
{
checkRoles
(
point
);
}
/**
* 权限校验
*
* @param joinPoint 切点
...
...
@@ -67,4 +81,44 @@ public class PermissionAspect {
throw
new
ServiceException
(
message
,
CodeEnum
.
FORBIDDEN
.
getCode
());
}
}
/**
* 角色校验
*
* @param joinPoint 切点
*/
private
void
checkRoles
(
JoinPoint
joinPoint
)
{
MethodSignature
signature
=
(
MethodSignature
)
joinPoint
.
getSignature
();
Method
method
=
signature
.
getMethod
();
RequiresRoles
requiresRoles
=
method
.
getAnnotation
(
RequiresRoles
.
class
);
if
(
requiresRoles
==
null
)
{
return
;
}
String
roles
=
requiresRoles
.
value
();
RequiresPermissions
.
RequireMode
mode
=
requiresRoles
.
mode
();
String
message
=
requiresRoles
.
message
();
boolean
hasRole
;
if
(
mode
==
RequiresPermissions
.
RequireMode
.
ALL
)
{
// 必须拥有所有角色
String
[]
roleArray
=
roles
.
split
(
","
);
hasRole
=
true
;
for
(
String
r
:
roleArray
)
{
if
(!
permissionService
.
hasRole
(
r
.
trim
()))
{
hasRole
=
false
;
break
;
}
}
}
else
{
// 拥有任意一个角色即可(默认)
hasRole
=
permissionService
.
hasAnyRoles
(
roles
);
}
if
(!
hasRole
)
{
log
.
warn
(
"用户无匹配角色,要求角色: {},校验模式: {},方法: {}"
,
roles
,
mode
,
method
.
getName
());
throw
new
ServiceException
(
message
,
CodeEnum
.
FORBIDDEN
.
getCode
());
}
}
}
custom-server-app/src/main/java/com/jomalls/custom/app/aspect/RepeatSubmitAspect.java
View file @
f5dd4bff
...
...
@@ -21,14 +21,10 @@ import java.util.concurrent.TimeUnit;
/**
* 防重复提交切面
* 基于Redis SET NX EX实现,在指定时间间隔(毫秒)内同一用户对同一接口的相同参数请求只允许执行一次
* 使用方法:
* 在需要防止重复提交的方法上添加@RepeatSubmit注解,指定间隔时间(毫秒)和提示消息
* 示例:
* @RepeatSubmit(interval = 5000, message = "请勿重复提交")
* @PostMapping("/save")
* public R<Void> save(@RequestBody XxxVO vo) { ... }
*
* @author Lizh
* @version 0.01
* @date 2026-05-29 10:43:28
*/
@Slf4j
@Aspect
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/exception/InvalidTokenException.java
0 → 100644
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
exception
;
import
lombok.Getter
;
import
java.io.Serial
;
/**
* @Author: Lizh
* @Date: 2026/5/28 10:27
* @Description: 未登录或token无效异常
* @Version: 1.0
*/
@Getter
public
class
InvalidTokenException
extends
RuntimeException
{
@Serial
private
static
final
long
serialVersionUID
=
1L
;
private
Integer
code
=
401
;
public
InvalidTokenException
()
{
super
(
"未登录或登录已过期"
);
}
public
InvalidTokenException
(
String
message
)
{
super
(
message
);
}
public
InvalidTokenException
(
Integer
code
,
String
message
)
{
super
(
message
);
this
.
code
=
code
;
}
}
\ No newline at end of file
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductBlacklistPageVO.java
View file @
f5dd4bff
...
...
@@ -11,7 +11,7 @@ import java.io.Serializable;
* PageModel
*
* @author Lizh
* @date 2026-0
5-29 10:25:1
5
* @date 2026-0
6-03 11:56:5
5
*/
@Data
@Builder
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductBlacklistVO.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
vo
;
import
lombok.*
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
io.swagger.v3.oas.annotations.media.Schema
;
/**
* Model
*
* @author Lizh
* @date 2026-0
5-29 10:25:1
5
* @date 2026-0
6-03 11:56:5
5
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema
(
description
=
"
CustomProductBlacklist
VO"
)
@Schema
(
description
=
"VO"
)
public
class
CustomProductBlacklistVO
implements
Serializable
{
@Serial
private
static
final
long
serialVersionUID
=
1L
;
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductCnRemarkPageVO.java
View file @
f5dd4bff
...
...
@@ -12,7 +12,7 @@ import java.util.Date;
* PageModel
*
* @author Lizh
* @date 2026-0
5-29 10:25:1
6
* @date 2026-0
6-03 11:56:5
6
*/
@Data
@Builder
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductCnRemarkVO.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
vo
;
import
lombok.*
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.util.Date
;
import
io.swagger.v3.oas.annotations.media.Schema
;
/**
* Model
*
* @author Lizh
* @date 2026-0
5-29 10:25:1
6
* @date 2026-0
6-03 11:56:5
6
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema
(
description
=
"
CustomProductCnRemark
VO"
)
@Schema
(
description
=
"VO"
)
public
class
CustomProductCnRemarkVO
implements
Serializable
{
@Serial
private
static
final
long
serialVersionUID
=
1L
;
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductCraftRelPageVO.java
View file @
f5dd4bff
...
...
@@ -11,7 +11,7 @@ import java.io.Serializable;
* PageModel
*
* @author Lizh
* @date 2026-0
5-29 10:25:16
* @date 2026-0
6-03 11:56:57
*/
@Data
@Builder
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductCraftRelVO.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
vo
;
import
lombok.*
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
io.swagger.v3.oas.annotations.media.Schema
;
/**
* Model
*
* @author Lizh
* @date 2026-0
5-29 10:25:16
* @date 2026-0
6-03 11:56:57
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema
(
description
=
"
CustomProductCraftRel
VO"
)
@Schema
(
description
=
"VO"
)
public
class
CustomProductCraftRelVO
implements
Serializable
{
@Serial
private
static
final
long
serialVersionUID
=
1L
;
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductDiyUserRelPageVO.java
View file @
f5dd4bff
...
...
@@ -11,13 +11,13 @@ import java.io.Serializable;
* PageModel
*
* @author Lizh
* @date 2026-0
5-29 10:25:16
* @date 2026-0
6-03 11:56:58
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode
(
callSuper
=
fals
e
)
@EqualsAndHashCode
(
callSuper
=
tru
e
)
@Schema
(
description
=
"CustomProductDiyUserRelPageVo"
)
public
class
CustomProductDiyUserRelPageVO
extends
PageRequest
implements
Serializable
{
@Serial
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductDiyUserRelVO.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
vo
;
import
lombok.*
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
io.swagger.v3.oas.annotations.media.Schema
;
/**
* Model
*
* @author Lizh
* @date 2026-0
5-29 10:25:16
* @date 2026-0
6-03 11:56:58
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema
(
description
=
"
CustomProductDiyUserRel
VO"
)
@Schema
(
description
=
"VO"
)
public
class
CustomProductDiyUserRelVO
implements
Serializable
{
@Serial
private
static
final
long
serialVersionUID
=
1L
;
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductFactoryPriceIntervalRelPageVO.java
View file @
f5dd4bff
...
...
@@ -12,7 +12,7 @@ import java.math.BigDecimal;
* PageModel
*
* @author Lizh
* @date 2026-0
5-29 10:25:16
* @date 2026-0
6-03 11:56:59
*/
@Data
@Builder
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductFactoryPriceIntervalRelVO.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
vo
;
import
lombok.*
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
io.swagger.v3.oas.annotations.media.Schema
;
/**
* Model
*
* @author Lizh
* @date 2026-0
5-29 10:25:16
* @date 2026-0
6-03 11:56:59
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema
(
description
=
"
CustomProductFactoryPriceIntervalRel
VO"
)
@Schema
(
description
=
"VO"
)
public
class
CustomProductFactoryPriceIntervalRelVO
implements
Serializable
{
@Serial
private
static
final
long
serialVersionUID
=
1L
;
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductFactoryPriceRelPageVO.java
View file @
f5dd4bff
...
...
@@ -13,7 +13,7 @@ import java.util.Date;
* PageModel
*
* @author Lizh
* @date 2026-0
5-29 10:25:16
* @date 2026-0
6-03 11:57:00
*/
@Data
@Builder
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductFactoryPriceRelVO.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
vo
;
import
lombok.*
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.util.Date
;
import
io.swagger.v3.oas.annotations.media.Schema
;
/**
* Model
*
* @author Lizh
* @date 2026-0
5-29 10:25:16
* @date 2026-0
6-03 11:57:00
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema
(
description
=
"
CustomProductFactoryPriceRel
VO"
)
@Schema
(
description
=
"VO"
)
public
class
CustomProductFactoryPriceRelVO
implements
Serializable
{
@Serial
private
static
final
long
serialVersionUID
=
1L
;
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductImagePageVO.java
View file @
f5dd4bff
...
...
@@ -12,7 +12,7 @@ import java.util.Date;
* PageModel
*
* @author Lizh
* @date 2026-0
5-29 10:25:16
* @date 2026-0
6-03 11:57:01
*/
@Data
@Builder
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductImageVO.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
vo
;
import
lombok.*
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.util.Date
;
import
io.swagger.v3.oas.annotations.media.Schema
;
/**
* Model
*
* @author Lizh
* @date 2026-0
5-29 10:25:16
* @date 2026-0
6-03 11:57:01
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema
(
description
=
"
CustomProductImage
VO"
)
@Schema
(
description
=
"VO"
)
public
class
CustomProductImageVO
implements
Serializable
{
@Serial
private
static
final
long
serialVersionUID
=
1L
;
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductInfoPageVO.java
View file @
f5dd4bff
...
...
@@ -13,7 +13,7 @@ import java.util.Date;
* PageModel
*
* @author Lizh
* @date 2026-0
5-29 10:25:16
* @date 2026-0
6-03 11:57:02
*/
@Data
@Builder
...
...
@@ -50,24 +50,6 @@ public class CustomProductInfoPageVO extends PageRequest implements Serializable
private
String
name
;
/**
* 所属客户
*/
@Schema
(
description
=
"所属客户"
)
private
String
namespace
;
/**
* 所属工厂
*/
@Schema
(
description
=
"所属工厂"
)
private
Integer
affiliatedFactory
;
/**
* 第三方SKU
*/
@Schema
(
description
=
"第三方SKU"
)
private
String
thirdSku
;
/**
* 商品主图
*/
@Schema
(
description
=
"商品主图"
)
...
...
@@ -116,12 +98,6 @@ public class CustomProductInfoPageVO extends PageRequest implements Serializable
private
Integer
status
;
/**
* 挂起前的状态
*/
@Schema
(
description
=
"挂起前的状态"
)
private
Integer
preSuspendStatus
;
/**
*
*/
@Schema
(
description
=
""
)
...
...
@@ -206,15 +182,15 @@ public class CustomProductInfoPageVO extends PageRequest implements Serializable
private
String
currencyCode
;
/**
* 币种
* 币种
名称
*/
@Schema
(
description
=
"币种"
)
@Schema
(
description
=
"币种
名称
"
)
private
String
currencyName
;
/**
*
平台直营 客户自营
*
产品类型(platform-平台直营 customer-客户自营)
*/
@Schema
(
description
=
"
平台直营 客户自营
"
)
@Schema
(
description
=
"
产品类型(platform-平台直营 customer-客户自营)
"
)
private
String
productType
;
/**
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductInfoPropertyPageVO.java
View file @
f5dd4bff
...
...
@@ -11,7 +11,7 @@ import java.io.Serializable;
* PageModel
*
* @author Lizh
* @date 2026-0
5-29 10:25:16
* @date 2026-0
6-03 11:57:03
*/
@Data
@Builder
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductInfoPropertyVO.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
vo
;
import
lombok.*
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
io.swagger.v3.oas.annotations.media.Schema
;
/**
* Model
*
* @author Lizh
* @date 2026-0
5-29 10:25:16
* @date 2026-0
6-03 11:57:03
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema
(
description
=
"
CustomProductInfoProperty
VO"
)
@Schema
(
description
=
"VO"
)
public
class
CustomProductInfoPropertyVO
implements
Serializable
{
@Serial
private
static
final
long
serialVersionUID
=
1L
;
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductInfoVO.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
vo
;
import
lombok.*
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.util.Date
;
import
io.swagger.v3.oas.annotations.media.Schema
;
/**
* Model
*
* @author Lizh
* @date 2026-0
5-29 10:25:16
* @date 2026-0
6-03 11:57:02
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema
(
description
=
"
CustomProductInfo
VO"
)
@Schema
(
description
=
"VO"
)
public
class
CustomProductInfoVO
implements
Serializable
{
@Serial
private
static
final
long
serialVersionUID
=
1L
;
...
...
@@ -49,24 +51,6 @@ public class CustomProductInfoVO implements Serializable {
private
String
name
;
/**
* 所属客户
*/
@Schema
(
description
=
"所属客户"
)
private
String
namespace
;
/**
* 所属工厂
*/
@Schema
(
description
=
"所属工厂"
)
private
Integer
affiliatedFactory
;
/**
* 第三方SKU
*/
@Schema
(
description
=
"第三方SKU"
)
private
String
thirdSku
;
/**
* 商品主图
*/
@Schema
(
description
=
"商品主图"
)
...
...
@@ -115,12 +99,6 @@ public class CustomProductInfoVO implements Serializable {
private
Integer
status
;
/**
* 挂起前的状态
*/
@Schema
(
description
=
"挂起前的状态"
)
private
Integer
preSuspendStatus
;
/**
*
*/
@Schema
(
description
=
""
)
...
...
@@ -205,15 +183,15 @@ public class CustomProductInfoVO implements Serializable {
private
String
currencyCode
;
/**
* 币种
* 币种
名称
*/
@Schema
(
description
=
"币种"
)
@Schema
(
description
=
"币种
名称
"
)
private
String
currencyName
;
/**
*
平台直营 客户自营
*
产品类型(platform-平台直营 customer-客户自营)
*/
@Schema
(
description
=
"
平台直营 客户自营
"
)
@Schema
(
description
=
"
产品类型(platform-平台直营 customer-客户自营)
"
)
private
String
productType
;
/**
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductItemPageVO.java
View file @
f5dd4bff
...
...
@@ -13,7 +13,7 @@ import java.util.Date;
* PageModel
*
* @author Lizh
* @date 2026-0
5-29 10:25:17
* @date 2026-0
6-03 11:57:04
*/
@Data
@Builder
...
...
@@ -170,12 +170,6 @@ public class CustomProductItemPageVO extends PageRequest implements Serializable
private
BigDecimal
skuWeight
;
/**
* 注册数量
*/
@Schema
(
description
=
"注册数量"
)
private
Integer
regCount
;
/**
* 印花类型 0满印 1局部印
*/
@Schema
(
description
=
"印花类型 0满印 1局部印"
)
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductItemVO.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
vo
;
import
lombok.*
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.util.Date
;
import
io.swagger.v3.oas.annotations.media.Schema
;
/**
* Model
*
* @author Lizh
* @date 2026-0
5-29 10:25:17
* @date 2026-0
6-03 11:57:04
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema
(
description
=
"
CustomProductItem
VO"
)
@Schema
(
description
=
"VO"
)
public
class
CustomProductItemVO
implements
Serializable
{
@Serial
private
static
final
long
serialVersionUID
=
1L
;
...
...
@@ -169,12 +171,6 @@ public class CustomProductItemVO implements Serializable {
private
BigDecimal
skuWeight
;
/**
* 注册数量
*/
@Schema
(
description
=
"注册数量"
)
private
Integer
regCount
;
/**
* 印花类型 0满印 1局部印
*/
@Schema
(
description
=
"印花类型 0满印 1局部印"
)
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductRemarkPageVO.java
View file @
f5dd4bff
...
...
@@ -12,7 +12,7 @@ import java.util.Date;
* PageModel
*
* @author Lizh
* @date 2026-0
5-29 10:25:17
* @date 2026-0
6-03 11:57:05
*/
@Data
@Builder
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductRemarkVO.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
vo
;
import
lombok.*
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.util.Date
;
import
io.swagger.v3.oas.annotations.media.Schema
;
/**
* Model
*
* @author Lizh
* @date 2026-0
5-29 10:25:17
* @date 2026-0
6-03 11:57:05
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema
(
description
=
"
CustomProductRemark
VO"
)
@Schema
(
description
=
"VO"
)
public
class
CustomProductRemarkVO
implements
Serializable
{
@Serial
private
static
final
long
serialVersionUID
=
1L
;
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductWarehouseRelPageVO.java
View file @
f5dd4bff
...
...
@@ -11,7 +11,7 @@ import java.io.Serializable;
* PageModel
*
* @author Lizh
* @date 2026-0
5-29 10:25:17
* @date 2026-0
6-03 11:57:06
*/
@Data
@Builder
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/CustomProductWarehouseRelVO.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
vo
;
import
lombok.*
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
io.swagger.v3.oas.annotations.media.Schema
;
/**
* Model
*
* @author Lizh
* @date 2026-0
5-29 10:25:17
* @date 2026-0
6-03 11:57:06
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema
(
description
=
"
CustomProductWarehouseRel
VO"
)
@Schema
(
description
=
"VO"
)
public
class
CustomProductWarehouseRelVO
implements
Serializable
{
@Serial
private
static
final
long
serialVersionUID
=
1L
;
...
...
custom-server-app/src/main/java/com/jomalls/custom/app/vo/LogCustomProductPageVO.java
View file @
f5dd4bff
...
...
@@ -12,7 +12,7 @@ import java.util.Date;
* PageModel
*
* @author Lizh
* @date 2026-0
5-29 10:25:1
7
* @date 2026-0
6-03 11:57:0
7
*/
@Data
@Builder
...
...
@@ -60,11 +60,5 @@ public class LogCustomProductPageVO extends PageRequest implements Serializable
@Schema
(
description
=
"创建时间"
)
private
Date
createTime
;
/**
* 0 custom 1 factory 2都可以
*/
@Schema
(
description
=
"0 custom 1 factory 2都可以"
)
private
Integer
dataPermissions
;
}
custom-server-app/src/main/java/com/jomalls/custom/app/vo/LogCustomProductVO.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
app
.
vo
;
import
lombok.*
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.util.Date
;
import
io.swagger.v3.oas.annotations.media.Schema
;
/**
* Model
*
* @author Lizh
* @date 2026-0
5-29 10:25:1
7
* @date 2026-0
6-03 11:57:0
7
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema
(
description
=
"
LogCustomProduct
VO"
)
@Schema
(
description
=
"VO"
)
public
class
LogCustomProductVO
implements
Serializable
{
@Serial
private
static
final
long
serialVersionUID
=
1L
;
...
...
@@ -59,11 +61,5 @@ public class LogCustomProductVO implements Serializable {
@Schema
(
description
=
"创建时间"
)
private
Date
createTime
;
/**
* 0 custom 1 factory 2都可以
*/
@Schema
(
description
=
"0 custom 1 factory 2都可以"
)
private
Integer
dataPermissions
;
}
custom-server-core/src/main/java/com/jomalls/custom/security/TokenHandle.java
View file @
f5dd4bff
...
...
@@ -40,31 +40,33 @@ public class TokenHandle {
public
LoginUser
getLoginUser
(
HttpServletRequest
request
)
{
// 获取请求携带的令牌
String
token
=
getToken
(
request
);
if
(
StringUtils
.
hasText
(
token
))
{
try
{
Claims
claims
=
parseToken
(
token
);
// 解析用户信息
Long
userId
=
claims
.
get
(
"id"
,
Long
.
class
);
String
username
=
claims
.
get
(
"account"
,
String
.
class
);
if
(
username
==
null
)
{
username
=
claims
.
get
(
"username"
,
String
.
class
);
}
if
(
userId
!=
null
&&
StringUtils
.
hasText
(
username
))
{
LoginUser
loginUser
=
new
LoginUser
(
userId
,
null
,
username
);
loginUser
.
setToken
(
token
);
loginUser
.
setExpireTime
(
claims
.
getExpiration
().
getTime
());
// 获取token失败, 返回null
if
(!
StringUtils
.
hasText
(
token
))
{
return
null
;
}
try
{
Claims
claims
=
parseToken
(
token
);
// 解析用户信息
Long
userId
=
claims
.
get
(
"id"
,
Long
.
class
);
String
username
=
claims
.
get
(
"account"
,
String
.
class
);
if
(
username
==
null
)
{
username
=
claims
.
get
(
"username"
,
String
.
class
);
}
if
(
userId
!=
null
&&
StringUtils
.
hasText
(
username
))
{
LoginUser
loginUser
=
new
LoginUser
(
userId
,
null
,
username
);
loginUser
.
setToken
(
token
);
loginUser
.
setExpireTime
(
claims
.
getExpiration
().
getTime
());
// 解析权限信息
Set
<
String
>
permissions
=
parsePermissions
(
claims
);
loginUser
.
setPermissions
(
permissions
);
// 解析权限信息
Set
<
String
>
permissions
=
parsePermissions
(
claims
);
loginUser
.
setPermissions
(
permissions
);
return
loginUser
;
}
}
catch
(
JwtException
e
)
{
log
.
error
(
"JWT解析异常: {}"
,
e
.
getMessage
());
}
catch
(
Exception
e
)
{
log
.
error
(
"获取用户信息异常: {}"
,
e
.
getMessage
());
return
loginUser
;
}
}
catch
(
JwtException
e
)
{
log
.
error
(
"JWT解析异常: {}"
,
e
.
getMessage
());
}
catch
(
Exception
e
)
{
log
.
error
(
"获取用户信息异常: {}"
,
e
.
getMessage
());
}
return
null
;
}
...
...
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductBlacklistEntity.java
View file @
f5dd4bff
...
...
@@ -10,12 +10,11 @@ import lombok.Data;
import
java.io.Serial
;
import
java.io.Serializable
;
/**
* Entity
*
* @author Lizh
* @date 2026-0
5-28 19:07:12
* @date 2026-0
6-03 11:56:55
*/
@Data
@TableName
(
"custom_product_blacklist"
)
...
...
@@ -24,17 +23,15 @@ public class CustomProductBlacklistEntity implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
/**
*
主键
*
*/
@TableId
(
value
=
"id"
,
type
=
IdType
.
ASSIGN_ID
)
private
Integer
id
;
/**
* custom_product_info的id
*/
@TableField
(
"product_id"
)
private
Integer
productId
;
/**
* db_diy_user的id
*/
...
...
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductCnRemarkEntity.java
View file @
f5dd4bff
...
...
@@ -15,7 +15,7 @@ import java.util.Date;
* Entity
*
* @author Lizh
* @date 2026-0
5-28 19:07:12
* @date 2026-0
6-03 11:56:56
*/
@Data
@TableName
(
"custom_product_cn_remark"
)
...
...
@@ -28,19 +28,16 @@ public class CustomProductCnRemarkEntity implements Serializable {
*/
@TableId
(
value
=
"id"
,
type
=
IdType
.
ASSIGN_ID
)
private
Integer
id
;
/**
* custom_product_info表id
*/
@TableField
(
"product_id"
)
private
Integer
productId
;
/**
* 内容
*/
@TableField
(
"remark"
)
private
String
remark
;
/**
* 创建时间
*/
...
...
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductCraftRelEntity.java
View file @
f5dd4bff
...
...
@@ -6,6 +6,7 @@ import com.baomidou.mybatisplus.annotation.TableId;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
lombok.Data
;
import
java.io.Serial
;
import
java.io.Serializable
;
...
...
@@ -13,7 +14,7 @@ import java.io.Serializable;
* Entity
*
* @author Lizh
* @date 2026-0
5-28 19:07:12
* @date 2026-0
6-03 11:56:57
*/
@Data
@TableName
(
"custom_product_craft_rel"
)
...
...
@@ -22,17 +23,15 @@ public class CustomProductCraftRelEntity implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
/**
*
主键ID
*
*/
@TableId
(
value
=
"id"
,
type
=
IdType
.
ASSIGN_ID
)
private
Integer
id
;
/**
* custom_product_info 的id
*/
@TableField
(
"product_id"
)
private
Integer
productId
;
/**
* craft_center 的id
*/
...
...
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductDiyUserRelEntity.java
View file @
f5dd4bff
...
...
@@ -6,15 +6,15 @@ import com.baomidou.mybatisplus.annotation.TableId;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
lombok.Data
;
import
java.io.Serial
;
import
java.io.Serializable
;
/**
* Entity
*
* @author Lizh
* @date 2026-0
5-28 19:07:12
* @date 2026-0
6-03 11:56:58
*/
@Data
@TableName
(
"custom_product_diy_user_rel"
)
...
...
@@ -23,17 +23,15 @@ public class CustomProductDiyUserRelEntity implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
/**
*
主键ID
*
*/
@TableId
(
value
=
"id"
,
type
=
IdType
.
ASSIGN_ID
)
private
Integer
id
;
/**
* custom_product_info的id
*/
@TableField
(
"product_id"
)
private
Integer
productId
;
/**
* db_diy_user的id
*/
...
...
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductFactoryPriceIntervalRelEntity.java
View file @
f5dd4bff
...
...
@@ -6,16 +6,16 @@ import com.baomidou.mybatisplus.annotation.TableId;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
lombok.Data
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
/**
* Entity
*
* @author Lizh
* @date 2026-0
5-28 19:07:12
* @date 2026-0
6-03 11:56:59
*/
@Data
@TableName
(
"custom_product_factory_price_interval_rel"
)
...
...
@@ -24,11 +24,10 @@ public class CustomProductFactoryPriceIntervalRelEntity implements Serializable
private
static
final
long
serialVersionUID
=
1L
;
/**
*
主键ID
*
*/
@TableId
(
value
=
"id"
,
type
=
IdType
.
ASSIGN_ID
)
private
Integer
id
;
/**
* custom_product_info 表id
*/
...
...
@@ -39,13 +38,11 @@ public class CustomProductFactoryPriceIntervalRelEntity implements Serializable
*/
@TableField
(
"currency_code"
)
private
String
currencyCode
;
/**
* (系统成本)最大值
*/
@TableField
(
"price_max"
)
private
BigDecimal
priceMax
;
/**
* (系统成本)最小值
*/
...
...
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductFactoryPriceRelEntity.java
View file @
f5dd4bff
...
...
@@ -6,6 +6,7 @@ import com.baomidou.mybatisplus.annotation.TableId;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
lombok.Data
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
...
...
@@ -15,7 +16,7 @@ import java.util.Date;
* Entity
*
* @author Lizh
* @date 2026-0
5-28 19:07:12
* @date 2026-0
6-03 11:57:00
*/
@Data
@TableName
(
"custom_product_factory_price_rel"
)
...
...
@@ -24,67 +25,57 @@ public class CustomProductFactoryPriceRelEntity implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
/**
*
主键ID
*
*/
@TableId
(
value
=
"id"
,
type
=
IdType
.
ASSIGN_ID
)
private
Integer
id
;
/**
* custom_product_info表id
*/
@TableField
(
"product_id"
)
private
Integer
productId
;
/**
* custom_product_item表id
*/
@TableField
(
"item_id"
)
private
Integer
itemId
;
/**
* custom_product_item表sku
*/
@TableField
(
"item_sku"
)
private
String
itemSku
;
/**
* db_diy表id
*/
@TableField
(
"factory_id"
)
private
Integer
factoryId
;
/**
* 工厂价格
*/
@TableField
(
"factory_price"
)
private
BigDecimal
factoryPrice
;
/**
* 销售价
*/
@TableField
(
"sales_price"
)
private
BigDecimal
salesPrice
;
/**
* 工厂币种
*/
@TableField
(
"factory_currency_code"
)
private
String
factoryCurrencyCode
;
/**
* 售卖币种
*/
@TableField
(
"sales_currency_code"
)
private
String
salesCurrencyCode
;
/**
*
创建时间
*
*/
@TableField
(
"create_time"
)
private
Date
createTime
;
/**
*
更新时间
*
*/
@TableField
(
"update_time"
)
private
Date
updateTime
;
...
...
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductImageEntity.java
View file @
f5dd4bff
...
...
@@ -6,6 +6,7 @@ import com.baomidou.mybatisplus.annotation.TableId;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
lombok.Data
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.util.Date
;
...
...
@@ -14,7 +15,7 @@ import java.util.Date;
* Entity
*
* @author Lizh
* @date 2026-0
5-28 19:07:12
* @date 2026-0
6-03 11:57:01
*/
@Data
@TableName
(
"custom_product_image"
)
...
...
@@ -23,37 +24,32 @@ public class CustomProductImageEntity implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
/**
*
主键ID
*
*/
@TableId
(
value
=
"id"
,
type
=
IdType
.
ASSIGN_ID
)
private
Integer
id
;
/**
* 商品ID
*/
@TableField
(
"product_id"
)
private
Integer
productId
;
/**
* 图片地址
*/
@TableField
(
"image_url"
)
private
String
imageUrl
;
/**
* 排序
*/
@TableField
(
"sort"
)
private
Integer
sort
;
/**
* 类型 0普通图片 1尺码图
*/
@TableField
(
"type"
)
private
Integer
type
;
/**
*
创建时间
*
*/
@TableField
(
"create_time"
)
private
Date
createTime
;
...
...
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductInfoEntity.java
View file @
f5dd4bff
...
...
@@ -6,17 +6,17 @@ import com.baomidou.mybatisplus.annotation.TableId;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
lombok.Data
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.util.Date
;
/**
* Entity
*
* @author Lizh
* @date 2026-0
5-28 19:07:1
2
* @date 2026-0
6-03 11:57:0
2
*/
@Data
@TableName
(
"custom_product_info"
)
...
...
@@ -29,235 +29,176 @@ public class CustomProductInfoEntity implements Serializable {
*/
@TableId
(
value
=
"id"
,
type
=
IdType
.
ASSIGN_ID
)
private
Integer
id
;
/**
* sku
*/
@TableField
(
"sku"
)
private
String
sku
;
/**
*
*/
@TableField
(
"title"
)
private
String
title
;
/**
* 商品名称
*/
@TableField
(
"name"
)
private
String
name
;
/**
* 所属客户
*/
@TableField
(
"namespace"
)
private
String
namespace
;
/**
* 所属工厂
*/
@TableField
(
"affiliated_factory"
)
private
Integer
affiliatedFactory
;
/**
* 第三方SKU
*/
@TableField
(
"third_sku"
)
private
String
thirdSku
;
/**
* 商品主图
*/
@TableField
(
"img_url"
)
private
String
imgUrl
;
/**
* 商品类别ID
*/
@TableField
(
"category_id"
)
private
Integer
categoryId
;
/**
* 重量kg
*/
@TableField
(
"weight"
)
private
BigDecimal
weight
;
/**
* 最小采购量
*/
@TableField
(
"purchasing_min"
)
private
Integer
purchasingMin
;
/**
* 工厂价(¥)
*/
@TableField
(
"factory_price"
)
private
BigDecimal
factoryPrice
;
/**
* 销售价(¥)
*/
@TableField
(
"sales_price"
)
private
BigDecimal
salesPrice
;
/**
* 销售价最大值(¥)
*/
@TableField
(
"sales_price_max"
)
private
BigDecimal
salesPriceMax
;
/**
* 1待上架 10已上架 20已下架 30待下架 40已作废
*/
@TableField
(
"status"
)
private
Integer
status
;
/**
* 挂起前的状态
*/
@TableField
(
"pre_suspend_status"
)
private
Integer
preSuspendStatus
;
/**
*
*/
@TableField
(
"property1_cate_id"
)
private
Integer
property1CateId
;
/**
*
*/
@TableField
(
"property2_cate_id"
)
private
Integer
property2CateId
;
/**
*
*/
@TableField
(
"property3_cate_id"
)
private
Integer
property3CateId
;
/**
*
*/
@TableField
(
"property1_enname"
)
private
String
property1Enname
;
/**
*
*/
@TableField
(
"property2_enname"
)
private
String
property2Enname
;
/**
*
*/
@TableField
(
"property3_enname"
)
private
String
property3Enname
;
/**
* 颜色图
*/
@TableField
(
"color_images"
)
private
String
colorImages
;
/**
* 材质
*/
@TableField
(
"material"
)
private
String
material
;
/**
* 印花类型 0满印 1局部印
*/
@TableField
(
"print_type"
)
private
Integer
printType
;
/**
* 货号
*/
@TableField
(
"product_no"
)
private
String
productNo
;
/**
* 产地code
*/
@TableField
(
"origin_code"
)
private
String
originCode
;
/**
* 产地中文名字
*/
@TableField
(
"origin_name_cn"
)
private
String
originNameCn
;
/**
* 产地英文名字
*/
@TableField
(
"origin_name_en"
)
private
String
originNameEn
;
/**
* 币种code
*/
@TableField
(
"currency_code"
)
private
String
currencyCode
;
/**
* 币种
* 币种
名称
*/
@TableField
(
"currency_name"
)
private
String
currencyName
;
/**
*
平台直营 客户自营
*
产品类型(platform-平台直营 customer-客户自营)
*/
@TableField
(
"product_type"
)
private
String
productType
;
/**
* 工厂id
*/
@TableField
(
"factory_id"
)
private
Integer
factoryId
;
/**
* 工厂编码
*/
@TableField
(
"factory_code"
)
private
String
factoryCode
;
/**
* 是否九猫处理
*/
@TableField
(
"processing"
)
private
Boolean
processing
;
/**
* 创建时间
*/
@TableField
(
"create_time"
)
private
Date
createTime
;
/**
*
*/
@TableField
(
"update_time"
)
private
Date
updateTime
;
/**
*
*/
@TableField
(
"sort"
)
private
Integer
sort
;
/**
* 默认模ID
*/
@TableField
(
"diy_id"
)
private
Integer
diyId
;
/**
* 默认模SKU
*/
...
...
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductInfoPropertyEntity.java
View file @
f5dd4bff
...
...
@@ -10,12 +10,11 @@ import lombok.Data;
import
java.io.Serial
;
import
java.io.Serializable
;
/**
* Entity
*
* @author Lizh
* @date 2026-0
5-28 19:07:12
* @date 2026-0
6-03 11:57:03
*/
@Data
@TableName
(
"custom_product_info_property"
)
...
...
@@ -28,25 +27,21 @@ public class CustomProductInfoPropertyEntity implements Serializable {
*/
@TableId
(
value
=
"id"
,
type
=
IdType
.
ASSIGN_ID
)
private
Integer
id
;
/**
* custom_product_info表id
*/
@TableField
(
"info_id"
)
private
Integer
infoId
;
/**
* 属性类ID
*/
@TableField
(
"property_id"
)
private
Integer
propertyId
;
/**
* 属性值ID
*/
@TableField
(
"value_id"
)
private
Integer
valueId
;
/**
* 是否为SKU属性
*/
...
...
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductItemEntity.java
View file @
f5dd4bff
...
...
@@ -6,17 +6,17 @@ import com.baomidou.mybatisplus.annotation.TableId;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
lombok.Data
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.util.Date
;
/**
* Entity
*
* @author Lizh
* @date 2026-0
5-28 19:07:13
* @date 2026-0
6-03 11:57:04
*/
@Data
@TableName
(
"custom_product_item"
)
...
...
@@ -29,181 +29,146 @@ public class CustomProductItemEntity implements Serializable {
*/
@TableId
(
value
=
"id"
,
type
=
IdType
.
ASSIGN_ID
)
private
Integer
id
;
/**
* 商品ID
*/
@TableField
(
"product_id"
)
private
Integer
productId
;
/**
* sku
*/
@TableField
(
"sku"
)
private
String
sku
;
/**
* sku商品名称
*/
@TableField
(
"sku_name"
)
private
String
skuName
;
/**
* 封面图
*/
@TableField
(
"image"
)
private
String
image
;
/**
* 图片集
*/
@TableField
(
"image_ary"
)
private
String
imageAry
;
/**
* 属性分类ID1
*/
@TableField
(
"property_cate_id1"
)
private
Integer
propertyCateId1
;
/**
* 属性分类ID2
*/
@TableField
(
"property_cate_id2"
)
private
Integer
propertyCateId2
;
/**
* 属性分类ID3
*/
@TableField
(
"property_cate_id3"
)
private
Integer
propertyCateId3
;
/**
*
*/
@TableField
(
"property1_id"
)
private
Integer
property1Id
;
/**
*
*/
@TableField
(
"property2_id"
)
private
Integer
property2Id
;
/**
*
*/
@TableField
(
"property3_id"
)
private
Integer
property3Id
;
/**
* 属性编码1
*/
@TableField
(
"property_code1"
)
private
String
propertyCode1
;
/**
* 属性编码2
*/
@TableField
(
"property_code2"
)
private
String
propertyCode2
;
/**
*
*/
@TableField
(
"property_code3"
)
private
String
propertyCode3
;
/**
* 属性名称1
*/
@TableField
(
"option_enname1"
)
private
String
optionEnname1
;
/**
* 属性名称2
*/
@TableField
(
"option_enname2"
)
private
String
optionEnname2
;
/**
*
*/
@TableField
(
"option_enname3"
)
private
String
optionEnname3
;
/**
*
*/
@TableField
(
"custom_value1"
)
private
String
customValue1
;
/**
*
*/
@TableField
(
"custom_value2"
)
private
String
customValue2
;
/**
*
*/
@TableField
(
"custom_value3"
)
private
String
customValue3
;
/**
* 工厂价
*/
@TableField
(
"factory_price"
)
private
BigDecimal
factoryPrice
;
/**
* 销售价
*/
@TableField
(
"sales_price"
)
private
BigDecimal
salesPrice
;
/**
* sku克重
*/
@TableField
(
"sku_weight"
)
private
BigDecimal
skuWeight
;
/**
* 注册数量
*/
@TableField
(
"reg_count"
)
private
Integer
regCount
;
/**
* 印花类型 0满印 1局部印
*/
@TableField
(
"print_type"
)
private
Integer
printType
;
/**
* 排序
*/
@TableField
(
"sort"
)
private
Integer
sort
;
/**
* 货号
*/
@TableField
(
"product_no"
)
private
String
productNo
;
/**
* 1正常码 2大码
*/
@TableField
(
"size_type"
)
private
Integer
sizeType
;
/**
* 创建时间
*/
@TableField
(
"create_time"
)
private
Date
createTime
;
/**
* 更新时间
*/
...
...
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductRemarkEntity.java
View file @
f5dd4bff
...
...
@@ -6,6 +6,7 @@ import com.baomidou.mybatisplus.annotation.TableId;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
lombok.Data
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.util.Date
;
...
...
@@ -14,7 +15,7 @@ import java.util.Date;
* Entity
*
* @author Lizh
* @date 2026-0
5-28 19:07:13
* @date 2026-0
6-03 11:57:05
*/
@Data
@TableName
(
"custom_product_remark"
)
...
...
@@ -27,19 +28,16 @@ public class CustomProductRemarkEntity implements Serializable {
*/
@TableId
(
value
=
"id"
,
type
=
IdType
.
ASSIGN_ID
)
private
Integer
id
;
/**
* custom_product_info表id
*/
@TableField
(
"product_id"
)
private
Integer
productId
;
/**
* 内容
*/
@TableField
(
"remark"
)
private
String
remark
;
/**
* 创建时间
*/
...
...
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/CustomProductWarehouseRelEntity.java
View file @
f5dd4bff
...
...
@@ -6,15 +6,15 @@ import com.baomidou.mybatisplus.annotation.TableId;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
lombok.Data
;
import
java.io.Serial
;
import
java.io.Serializable
;
/**
* Entity
*
* @author Lizh
* @date 2026-0
5-28 19:07:13
* @date 2026-0
6-03 11:57:06
*/
@Data
@TableName
(
"custom_product_warehouse_rel"
)
...
...
@@ -27,13 +27,11 @@ public class CustomProductWarehouseRelEntity implements Serializable {
*/
@TableId
(
value
=
"id"
,
type
=
IdType
.
ASSIGN_ID
)
private
Integer
id
;
/**
*
*/
@TableField
(
"product_id"
)
private
Integer
productId
;
/**
*
*/
...
...
custom-server-domain/src/main/java/com/jomalls/custom/dal/entity/LogCustomProductEntity.java
View file @
f5dd4bff
...
...
@@ -6,6 +6,7 @@ import com.baomidou.mybatisplus.annotation.TableId;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
lombok.Data
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.util.Date
;
...
...
@@ -14,7 +15,7 @@ import java.util.Date;
* Entity
*
* @author Lizh
* @date 2026-0
5-28 19:07:13
* @date 2026-0
6-03 11:57:07
*/
@Data
@TableName
(
"log_custom_product"
)
...
...
@@ -27,41 +28,30 @@ public class LogCustomProductEntity implements Serializable {
*/
@TableId
(
value
=
"id"
,
type
=
IdType
.
ASSIGN_ID
)
private
Long
id
;
/**
* 商品id(custom_product_info表id)
*/
@TableField
(
"product_id"
)
private
Integer
productId
;
/**
* 操作人id
*/
@TableField
(
"employee_id"
)
private
Integer
employeeId
;
/**
* 操作人账号
*/
@TableField
(
"employee_account"
)
private
String
employeeAccount
;
/**
* 操作描述
*/
@TableField
(
"description"
)
private
String
description
;
/**
* 创建时间
*/
@TableField
(
"create_time"
)
private
Date
createTime
;
/**
* 0 custom 1 factory 2都可以
*/
@TableField
(
"data_permissions"
)
private
Integer
dataPermissions
;
}
custom-server-starter/src/main/java/com/jomalls/custom/config/CommonExceptionHandlerAdvice.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
config
;
import
com.jomalls.custom.app.enums.CodeEnum
;
import
com.jomalls.custom.app.exception.InvalidTokenException
;
import
com.jomalls.custom.app.exception.PermissionDeniedException
;
import
com.jomalls.custom.app.exception.ServiceException
;
import
org.springframework.http.HttpStatus
;
...
...
@@ -12,6 +13,15 @@ import org.springframework.web.bind.annotation.RestControllerAdvice;
public
class
CommonExceptionHandlerAdvice
{
/**
* token验证失败(返回401 未登录或登录已过期)
*/
@ExceptionHandler
(
InvalidTokenException
.
class
)
public
ResponseEntity
<
com
.
jomalls
.
custom
.
app
.
utils
.
R
<
Object
>>
handleInvalidTokenException
(
PermissionDeniedException
e
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
UNAUTHORIZED
)
.
body
(
com
.
jomalls
.
custom
.
app
.
utils
.
R
.
fail
(
CodeEnum
.
UNAUTHORIZED
.
getCode
(),
e
.
getMessage
()));
}
/**
* 权限异常处理(返回403 Forbidden)
*/
@ExceptionHandler
(
PermissionDeniedException
.
class
)
...
...
custom-server-starter/src/main/java/com/jomalls/custom/config/SecurityInterceptor.java
View file @
f5dd4bff
...
...
@@ -2,6 +2,8 @@
package
com
.
jomalls
.
custom
.
config
;
import
com.jomalls.custom.app.enums.CodeEnum
;
import
com.jomalls.custom.app.exception.InvalidTokenException
;
import
com.jomalls.custom.app.utils.RequestHolder
;
import
com.jomalls.custom.security.LoginUser
;
import
com.jomalls.custom.security.SecurityUtils
;
...
...
@@ -47,21 +49,20 @@ public class SecurityInterceptor implements HandlerInterceptor {
// 获取登录用户信息
LoginUser
loginUser
=
tokenHandle
.
getLoginUser
(
request
);
// 如果有登录用户,保存到线程本地变量
if
(
loginUser
!=
null
)
{
// 验证token是否有效
if
(
tokenHandle
.
verifyToken
(
loginUser
))
{
SecurityUtils
.
setLoginUser
(
loginUser
);
log
.
debug
(
"用户[{}]登录验证通过,请求URI: {}"
,
loginUser
.
getUsername
(),
request
.
getRequestURI
());
return
true
;
}
else
{
log
.
warn
(
"用户[{}]token已过期,请求URI: {}"
,
loginUser
.
getUsername
(),
request
.
getRequestURI
());
}
// 如果用户没有登录,返回提示
if
(
loginUser
==
null
)
{
throw
new
InvalidTokenException
(
CodeEnum
.
UNAUTHORIZED
.
getCode
(),
"未登录或登录已过期"
);
}
// 未登录或token无效,允许继续(由后续业务逻辑决定是否需要登录)
// 如果需要强制登录,这里可以抛出异常或返回401
return
true
;
// 验证token是否有效
if
(
tokenHandle
.
verifyToken
(
loginUser
))
{
SecurityUtils
.
setLoginUser
(
loginUser
);
log
.
debug
(
"用户[{}]登录验证通过,请求URI: {}"
,
loginUser
.
getUsername
(),
request
.
getRequestURI
());
return
true
;
}
else
{
log
.
warn
(
"用户[{}]token已过期,请求URI: {}"
,
loginUser
.
getUsername
(),
request
.
getRequestURI
());
}
return
false
;
}
/**
...
...
custom-server-webapp/src/main/java/com/jomalls/custom/webapp/controller/CustomProductCraftRelController.java
View file @
f5dd4bff
package
com
.
jomalls
.
custom
.
webapp
.
controller
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.jomalls.custom.app.annotation.RequiresPermissions
;
import
com.jomalls.custom.app.vo.CustomProductCraftRelPageVO
;
import
com.jomalls.custom.app.vo.CustomProductCraftRelVO
;
import
com.jomalls.custom.app.service.CustomProductCraftRelService
;
...
...
@@ -37,6 +38,7 @@ public class CustomProductCraftRelController {
* @return list集合
*/
@Operation
(
summary
=
"列表查询接口"
,
description
=
"根据条件查询列表接口(不分页)"
)
@RequiresPermissions
(
value
=
"demo:permission:edit"
,
mode
=
RequiresPermissions
.
RequireMode
.
ANY
)
@RequestMapping
(
value
=
"/list"
,
method
=
RequestMethod
.
POST
)
public
List
<
CustomProductCraftRelVO
>
list
(
@RequestBody
CustomProductCraftRelVO
customProductCraftRelVO
)
{
return
customProductCraftRelService
.
list
(
customProductCraftRelVO
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment