diff --git a/aircraft-common/src/main/java/com/aircraft/utils/SecurityUtils.java b/aircraft-common/src/main/java/com/aircraft/utils/SecurityUtils.java index 0591349..7556e41 100644 --- a/aircraft-common/src/main/java/com/aircraft/utils/SecurityUtils.java +++ b/aircraft-common/src/main/java/com/aircraft/utils/SecurityUtils.java @@ -164,11 +164,7 @@ public class SecurityUtils { * @return 系统用户类型 */ public static UserTypeEnum getCurrentUserType(){ - UserDetails userDetails = getCurrentUser(); - // 将 Java 对象转换为 JSONObject 对象 - JSONObject jsonObject = (JSONObject) JSON.toJSON(userDetails); - String userTypeStr = jsonObject.getString("userType"); - return UserTypeEnum.valueOf(userTypeStr); + return getCurrentUserTypeVo(); } public static String getCurrentEmployee(){