From ab9bc35f9f3e6fe2e57fe054aa0dc898fe9a8d2c Mon Sep 17 00:00:00 2001
From: 疯狂的狮子li <15040126243@163.com>
Date: 星期四, 02 九月 2021 15:45:57 +0800
Subject: [PATCH] update MP字段验证策略更改为 NOT_NULL 个别特殊字段使用注解单独处理

---
 ruoyi-common/src/main/java/com/ruoyi/common/utils/SecurityUtils.java |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/ruoyi-common/src/main/java/com/ruoyi/common/utils/SecurityUtils.java b/ruoyi-common/src/main/java/com/ruoyi/common/utils/SecurityUtils.java
index 1a20d60..969eaf5 100644
--- a/ruoyi-common/src/main/java/com/ruoyi/common/utils/SecurityUtils.java
+++ b/ruoyi-common/src/main/java/com/ruoyi/common/utils/SecurityUtils.java
@@ -5,7 +5,7 @@
 import org.springframework.security.core.context.SecurityContextHolder;
 import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
 import com.ruoyi.common.core.domain.model.LoginUser;
-import com.ruoyi.common.exception.CustomException;
+import com.ruoyi.common.exception.ServiceException;
 
 /**
  * 瀹夊叏鏈嶅姟宸ュ叿绫�
@@ -25,7 +25,7 @@
         }
         catch (Exception e)
         {
-            throw new CustomException("鑾峰彇鐢ㄦ埛ID寮傚父", HttpStatus.UNAUTHORIZED);
+            throw new ServiceException("鑾峰彇鐢ㄦ埛ID寮傚父", HttpStatus.HTTP_UNAUTHORIZED);
         }
     }
 
@@ -40,7 +40,7 @@
         }
         catch (Exception e)
         {
-            throw new CustomException("鑾峰彇閮ㄩ棬ID寮傚父", HttpStatus.UNAUTHORIZED);
+            throw new ServiceException("鑾峰彇閮ㄩ棬ID寮傚父", HttpStatus.HTTP_UNAUTHORIZED);
         }
     }
 
@@ -55,7 +55,7 @@
         }
         catch (Exception e)
         {
-            throw new CustomException("鑾峰彇鐢ㄦ埛璐︽埛寮傚父", HttpStatus.HTTP_UNAUTHORIZED);
+            throw new ServiceException("鑾峰彇鐢ㄦ埛璐︽埛寮傚父", HttpStatus.HTTP_UNAUTHORIZED);
         }
     }
 
@@ -70,7 +70,7 @@
         }
         catch (Exception e)
         {
-            throw new CustomException("鑾峰彇鐢ㄦ埛淇℃伅寮傚父", HttpStatus.HTTP_UNAUTHORIZED);
+            throw new ServiceException("鑾峰彇鐢ㄦ埛淇℃伅寮傚父", HttpStatus.HTTP_UNAUTHORIZED);
         }
     }
 

--
Gitblit v1.9.3