From f930c9ac4bdbe0faf6077dbb39a8cacb7bbbe761 Mon Sep 17 00:00:00 2001 From: Jie Zheng <201507802@qq.com> Date: Wed, 22 Jan 2025 10:24:07 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=8D=87=E7=BA=A7=E9=83=A8=E5=88=86?= =?UTF-8?q?=E4=BE=9D=E8=B5=96=E4=BA=8E=E4=BC=98=E5=8C=96=E4=BB=A3=E7=A0=81?= =?UTF-8?q?=EF=BC=88=E5=8D=87=E7=BA=A7fastjson2=EF=BC=8C=E4=B8=8D=E5=86=8D?= =?UTF-8?q?=E5=85=BC=E5=AE=B9fastjson1=EF=BC=89=EF=BC=8C=E5=85=B6=E4=BB=96?= =?UTF-8?q?=E5=8D=87=E7=BA=A7=E7=9C=8B=E8=AF=A6=E6=83=85=20=E5=8D=87?= =?UTF-8?q?=E7=BA=A7=20hutool=EF=BC=9A5.8.35=20=E5=8D=87=E7=BA=A7=20oshi-c?= =?UTF-8?q?ore=EF=BC=9A6.6.5=20=E5=8D=87=E7=BA=A7=20mica-ip2region?= =?UTF-8?q?=EF=BC=9A2.7.18.9=20=E5=8D=87=E7=BA=A7=20poi=EF=BC=9A5.4.0=20?= =?UTF-8?q?=E5=8D=87=E7=BA=A7=20commons-text=EF=BC=9A1.13.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- eladmin-web/README.md | 11 +++- eladmin-web/package.json | 10 ++-- eladmin/eladmin-common/pom.xml | 6 +-- .../zhengjie/config/RedisConfiguration.java | 31 +++++------ .../zhengjie/config/RemoveDruidAdConfig.java | 3 +- .../config/webConfig/ConfigurerAdapter.java | 13 ++--- .../config/webConfig/SwaggerConfig.java | 2 +- .../java/me/zhengjie/utils/RedisUtils.java | 2 +- .../java/me/zhengjie/utils/SecurityUtils.java | 6 +-- .../me/zhengjie/utils/SpringBeanHolder.java | 2 +- .../java/me/zhengjie/utils/StringUtils.java | 2 +- eladmin/eladmin-generator/pom.xml | 4 +- eladmin/eladmin-logging/pom.xml | 4 +- .../main/java/me/zhengjie/domain/SysLog.java | 2 +- .../service/impl/SysLogServiceImpl.java | 4 +- eladmin/eladmin-system/pom.xml | 6 +-- .../service/websocket/WebSocketServer.java | 4 +- .../modules/quartz/utils/QuartzRunnable.java | 2 +- .../security/service/dto/JwtUserDto.java | 2 +- .../zhengjie/modules/system/domain/Dept.java | 6 ++- .../zhengjie/modules/system/domain/Menu.java | 5 +- .../zhengjie/modules/system/domain/User.java | 2 +- eladmin/eladmin-tools/pom.xml | 4 +- .../service/impl/QiniuContentServiceImpl.java | 4 +- eladmin/pom.xml | 54 +++++++++++++------ 25 files changed, 106 insertions(+), 85 deletions(-) diff --git a/eladmin-web/README.md b/eladmin-web/README.md index ae1f7a0..4ba4a0e 100644 --- a/eladmin-web/README.md +++ b/eladmin-web/README.md @@ -7,7 +7,7 @@ 模板文档: [https://panjiachen.github.io/vue-element-admin-site/zh/guide/](https://panjiachen.github.io/vue-element-admin-site/zh/guide/) #### Build Setup -**推荐 node 版本:12-16** +**推荐 node 版本:12+** ``` bash # 配置镜像加速 https://www.ydyno.com/archives/1219.html @@ -34,7 +34,14 @@ npm run build:prod 2、加速node-sass安装 -https://www.ydyno.com/archives/1219.html +https://izlzl.com/archives/1219.html + +3、出现 npm ERR! ModuleNotFoundError: No module named 'distutils' + +``` +需要安装 python,安装 pip 或者 pip3 +然后安装 pip install distutils / pip3 install distutils +``` #### 特别鸣谢 diff --git a/eladmin-web/package.json b/eladmin-web/package.json index 26b0700..b603f94 100644 --- a/eladmin-web/package.json +++ b/eladmin-web/package.json @@ -36,7 +36,7 @@ "@riophae/vue-treeselect": "^0.4.0", "@wangeditor/editor": "^5.1.23", "@wangeditor/editor-for-vue": "^1.0.2", - "axios": "^0.28.0", + "axios": "1.7.4", "clipboard": "2.0.4", "codemirror": "^5.49.2", "core-js": "^2.6.12", @@ -66,7 +66,7 @@ "vuedraggable": "2.20.0", "vuex": "3.1.0", "wangeditor": "^4.7.11", - "webpack": "^4.46.0" + "webpack": "^4.47.0" }, "devDependencies": { "@babel/parser": "^7.7.4", @@ -90,7 +90,7 @@ "eslint": "5.15.3", "eslint-plugin-vue": "5.2.2", "html-webpack-plugin": "3.2.0", - "http-proxy-middleware": "^0.19.1", + "http-proxy-middleware": "3.0.3", "husky": "1.3.1", "lint-staged": "8.1.5", "plop": "2.3.0", @@ -98,11 +98,11 @@ "sass-loader": "10.2.0", "script-ext-html-webpack-plugin": "2.1.3", "script-loader": "0.7.2", - "serve-static": "^1.13.2", + "serve-static": "1.16.2", "svg-sprite-loader": "4.1.3", "svgo": "1.2.0", "tasksfile": "^5.1.1", - "vue-template-compiler": "2.6.14" + "vue-template-compiler": "2.7.15" }, "engines": { "node": ">=8.9", diff --git a/eladmin/eladmin-common/pom.xml b/eladmin/eladmin-common/pom.xml index a8a3fe7..c97dde2 100644 --- a/eladmin/eladmin-common/pom.xml +++ b/eladmin/eladmin-common/pom.xml @@ -1,7 +1,5 @@ - + eladmin me.zhengjie @@ -9,7 +7,7 @@ 4.0.0 - 5.8.21 + 5.8.35 eladmin-common diff --git a/eladmin/eladmin-common/src/main/java/me/zhengjie/config/RedisConfiguration.java b/eladmin/eladmin-common/src/main/java/me/zhengjie/config/RedisConfiguration.java index 370bfc5..cdd47e4 100644 --- a/eladmin/eladmin-common/src/main/java/me/zhengjie/config/RedisConfiguration.java +++ b/eladmin/eladmin-common/src/main/java/me/zhengjie/config/RedisConfiguration.java @@ -15,9 +15,9 @@ */ package me.zhengjie.config; -import com.alibaba.fastjson.JSON; -import com.alibaba.fastjson.parser.ParserConfig; -import com.alibaba.fastjson.serializer.SerializerFeature; +import com.alibaba.fastjson2.JSON; +import com.alibaba.fastjson2.JSONFactory; +import com.alibaba.fastjson2.JSONWriter; import lombok.extern.slf4j.Slf4j; import org.apache.commons.codec.digest.DigestUtils; import org.springframework.cache.Cache; @@ -33,6 +33,7 @@ import org.springframework.data.redis.connection.RedisConnectionFactory; import org.springframework.data.redis.core.RedisTemplate; import org.springframework.data.redis.serializer.RedisSerializationContext; import org.springframework.data.redis.serializer.RedisSerializer; +import org.springframework.data.redis.serializer.SerializationException; import org.springframework.data.redis.serializer.StringRedisSerializer; import java.nio.charset.StandardCharsets; import java.time.Duration; @@ -64,21 +65,13 @@ public class RedisConfiguration { @Bean(name = "redisTemplate") public RedisTemplate redisTemplate(RedisConnectionFactory redisConnectionFactory) { RedisTemplate template = new RedisTemplate<>(); - //序列化 + // 指定 key 和 value 的序列化方案 FastJsonRedisSerializer fastJsonRedisSerializer = new FastJsonRedisSerializer<>(Object.class); // value值的序列化采用fastJsonRedisSerializer template.setValueSerializer(fastJsonRedisSerializer); template.setHashValueSerializer(fastJsonRedisSerializer); - // fastjson 升级到 1.2.83 后需要指定序列化白名单 - ParserConfig.getGlobalInstance().addAccept("me.zhengjie.domain"); - // 模块内的实体类 - ParserConfig.getGlobalInstance().addAccept("me.zhengjie.modules.mnt.domain"); - ParserConfig.getGlobalInstance().addAccept("me.zhengjie.modules.quartz.domain"); - ParserConfig.getGlobalInstance().addAccept("me.zhengjie.modules.system.domain"); - // 模块内的 Dto - ParserConfig.getGlobalInstance().addAccept("me.zhengjie.modules.security.service.dto"); - // 分页返回数据 - ParserConfig.getGlobalInstance().addAccept("me.zhengjie.utils.PageResult"); + // 设置fastJson的序列化白名单 + JSONFactory.getDefaultObjectReaderProvider().addAutoTypeAccept("me.zhengjie"); // key的序列化采用StringRedisSerializer template.setKeySerializer(new StringRedisSerializer()); template.setHashKeySerializer(new StringRedisSerializer()); @@ -127,7 +120,7 @@ public class RedisConfiguration { } @Bean - @SuppressWarnings("all") + @SuppressWarnings({"unchecked","all"}) public CacheErrorHandler errorHandler() { return new SimpleCacheErrorHandler() { @Override @@ -169,15 +162,17 @@ public class RedisConfiguration { } @Override - public byte[] serialize(T t) { + public byte[] serialize(T t) throws SerializationException + { if (t == null) { return new byte[0]; } - return JSON.toJSONString(t, SerializerFeature.WriteClassName).getBytes(StandardCharsets.UTF_8); + return JSON.toJSONString(t, JSONWriter.Feature.WriteClassName).getBytes(StandardCharsets.UTF_8); } @Override - public T deserialize(byte[] bytes) { + public T deserialize(byte[] bytes) throws SerializationException + { if (bytes == null || bytes.length == 0) { return null; } diff --git a/eladmin/eladmin-common/src/main/java/me/zhengjie/config/RemoveDruidAdConfig.java b/eladmin/eladmin-common/src/main/java/me/zhengjie/config/RemoveDruidAdConfig.java index f432de4..2bba6b7 100644 --- a/eladmin/eladmin-common/src/main/java/me/zhengjie/config/RemoveDruidAdConfig.java +++ b/eladmin/eladmin-common/src/main/java/me/zhengjie/config/RemoveDruidAdConfig.java @@ -9,7 +9,6 @@ import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplicat import org.springframework.boot.web.servlet.FilterRegistrationBean; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; - import javax.servlet.*; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; @@ -21,7 +20,7 @@ import java.io.IOException; * @date 2025-01-11 **/ @Configuration -@SuppressWarnings("all") +@SuppressWarnings({"unchecked","all"}) @ConditionalOnWebApplication @AutoConfigureAfter(DruidDataSourceAutoConfigure.class) @ConditionalOnProperty(name = "spring.datasource.druid.stat-view-servlet.enabled", diff --git a/eladmin/eladmin-common/src/main/java/me/zhengjie/config/webConfig/ConfigurerAdapter.java b/eladmin/eladmin-common/src/main/java/me/zhengjie/config/webConfig/ConfigurerAdapter.java index 80ef131..82a7e44 100644 --- a/eladmin/eladmin-common/src/main/java/me/zhengjie/config/webConfig/ConfigurerAdapter.java +++ b/eladmin/eladmin-common/src/main/java/me/zhengjie/config/webConfig/ConfigurerAdapter.java @@ -15,9 +15,9 @@ */ package me.zhengjie.config.webConfig; -import com.alibaba.fastjson.serializer.SerializerFeature; -import com.alibaba.fastjson.support.config.FastJsonConfig; -import com.alibaba.fastjson.support.spring.FastJsonHttpMessageConverter; +import com.alibaba.fastjson2.JSONWriter; +import com.alibaba.fastjson2.support.config.FastJsonConfig; +import com.alibaba.fastjson2.support.spring.http.converter.FastJsonHttpMessageConverter; import me.zhengjie.config.properties.FileProperties; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; @@ -83,9 +83,10 @@ public class ConfigurerAdapter implements WebMvcConfigurer { supportMediaTypeList.add(MediaType.APPLICATION_JSON); FastJsonConfig config = new FastJsonConfig(); config.setDateFormat("yyyy-MM-dd HH:mm:ss"); - config.setSerializerFeatures( - SerializerFeature.WriteEnumUsingToString, - SerializerFeature.DisableCircularReferenceDetect + // 开启引用检测,枚举支持 + config.setWriterFeatures( + JSONWriter.Feature.WriteEnumUsingToString, + JSONWriter.Feature.ReferenceDetection ); fastJsonConverter.setFastJsonConfig(config); fastJsonConverter.setSupportedMediaTypes(supportMediaTypeList); diff --git a/eladmin/eladmin-common/src/main/java/me/zhengjie/config/webConfig/SwaggerConfig.java b/eladmin/eladmin-common/src/main/java/me/zhengjie/config/webConfig/SwaggerConfig.java index a664cd6..d5c1282 100644 --- a/eladmin/eladmin-common/src/main/java/me/zhengjie/config/webConfig/SwaggerConfig.java +++ b/eladmin/eladmin-common/src/main/java/me/zhengjie/config/webConfig/SwaggerConfig.java @@ -130,7 +130,7 @@ public class SwaggerConfig { * @return / */ @Bean - @SuppressWarnings({"all"}) + @SuppressWarnings({"unchecked","all"}) public static BeanPostProcessor springfoxHandlerProviderBeanPostProcessor() { return new BeanPostProcessor() { diff --git a/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/RedisUtils.java b/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/RedisUtils.java index 04fd53c..02a9971 100644 --- a/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/RedisUtils.java +++ b/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/RedisUtils.java @@ -33,7 +33,7 @@ import java.util.stream.Collectors; * @author / */ @Component -@SuppressWarnings({"all"}) +@SuppressWarnings({"unchecked","all"}) public class RedisUtils { private static final Logger log = LoggerFactory.getLogger(RedisUtils.class); diff --git a/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/SecurityUtils.java b/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/SecurityUtils.java index 2b6b498..c4c6a6c 100644 --- a/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/SecurityUtils.java +++ b/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/SecurityUtils.java @@ -18,9 +18,9 @@ package me.zhengjie.utils; import cn.hutool.core.collection.CollUtil; import cn.hutool.jwt.JWT; import cn.hutool.jwt.JWTUtil; -import com.alibaba.fastjson.JSON; -import com.alibaba.fastjson.JSONArray; -import com.alibaba.fastjson.JSONObject; +import com.alibaba.fastjson2.JSON; +import com.alibaba.fastjson2.JSONArray; +import com.alibaba.fastjson2.JSONObject; import lombok.extern.slf4j.Slf4j; import me.zhengjie.utils.enums.DataScopeEnum; import org.springframework.beans.factory.annotation.Value; diff --git a/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/SpringBeanHolder.java b/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/SpringBeanHolder.java index ace0074..57ad9fa 100644 --- a/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/SpringBeanHolder.java +++ b/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/SpringBeanHolder.java @@ -31,7 +31,7 @@ import java.util.List; * @date 2019-01-07 */ @Slf4j -@SuppressWarnings("all") +@SuppressWarnings({"unchecked","all"}) public class SpringBeanHolder implements ApplicationContextAware, DisposableBean { private static ApplicationContext applicationContext = null; diff --git a/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/StringUtils.java b/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/StringUtils.java index cc4b496..bbaea65 100644 --- a/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/StringUtils.java +++ b/eladmin/eladmin-common/src/main/java/me/zhengjie/utils/StringUtils.java @@ -232,7 +232,7 @@ public class StringUtils extends org.apache.commons.lang3.StringUtils { } } - @SuppressWarnings({"all"}) + @SuppressWarnings({"unchecked","all"}) public static List getAllFields(Class clazz, List fields) { if (clazz != null) { fields.addAll(Arrays.asList(clazz.getDeclaredFields())); diff --git a/eladmin/eladmin-generator/pom.xml b/eladmin/eladmin-generator/pom.xml index 0ab5121..6b942d5 100644 --- a/eladmin/eladmin-generator/pom.xml +++ b/eladmin/eladmin-generator/pom.xml @@ -1,7 +1,5 @@ - + eladmin me.zhengjie diff --git a/eladmin/eladmin-logging/pom.xml b/eladmin/eladmin-logging/pom.xml index 4903c27..6cb3e91 100644 --- a/eladmin/eladmin-logging/pom.xml +++ b/eladmin/eladmin-logging/pom.xml @@ -1,7 +1,5 @@ - + eladmin me.zhengjie diff --git a/eladmin/eladmin-logging/src/main/java/me/zhengjie/domain/SysLog.java b/eladmin/eladmin-logging/src/main/java/me/zhengjie/domain/SysLog.java index a749ff1..571af93 100644 --- a/eladmin/eladmin-logging/src/main/java/me/zhengjie/domain/SysLog.java +++ b/eladmin/eladmin-logging/src/main/java/me/zhengjie/domain/SysLog.java @@ -15,7 +15,7 @@ */ package me.zhengjie.domain; -import com.alibaba.fastjson.annotation.JSONField; +import com.alibaba.fastjson2.annotation.JSONField; import com.baomidou.mybatisplus.annotation.*; import com.fasterxml.jackson.annotation.JsonFormat; import io.swagger.annotations.ApiModelProperty; diff --git a/eladmin/eladmin-logging/src/main/java/me/zhengjie/service/impl/SysLogServiceImpl.java b/eladmin/eladmin-logging/src/main/java/me/zhengjie/service/impl/SysLogServiceImpl.java index 1b0d87b..69448d7 100644 --- a/eladmin/eladmin-logging/src/main/java/me/zhengjie/service/impl/SysLogServiceImpl.java +++ b/eladmin/eladmin-logging/src/main/java/me/zhengjie/service/impl/SysLogServiceImpl.java @@ -16,8 +16,8 @@ package me.zhengjie.service.impl; import cn.hutool.core.lang.Dict; -import com.alibaba.fastjson.JSON; -import com.alibaba.fastjson.JSONObject; +import com.alibaba.fastjson2.JSON; +import com.alibaba.fastjson2.JSONObject; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import lombok.RequiredArgsConstructor; diff --git a/eladmin/eladmin-system/pom.xml b/eladmin/eladmin-system/pom.xml index 8c20b01..451aae0 100644 --- a/eladmin/eladmin-system/pom.xml +++ b/eladmin/eladmin-system/pom.xml @@ -1,7 +1,5 @@ - + eladmin me.zhengjie @@ -78,7 +76,7 @@ com.github.oshi oshi-core - 6.1.4 + 6.6.5 diff --git a/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/maint/service/websocket/WebSocketServer.java b/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/maint/service/websocket/WebSocketServer.java index 7130a29..5f46415 100644 --- a/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/maint/service/websocket/WebSocketServer.java +++ b/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/maint/service/websocket/WebSocketServer.java @@ -15,7 +15,7 @@ */ package me.zhengjie.modules.maint.service.websocket; -import com.alibaba.fastjson.JSON; +import com.alibaba.fastjson2.JSON; import lombok.extern.slf4j.Slf4j; import org.springframework.stereotype.Component; import javax.websocket.*; @@ -37,7 +37,7 @@ public class WebSocketServer { /** * concurrent包的线程安全Set,用来存放每个客户端对应的MyWebSocket对象。 */ - private static final CopyOnWriteArraySet webSocketSet = new CopyOnWriteArraySet(); + private static final CopyOnWriteArraySet webSocketSet = new CopyOnWriteArraySet<>(); /** * 与某个客户端的连接会话,需要通过它来给客户端发送数据 diff --git a/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/quartz/utils/QuartzRunnable.java b/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/quartz/utils/QuartzRunnable.java index a8f708d..0b4751a 100644 --- a/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/quartz/utils/QuartzRunnable.java +++ b/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/quartz/utils/QuartzRunnable.java @@ -45,7 +45,7 @@ public class QuartzRunnable implements Callable { } @Override - @SuppressWarnings("all") + @SuppressWarnings({"unchecked","all"}) public Object call() throws Exception { ReflectionUtils.makeAccessible(method); if (StringUtils.isNotBlank(params)) { diff --git a/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/security/service/dto/JwtUserDto.java b/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/security/service/dto/JwtUserDto.java index d687774..588770e 100644 --- a/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/security/service/dto/JwtUserDto.java +++ b/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/security/service/dto/JwtUserDto.java @@ -15,7 +15,7 @@ */ package me.zhengjie.modules.security.service.dto; -import com.alibaba.fastjson.annotation.JSONField; +import com.alibaba.fastjson2.annotation.JSONField; import io.swagger.annotations.ApiModelProperty; import lombok.AllArgsConstructor; import lombok.Getter; diff --git a/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/system/domain/Dept.java b/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/system/domain/Dept.java index 68e5f1d..5196725 100644 --- a/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/system/domain/Dept.java +++ b/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/system/domain/Dept.java @@ -15,7 +15,7 @@ */ package me.zhengjie.modules.system.domain; -import com.alibaba.fastjson.annotation.JSONField; +import com.alibaba.fastjson2.annotation.JSONField; import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableId; @@ -89,14 +89,18 @@ public class Dept extends BaseEntity implements Serializable { return Objects.hash(id, name); } + @ApiModelProperty(value = "是否有子节点") public Boolean getHasChildren() { return subCount > 0; } + + @ApiModelProperty(value = "是否为叶子") public Boolean getLeaf() { return subCount <= 0; } + @ApiModelProperty(value = "标签名称") public String getLabel() { return name; } diff --git a/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/system/domain/Menu.java b/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/system/domain/Menu.java index f97956f..f425755 100644 --- a/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/system/domain/Menu.java +++ b/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/system/domain/Menu.java @@ -15,7 +15,7 @@ */ package me.zhengjie.modules.system.domain; -import com.alibaba.fastjson.annotation.JSONField; +import com.alibaba.fastjson2.annotation.JSONField; import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableId; @@ -109,14 +109,17 @@ public class Menu extends BaseEntity implements Serializable { return Objects.hash(id); } + @ApiModelProperty(value = "是否有子节点") public Boolean getHasChildren() { return subCount > 0; } + @ApiModelProperty(value = "是否为叶子") public Boolean getLeaf() { return subCount <= 0; } + @ApiModelProperty(value = "标签名称") public String getLabel() { return title; } diff --git a/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/system/domain/User.java b/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/system/domain/User.java index 12f87da..2ddce17 100644 --- a/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/system/domain/User.java +++ b/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/system/domain/User.java @@ -15,7 +15,7 @@ */ package me.zhengjie.modules.system.domain; -import com.alibaba.fastjson.annotation.JSONField; +import com.alibaba.fastjson2.annotation.JSONField; import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableId; diff --git a/eladmin/eladmin-tools/pom.xml b/eladmin/eladmin-tools/pom.xml index 789f134..ae15c55 100644 --- a/eladmin/eladmin-tools/pom.xml +++ b/eladmin/eladmin-tools/pom.xml @@ -1,7 +1,5 @@ - + eladmin me.zhengjie diff --git a/eladmin/eladmin-tools/src/main/java/me/zhengjie/service/impl/QiniuContentServiceImpl.java b/eladmin/eladmin-tools/src/main/java/me/zhengjie/service/impl/QiniuContentServiceImpl.java index e4a37e8..f240e36 100644 --- a/eladmin/eladmin-tools/src/main/java/me/zhengjie/service/impl/QiniuContentServiceImpl.java +++ b/eladmin/eladmin-tools/src/main/java/me/zhengjie/service/impl/QiniuContentServiceImpl.java @@ -15,7 +15,7 @@ */ package me.zhengjie.service.impl; -import com.alibaba.fastjson.JSON; +import com.alibaba.fastjson2.JSON; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.qiniu.common.QiniuException; @@ -133,7 +133,7 @@ public class QiniuContentServiceImpl extends ServiceImpl - + 4.0.0 me.zhengjie @@ -27,13 +25,11 @@ - 2.17.0 1.2.9 UTF-8 UTF-8 1.8 - 2.9.2 - 1.2.83 + 2.0.54 1.2.19 2.11.1 @@ -43,6 +39,13 @@ org.springframework.boot spring-boot-starter-web + + + + org.springframework.boot + spring-boot-starter-json + + @@ -116,11 +119,24 @@ - com.github.xiaoymin knife4j-spring-boot-starter 3.0.3 + + + + io.swagger + swagger-annotations + + + + + + + io.swagger + swagger-annotations + 1.5.22 @@ -138,11 +154,11 @@ ${druid.version} - + net.dreamlu mica-ip2region - 2.7.12 + 2.7.18.9 @@ -167,12 +183,12 @@ org.apache.poi poi - 5.2.0 + 5.4.0 org.apache.poi poi-ooxml - 5.2.0 + 5.4.0 xerces @@ -180,11 +196,17 @@ 2.12.2 - + - com.alibaba - fastjson - ${fastjson.version} + com.alibaba.fastjson2 + fastjson2 + ${fastjson2.version} + + + + com.alibaba.fastjson2 + fastjson2-extension-spring5 + ${fastjson2.version} @@ -197,7 +219,7 @@ org.apache.commons commons-text - 1.10.0 + 1.13.0