From 59926aa2f4ce3b06ee1cab7260e1b3b42f617d46 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9B=BE=E6=96=87=E8=B1=AA?= <980287353@qq.com>
Date: Thu, 11 Jul 2024 15:37:03 +0800
Subject: [PATCH] publish 2.0.0.rc5
---
pom.xml | 22 +++++++++----------
springboot-ademo/pom.xml | 4 ++--
.../demo/controller/TestController.java | 4 +++-
springboot-annotation/pom.xml | 2 +-
springboot-database/pom.xml | 2 +-
springboot-encrypt/pom.xml | 2 +-
springboot-login/pom.xml | 2 +-
.../login/config/TokenWebMvcConfigurer.java | 10 ++++++++-
springboot-message/pom.xml | 2 +-
springboot-platform/pom.xml | 2 +-
springboot-poi/pom.xml | 2 +-
springboot-role/pom.xml | 2 +-
springboot-util/pom.xml | 2 +-
springboot-web/pom.xml | 2 +-
14 files changed, 35 insertions(+), 25 deletions(-)
diff --git a/pom.xml b/pom.xml
index fe40445..33f8d01 100644
--- a/pom.xml
+++ b/pom.xml
@@ -6,7 +6,7 @@
com.tiesheng.springboot-parent
springboot-parent
- 2.0.0.rc4
+ 2.0.0.rc5
pom
springboot-parent
杭州铁晟科技有限公司基础依赖
@@ -58,61 +58,61 @@
com.tiesheng.springboot-parent
springboot-database
- 2.0.0.rc4
+ 2.0.0.rc5
com.tiesheng.springboot-parent
springboot-login
- 2.0.0.rc4
+ 2.0.0.rc5
com.tiesheng.springboot-parent
springboot-web
- 2.0.0.rc4
+ 2.0.0.rc5
com.tiesheng.springboot-parent
springboot-util
- 2.0.0.rc4
+ 2.0.0.rc5
com.tiesheng.springboot-parent
springboot-platform
- 2.0.0.rc4
+ 2.0.0.rc5
com.tiesheng.springboot-parent
springboot-message
- 2.0.0.rc4
+ 2.0.0.rc5
com.tiesheng.springboot-parent
springboot-encrypt
- 2.0.0.rc4
+ 2.0.0.rc5
com.tiesheng.springboot-parent
springboot-role
- 2.0.0.rc4
+ 2.0.0.rc5
com.tiesheng.springboot-parent
springboot-annotation
- 2.0.0.rc4
+ 2.0.0.rc5
com.tiesheng.springboot-parent
springboot-poi
- 2.0.0.rc4
+ 2.0.0.rc5
diff --git a/springboot-ademo/pom.xml b/springboot-ademo/pom.xml
index 6b7dd38..1598176 100644
--- a/springboot-ademo/pom.xml
+++ b/springboot-ademo/pom.xml
@@ -6,11 +6,11 @@
com.tiesheng.springboot-parent
springboot-parent
- 2.0.0.rc4
+ 2.0.0.rc5
springboot-ademo
- 2.0.0.rc4
+ 2.0.0.rc5
8
diff --git a/springboot-ademo/src/main/java/com/tiesheng/demo/controller/TestController.java b/springboot-ademo/src/main/java/com/tiesheng/demo/controller/TestController.java
index 8ead4ed..1b688f4 100644
--- a/springboot-ademo/src/main/java/com/tiesheng/demo/controller/TestController.java
+++ b/springboot-ademo/src/main/java/com/tiesheng/demo/controller/TestController.java
@@ -9,6 +9,7 @@ import com.alibaba.excel.EasyExcel;
import com.alibaba.excel.context.AnalysisContext;
import com.alibaba.excel.read.listener.ReadListener;
import com.tiesheng.annotation.token.TokenIgnore;
+import com.tiesheng.util.pojos.TokenBean;
import com.tiesheng.web.service.CoreLogService;
import com.tiesheng.web.service.CoreMessageService;
import com.tiesheng.web.util.ProcessImportConsumer;
@@ -55,7 +56,8 @@ public class TestController {
@RequestMapping("/index")
- public ApiResp index() {
+ @TokenIgnore
+ public ApiResp index(TokenBean tokenBean) {
return ApiResp.respOK("hello world");
}
diff --git a/springboot-annotation/pom.xml b/springboot-annotation/pom.xml
index a1c42c2..361efcb 100644
--- a/springboot-annotation/pom.xml
+++ b/springboot-annotation/pom.xml
@@ -6,7 +6,7 @@
com.tiesheng.springboot-parent
springboot-parent
- 2.0.0.rc4
+ 2.0.0.rc5
springboot-annotation
diff --git a/springboot-database/pom.xml b/springboot-database/pom.xml
index 4476aa7..d29492a 100644
--- a/springboot-database/pom.xml
+++ b/springboot-database/pom.xml
@@ -6,7 +6,7 @@
com.tiesheng.springboot-parent
springboot-parent
- 2.0.0.rc4
+ 2.0.0.rc5
springboot-database
diff --git a/springboot-encrypt/pom.xml b/springboot-encrypt/pom.xml
index 5e728a2..6e95cbb 100644
--- a/springboot-encrypt/pom.xml
+++ b/springboot-encrypt/pom.xml
@@ -6,7 +6,7 @@
com.tiesheng.springboot-parent
springboot-parent
- 2.0.0.rc4
+ 2.0.0.rc5
springboot-encrypt
diff --git a/springboot-login/pom.xml b/springboot-login/pom.xml
index f32ed4f..4141ea6 100644
--- a/springboot-login/pom.xml
+++ b/springboot-login/pom.xml
@@ -6,7 +6,7 @@
com.tiesheng.springboot-parent
springboot-parent
- 2.0.0.rc4
+ 2.0.0.rc5
springboot-login
diff --git a/springboot-login/src/main/java/com/tiesheng/login/config/TokenWebMvcConfigurer.java b/springboot-login/src/main/java/com/tiesheng/login/config/TokenWebMvcConfigurer.java
index 237ef6e..6416846 100644
--- a/springboot-login/src/main/java/com/tiesheng/login/config/TokenWebMvcConfigurer.java
+++ b/springboot-login/src/main/java/com/tiesheng/login/config/TokenWebMvcConfigurer.java
@@ -19,6 +19,7 @@ import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
+import java.lang.reflect.Method;
import java.util.List;
@@ -40,7 +41,14 @@ public class TokenWebMvcConfigurer implements WebMvcConfigurer {
public Object resolveArgument(MethodParameter parameter, ModelAndViewContainer mavContainer,
NativeWebRequest webRequest, WebDataBinderFactory binderFactory) {
String header = webRequest.getHeader(TsTokenConfig.TOKEN_KEY);
- return tsTokenConfig.validToken(header, true);
+
+ boolean thrExp = true;
+ Method method = parameter.getMethod();
+ if (method != null) {
+ TokenIgnore annotation = method.getAnnotation(TokenIgnore.class);
+ thrExp = annotation == null;
+ }
+ return tsTokenConfig.validToken(header, thrExp);
}
});
}
diff --git a/springboot-message/pom.xml b/springboot-message/pom.xml
index 55839dd..73d2f8b 100644
--- a/springboot-message/pom.xml
+++ b/springboot-message/pom.xml
@@ -6,7 +6,7 @@
com.tiesheng.springboot-parent
springboot-parent
- 2.0.0.rc4
+ 2.0.0.rc5
springboot-message
diff --git a/springboot-platform/pom.xml b/springboot-platform/pom.xml
index 9fbdd84..ad544db 100644
--- a/springboot-platform/pom.xml
+++ b/springboot-platform/pom.xml
@@ -6,7 +6,7 @@
com.tiesheng.springboot-parent
springboot-parent
- 2.0.0.rc4
+ 2.0.0.rc5
springboot-platform
diff --git a/springboot-poi/pom.xml b/springboot-poi/pom.xml
index ca46c32..a9fc3be 100644
--- a/springboot-poi/pom.xml
+++ b/springboot-poi/pom.xml
@@ -6,7 +6,7 @@
com.tiesheng.springboot-parent
springboot-parent
- 2.0.0.rc4
+ 2.0.0.rc5
springboot-poi
diff --git a/springboot-role/pom.xml b/springboot-role/pom.xml
index 497ddd9..93190b9 100644
--- a/springboot-role/pom.xml
+++ b/springboot-role/pom.xml
@@ -6,7 +6,7 @@
com.tiesheng.springboot-parent
springboot-parent
- 2.0.0.rc4
+ 2.0.0.rc5
springboot-role
diff --git a/springboot-util/pom.xml b/springboot-util/pom.xml
index bdbe004..449d3e1 100644
--- a/springboot-util/pom.xml
+++ b/springboot-util/pom.xml
@@ -6,7 +6,7 @@
com.tiesheng.springboot-parent
springboot-parent
- 2.0.0.rc4
+ 2.0.0.rc5
springboot-util
diff --git a/springboot-web/pom.xml b/springboot-web/pom.xml
index 3d845f2..228344f 100644
--- a/springboot-web/pom.xml
+++ b/springboot-web/pom.xml
@@ -6,7 +6,7 @@
com.tiesheng.springboot-parent
springboot-parent
- 2.0.0.rc4
+ 2.0.0.rc5
springboot-web