From 5e19b011d2b5dcc4cc821589b506e2d1d9beb894 Mon Sep 17 00:00:00 2001 From: Hzq <670952964@qq.com> Date: Fri, 17 Sep 2021 03:01:47 +0000 Subject: [PATCH 1/2] =?UTF-8?q?!159=20=E5=BC=82=E5=B8=B8=E7=B1=BB=E5=9E=8B?= =?UTF-8?q?=E9=94=99=E8=AF=AF=20*=20=E5=9D=8F=E7=9A=84=E5=87=AD=E8=AF=81?= =?UTF-8?q?=E5=BC=82=E5=B8=B8=20*=20=E5=9D=8F=E7=9A=84=E5=87=AD=E8=AF=81?= =?UTF-8?q?=E5=BC=82=E5=B8=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pig/auth/grant/PhoneAuthenticationProvider.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pig-auth/src/main/java/com/pig4cloud/pig/auth/grant/PhoneAuthenticationProvider.java b/pig-auth/src/main/java/com/pig4cloud/pig/auth/grant/PhoneAuthenticationProvider.java index efe873de..45da921f 100644 --- a/pig-auth/src/main/java/com/pig4cloud/pig/auth/grant/PhoneAuthenticationProvider.java +++ b/pig-auth/src/main/java/com/pig4cloud/pig/auth/grant/PhoneAuthenticationProvider.java @@ -3,8 +3,8 @@ package com.pig4cloud.pig.auth.grant; import com.pig4cloud.pig.common.security.service.PigUserDetailsServiceImpl; import lombok.Setter; import lombok.extern.slf4j.Slf4j; -import org.springframework.beans.factory.BeanCreationException; import org.springframework.security.authentication.AuthenticationProvider; +import org.springframework.security.authentication.BadCredentialsException; import org.springframework.security.core.Authentication; import org.springframework.security.core.AuthenticationException; import org.springframework.security.core.userdetails.UserDetails; @@ -28,7 +28,7 @@ public class PhoneAuthenticationProvider implements AuthenticationProvider { if (authentication.getCredentials() == null) { log.debug("Failed to authenticate since no credentials provided"); - throw new BeanCreationException("Bad credentials"); + throw new BadCredentialsException("Bad credentials"); } // 手机号 @@ -45,7 +45,7 @@ public class PhoneAuthenticationProvider implements AuthenticationProvider { boolean matches = passwordEncoder.matches(code, password); if (!matches) { - throw new BeanCreationException("Bad credentials"); + throw new BadCredentialsException("Bad credentials"); } PhoneAuthenticationToken token = new PhoneAuthenticationToken(userDetails); From fe3d3e0435ed22eb8c45be1a5fc860f7516060c0 Mon Sep 17 00:00:00 2001 From: Lht Date: Sun, 19 Sep 2021 23:19:27 +0800 Subject: [PATCH 2/2] =?UTF-8?q?:green=5Fheart:=20=E4=BF=AE=E5=A4=8Dpig.sql?= =?UTF-8?q?=E7=BC=96=E7=A0=81=E6=A0=BC=E5=BC=8F=E4=B8=8D=E4=B8=80=E8=87=B4?= =?UTF-8?q?=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- db/pig.sql | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/db/pig.sql b/db/pig.sql index 2b288114..884f68ab 100644 --- a/db/pig.sql +++ b/db/pig.sql @@ -414,10 +414,10 @@ COMMIT; DROP TABLE IF EXISTS `sys_file`; CREATE TABLE `sys_file` ( `id` bigint NOT NULL AUTO_INCREMENT COMMENT '编号', - `file_name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT NULL, - `bucket_name` varchar(200) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT NULL, - `original` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT NULL, - `type` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT NULL, + `file_name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL, + `bucket_name` varchar(200) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL, + `original` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL, + `type` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL, `file_size` bigint DEFAULT NULL COMMENT '文件大小', `del_flag` char(1) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '0' COMMENT '0-正常,1-删除', `create_time` datetime DEFAULT NULL COMMENT '创建时间',