chore: continew-starter 2.5.2 => 2.6.0

修复更新加密失效
修复特殊校验异常不打印堆栈
其他优化

Closes #84
This commit is contained in:
2024-09-07 19:00:06 +08:00
parent 098571ffb2
commit c87317d199
46 changed files with 67 additions and 63 deletions

View File

@@ -13,7 +13,7 @@
<img src="https://sonarcloud.io/api/project_badges/measure?project=Charles7c_continew-admin&metric=alert_status" alt="Sonar Status" />
</a>
<a href="https://github.com/continew-org/continew-starter" target="_blank">
<img src="https://img.shields.io/badge/ContiNew Starter-2.5.2-%236CB52D.svg" alt="ContiNew Starter" />
<img src="https://img.shields.io/badge/ContiNew Starter-2.6.0-%236CB52D.svg" alt="ContiNew Starter" />
</a>
<a href="https://spring.io/projects/spring-boot" target="_blank">
<img src="https://img.shields.io/badge/Spring Boot-3.2.7-%236CB52D.svg?logo=Spring-Boot" alt="Spring Boot" />
@@ -210,16 +210,16 @@ public class DeptController extends BaseController<DeptService, DeptResp, DeptDe
## 核心技术栈
| 名称 | 版本 | 简介 |
| :----------------------------------------------------------- |:-------------| :----------------------------------------------------------- |
| 名称 | 版本 | 简介 |
| :----------------------------------------------------------- | :----------- | :----------------------------------------------------------- |
| <a href="https://cn.vuejs.org/" target="_blank">Vue</a> | 3.4.21 | 渐进式 JavaScript 框架,易学易用,性能出色,适用场景丰富的 Web 前端框架。 |
| <a href="https://arco.design/vue/docs/start" target="_blank">Arco Design</a> | 2.55.0 | 字节跳动推出的前端 UI 框架,年轻化的色彩和组件设计。 |
| <a href="https://arco.design/vue/docs/start" target="_blank">Arco Design</a> | 2.56.0 | 字节跳动推出的前端 UI 框架,年轻化的色彩和组件设计。 |
| <a href="https://www.typescriptlang.org/zh/" target="_blank">TypeScript</a> | 5.0.4 | TypeScript 是微软开发的一个开源的编程语言,通过在 JavaScript 的基础上添加静态类型定义构建而成。 |
| <a href="https://cn.vitejs.dev/" target="_blank">Vite</a> | 5.1.5 | 下一代的前端工具链,为开发提供极速响应。 |
| [ContiNew Starter](https://github.com/continew-org/continew-starter) | 2.5.2 | ContiNew Starter 包含了一系列经过企业实践优化的依赖包(如 MyBatis-Plus、SaToken可轻松集成到应用中为开发人员减少手动引入依赖及配置的麻烦为 Spring Boot Web 项目的灵活快速构建提供支持。 |
| [ContiNew Starter](https://github.com/continew-org/continew-starter) | 2.6.0 | ContiNew Starter 包含了一系列经过企业实践优化的依赖包(如 MyBatis-Plus、SaToken可轻松集成到应用中为开发人员减少手动引入依赖及配置的麻烦为 Spring Boot Web 项目的灵活快速构建提供支持。 |
| <a href="https://spring.io/projects/spring-boot" target="_blank">Spring Boot</a> | 3.2.7 | 简化 Spring 应用的初始搭建和开发过程基于“约定优于配置”的理念使开发人员不再需要定义样板化的配置。Spring Boot 3.0 开始,要求 Java 17 作为最低版本) |
| <a href="https://undertow.io/" target="_blank">Undertow</a> | 2.3.13.Final | 采用 Java 开发的灵活的高性能 Web 服务器,提供包括阻塞和基于 NIO 的非堵塞机制。 |
| <a href="https://sa-token.dev33.cn/" target="_blank">Sa-Token + JWT</a> | 1.38.0 | 轻量级 Java 权限认证框架,让鉴权变得简单、优雅。 |
| <a href="https://sa-token.dev33.cn/" target="_blank">Sa-Token + JWT</a> | 1.39.0 | 轻量级 Java 权限认证框架,让鉴权变得简单、优雅。 |
| <a href="https://baomidou.com/" target="_blank">MyBatis Plus</a> | 3.5.7 | MyBatis 的增强工具,在 MyBatis 的基础上只做增强不做改变,简化开发、提高效率。 |
| <a href="https://www.kancloud.cn/tracy5546/dynamic-datasource/2264611" target="_blank">dynamic-datasource-spring-boot-starter</a> | 4.3.1 | 基于 Spring Boot 的快速集成多数据源的启动器。 |
| Hikari | 5.0.1 | JDBC 连接池,号称 “史上最快连接池”SpringBoot 在 2.0 之后,采用的默认数据库连接池就是 Hikari。 |
@@ -228,18 +228,20 @@ public class DeptController extends BaseController<DeptService, DeptResp, DeptDe
| <a href="https://github.com/p6spy/p6spy" target="_blank">P6Spy</a> | 3.9.1 | SQL 性能分析组件。 |
| <a href="https://github.com/liquibase/liquibase" target="_blank">Liquibase</a> | 4.24.0 | 用于管理数据库版本,跟踪、管理和应用数据库变化。 |
| [JetCache](https://github.com/alibaba/jetcache/blob/master/docs/CN/Readme.md) | 2.7.6 | 一个基于 Java 的缓存系统封装,提供统一的 API 和注解来简化缓存的使用。提供了比 SpringCache 更加强大的注解,可以原生的支持 TTL、两级缓存、分布式自动刷新还提供了 Cache 接口用于手工缓存操作。 |
| <a href="https://github.com/redisson/redisson/wiki/Redisson%E9%A1%B9%E7%9B%AE%E4%BB%8B%E7%BB%8D" target="_blank">Redisson</a> | 3.32.0 | 不仅仅是一个 Redis Java 客户端Redisson 充分的利用了 Redis 键值数据库提供的一系列优势,为使用者提供了一系列具有分布式特性的常用工具:分布式锁、限流器等。 |
| <a href="https://github.com/redisson/redisson/wiki/Redisson%E9%A1%B9%E7%9B%AE%E4%BB%8B%E7%BB%8D" target="_blank">Redisson</a> | 3.35.0 | 不仅仅是一个 Redis Java 客户端Redisson 充分的利用了 Redis 键值数据库提供的一系列优势,为使用者提供了一系列具有分布式特性的常用工具:分布式锁、限流器等。 |
| <a href="https://redis.io/" target="_blank">Redis</a> | 7.2.3 | 高性能的 key-value 数据库。 |
| [Snail Job](https://snailjob.opensnail.com/) | 1.1.0 | 灵活,可靠和快速的分布式任务重试和分布式任务调度平台。 |
| [X File Storage](https://x-file-storage.xuyanwu.cn/#/) | 2.2.0 | 一行代码将文件存储到本地、FTP、SFTP、WebDAV、阿里云 OSS、华为云 OBS...等其它兼容 S3 协议的存储平台。 |
| <a href="https://sms4j.com/" target="_blank">SMS4J</a> | 3.2.1 | 短信聚合框架,轻松集成多家短信服务,解决接入多个短信 SDK 的繁琐流程。 |
| [Snail Job](https://snailjob.opensnail.com/) | 1.1.2 | 灵活,可靠和快速的分布式任务重试和分布式任务调度平台。 |
| [X File Storage](https://x-file-storage.xuyanwu.cn/#/) | 2.2.1 | 一行代码将文件存储到本地、FTP、SFTP、WebDAV、阿里云 OSS、华为云 OBS...等其它兼容 S3 协议的存储平台。 |
| <a href="https://sms4j.com/" target="_blank">SMS4J</a> | 3.3.2 | 短信聚合框架,轻松集成多家短信服务,解决接入多个短信 SDK 的繁琐流程。 |
| <a href="https://justauth.cn/" target="_blank">Just Auth</a> | 1.16.6 | 开箱即用的整合第三方登录的开源组件,脱离繁琐的第三方登录 SDK让登录变得 So easy |
| <a href="https://easyexcel.opensource.alibaba.com/" target="_blank">Easy Excel</a> | 4.0.1 | 一个基于 Java 的、快速、简洁、解决大文件内存溢出的 Excel 处理工具。 |
| [AJ-Captcha](https://ajcaptcha.beliefteam.cn/captcha-doc/) | 1.3.0 | Java 行为验证码包含滑动拼图、文字点选两种方式UI支持弹出和嵌入两种方式。 |
| Easy Captcha | 1.6.2 | Java 图形验证码,支持 gif、中文、算术等类型可用于 Java Web、JavaSE 等项目。 |
| [Crane4j](https://createsequence.gitee.io/crane4j-doc/#/) | 2.9.0 | 一个基于注解的,用于完成一切 “根据 A 的 key 值拿到 B再把 B 的属性映射到 A” 这类需求的字段填充框架。 |
| [CosID](https://cosid.ahoo.me/guide/getting-started.html) | 2.9.6 | 旨在提供通用、灵活、高性能的分布式 ID 生成器。 |
| [Graceful Response](https://doc.feiniaojin.com/graceful-response/home.html) | 5.0.0-boot3 | 一个Spring Boot技术栈下的优雅响应处理组件可以帮助开发者完成响应数据封装、异常处理、错误码填充等过程提高开发效率提高代码质量。 |
| <a href="https://doc.xiaominfo.com/" target="_blank">Knife4j</a> | 4.5.0 | 前身是 swagger-bootstrap-ui集 Swagger2 和 OpenAPI3 为一体的增强解决方案。 |
| <a href="https://www.hutool.cn/" target="_blank">Hutool</a> | 5.8.29 | 小而全的 Java 工具类库,通过静态方法封装,降低相关 API 的学习成本,提高工作效率,使 Java 拥有函数式语言般的优雅,让 Java 语言也可以“甜甜的”。 |
| <a href="https://www.hutool.cn/" target="_blank">Hutool</a> | 5.8.32 | 小而全的 Java 工具类库,通过静态方法封装,降低相关 API 的学习成本,提高工作效率,使 Java 拥有函数式语言般的优雅,让 Java 语言也可以“甜甜的”。 |
| <a href="https://projectlombok.org/" target="_blank">Lombok</a> | 1.18.32 | 在 Java 开发过程中用注解的方式,简化了 JavaBean 的编写,避免了冗余和样板式代码,让编写的类更加简洁。 |
## 快速开始

View File

@@ -67,7 +67,7 @@
<!-- ContiNew Starter 数据访问模块 - MyBatis Plus -->
<dependency>
<groupId>top.continew</groupId>
<artifactId>continew-starter-data-mybatis-plus</artifactId>
<artifactId>continew-starter-data-mp</artifactId>
</dependency>
<!-- ContiNew Starter 缓存模块 - JetCache -->

View File

@@ -45,7 +45,7 @@ public class GlobalExceptionHandler {
*/
@ExceptionHandler(BusinessException.class)
public R handleBusinessException(BusinessException e, HttpServletRequest request) {
log.error("请求地址 [{}],发生业务异常。", request.getRequestURI(), e);
log.error("[{}] {}", request.getMethod(), request.getRequestURI(), e);
return R.fail(String.valueOf(HttpStatus.INTERNAL_SERVER_ERROR.value()), e.getMessage());
}
@@ -54,7 +54,7 @@ public class GlobalExceptionHandler {
*/
@ExceptionHandler(BadRequestException.class)
public R handleBadRequestException(BadRequestException e, HttpServletRequest request) {
log.error("请求地址 [{}],自定义验证失败。", request.getRequestURI(), e);
log.error("[{}] {}", request.getMethod(), request.getRequestURI(), e);
return R.fail(String.valueOf(HttpStatus.BAD_REQUEST.value()), e.getMessage());
}
@@ -63,6 +63,7 @@ public class GlobalExceptionHandler {
*/
@ExceptionHandler(MultipartException.class)
public R handleRequestTooBigException(MultipartException e, HttpServletRequest request) {
log.error("[{}] {}", request.getMethod(), request.getRequestURI(), e);
String msg = e.getMessage();
R defaultFail = R.fail(String.valueOf(HttpStatus.BAD_REQUEST.value()), msg);
if (CharSequenceUtil.isBlank(msg)) {
@@ -81,7 +82,6 @@ public class GlobalExceptionHandler {
return defaultFail;
}
String errorMsg = "请上传小于 %sKB 的文件".formatted(NumberUtil.parseLong(sizeLimit) / 1024);
log.error("请求地址 [{}],上传文件失败,文件大小超过限制。", request.getRequestURI(), e);
return R.fail(String.valueOf(HttpStatus.BAD_REQUEST.value()), errorMsg);
}
}

View File

@@ -43,7 +43,7 @@ public class GlobalSaTokenExceptionHandler {
*/
@ExceptionHandler(NotLoginException.class)
public R handleNotLoginException(NotLoginException e, HttpServletRequest request) {
log.error("请求地址 [{}],认证失败,无法访问系统资源。", request.getRequestURI(), e);
log.error("[{}] {}", request.getMethod(), request.getRequestURI(), e);
String errorMsg = switch (e.getType()) {
case NotLoginException.KICK_OUT -> "您已被踢下线";
case NotLoginException.BE_REPLACED_MESSAGE -> "您已被顶下线";
@@ -57,7 +57,7 @@ public class GlobalSaTokenExceptionHandler {
*/
@ExceptionHandler(NotPermissionException.class)
public R handleNotPermissionException(NotPermissionException e, HttpServletRequest request) {
log.error("请求地址 [{}],权限码校验失败。", request.getRequestURI(), e);
log.error("[{}] {}", request.getMethod(), request.getRequestURI(), e);
return R.fail(String.valueOf(HttpStatus.FORBIDDEN.value()), "没有访问权限,请联系管理员授权");
}
@@ -66,7 +66,7 @@ public class GlobalSaTokenExceptionHandler {
*/
@ExceptionHandler(NotRoleException.class)
public R handleNotRoleException(NotRoleException e, HttpServletRequest request) {
log.error("请求地址 [{}],角色权限校验失败。", request.getRequestURI(), e);
log.error("[{}] {}", request.getMethod(), request.getRequestURI(), e);
return R.fail(String.valueOf(HttpStatus.FORBIDDEN.value()), "没有访问权限,请联系管理员授权");
}
}

View File

@@ -19,9 +19,9 @@ package top.continew.admin.common.config.mybatis;
import cn.hutool.core.convert.Convert;
import top.continew.admin.common.model.dto.LoginUser;
import top.continew.admin.common.util.helper.LoginHelper;
import top.continew.starter.data.mybatis.plus.datapermission.DataPermissionCurrentUser;
import top.continew.starter.data.mybatis.plus.datapermission.DataPermissionFilter;
import top.continew.starter.data.mybatis.plus.datapermission.DataScope;
import top.continew.starter.data.mp.datapermission.DataPermissionCurrentUser;
import top.continew.starter.data.mp.datapermission.DataPermissionFilter;
import top.continew.starter.data.mp.datapermission.DataScope;
import java.util.stream.Collectors;

View File

@@ -20,8 +20,8 @@ import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import org.apache.ibatis.annotations.Param;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mybatis.plus.datapermission.DataPermission;
import top.continew.starter.data.mp.base.BaseMapper;
import top.continew.starter.data.mp.datapermission.DataPermission;
import java.util.List;

View File

@@ -20,7 +20,7 @@ import com.baomidou.mybatisplus.core.handlers.MetaObjectHandler;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.security.crypto.password.PasswordEncoder;
import top.continew.starter.data.mybatis.plus.datapermission.DataPermissionFilter;
import top.continew.starter.data.mp.datapermission.DataPermissionFilter;
/**
* MyBatis Plus 配置

View File

@@ -14,7 +14,7 @@
<properties>
<!-- SnailJob 服务端 -->
<snail-job.version>1.1.0</snail-job.version>
<snail-job.version>1.1.2</snail-job.version>
</properties>
<dependencies>

View File

@@ -19,7 +19,7 @@ package top.continew.admin.generator.mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import top.continew.admin.generator.model.entity.FieldConfigDO;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
import java.util.List;

View File

@@ -17,7 +17,7 @@
package top.continew.admin.generator.mapper;
import top.continew.admin.generator.model.entity.GenConfigDO;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
/**
* 生成配置 Mapper

View File

@@ -1,6 +1,6 @@
package ${packageName}.${subPackageName};
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
import ${packageName}.model.entity.${classNamePrefix}DO;
/**

View File

@@ -108,7 +108,7 @@
<script setup lang="ts">
import ${classNamePrefix}AddModal from './${classNamePrefix}AddModal.vue'
import ${classNamePrefix}DetailDrawer from './${classNamePrefix}DetailDrawer.vue'
import { type ${classNamePrefix}Resp, type ${classNamePrefix}Query, delete${classNamePrefix}, export${classNamePrefix}, list${classNamePrefix} } from '@/apis/${apiModuleName}/${apiName}'
import { type ${classNamePrefix}Resp, type ${classNamePrefix}Query, delete${classNamePrefix}, export${classNamePrefix}, list${classNamePrefix} } from '@/apis/${apiModuleName}'
import type { TableInstanceColumns } from '@/components/GiTable/type'
import { useDownload, useTable } from '@/hooks'
import { isMobile } from '@/utils'

View File

@@ -17,7 +17,7 @@
package top.continew.admin.system.mapper;
import top.continew.admin.system.model.entity.DeptDO;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
/**
* 部门 Mapper

View File

@@ -18,7 +18,7 @@ package top.continew.admin.system.mapper;
import org.apache.ibatis.annotations.Param;
import top.continew.admin.system.model.entity.DictItemDO;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
import top.continew.starter.extension.crud.model.resp.LabelValueResp;
import java.util.List;

View File

@@ -17,7 +17,7 @@
package top.continew.admin.system.mapper;
import top.continew.admin.system.model.entity.DictDO;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
/**
* 字典 Mapper

View File

@@ -19,7 +19,7 @@ package top.continew.admin.system.mapper;
import org.apache.ibatis.annotations.Select;
import top.continew.admin.system.model.entity.FileDO;
import top.continew.admin.system.model.resp.FileStatisticsResp;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
import java.util.List;

View File

@@ -25,7 +25,7 @@ import top.continew.admin.system.model.resp.DashboardAccessTrendResp;
import top.continew.admin.system.model.resp.DashboardPopularModuleResp;
import top.continew.admin.system.model.resp.DashboardTotalResp;
import top.continew.admin.system.model.resp.log.LogResp;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
import java.util.List;
import java.util.Map;

View File

@@ -18,7 +18,7 @@ package top.continew.admin.system.mapper;
import org.apache.ibatis.annotations.Param;
import top.continew.admin.system.model.entity.MenuDO;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
import java.util.List;
import java.util.Set;

View File

@@ -22,7 +22,7 @@ import com.baomidou.mybatisplus.core.toolkit.Constants;
import org.apache.ibatis.annotations.Param;
import top.continew.admin.system.model.entity.MessageDO;
import top.continew.admin.system.model.resp.MessageResp;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
/**
* 消息 Mapper

View File

@@ -18,7 +18,7 @@ package top.continew.admin.system.mapper;
import org.apache.ibatis.annotations.Param;
import top.continew.admin.system.model.entity.MessageUserDO;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
/**
* 消息和用户 Mapper

View File

@@ -18,7 +18,7 @@ package top.continew.admin.system.mapper;
import top.continew.admin.system.model.entity.NoticeDO;
import top.continew.admin.system.model.resp.DashboardNoticeResp;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
import java.util.List;

View File

@@ -19,7 +19,7 @@ package top.continew.admin.system.mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import top.continew.admin.system.model.entity.OptionDO;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
import java.util.List;

View File

@@ -19,7 +19,7 @@ package top.continew.admin.system.mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import top.continew.admin.system.model.entity.RoleDeptDO;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
import java.util.List;

View File

@@ -17,7 +17,7 @@
package top.continew.admin.system.mapper;
import top.continew.admin.system.model.entity.RoleDO;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
/**
* 角色 Mapper

View File

@@ -17,7 +17,7 @@
package top.continew.admin.system.mapper;
import top.continew.admin.system.model.entity.RoleMenuDO;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
import java.util.List;

View File

@@ -17,7 +17,7 @@
package top.continew.admin.system.mapper;
import top.continew.admin.system.model.entity.StorageDO;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
/**
* 存储 Mapper

View File

@@ -24,7 +24,7 @@ import org.apache.ibatis.annotations.Select;
import top.continew.admin.common.config.mybatis.DataPermissionMapper;
import top.continew.admin.system.model.entity.UserDO;
import top.continew.admin.system.model.resp.UserDetailResp;
import top.continew.starter.data.mybatis.plus.datapermission.DataPermission;
import top.continew.starter.data.mp.datapermission.DataPermission;
import top.continew.starter.security.crypto.annotation.FieldEncrypt;
import java.util.List;

View File

@@ -17,7 +17,7 @@
package top.continew.admin.system.mapper;
import org.apache.ibatis.annotations.Param;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
import top.continew.admin.system.model.entity.UserPasswordHistoryDO;
/**

View File

@@ -19,7 +19,7 @@ package top.continew.admin.system.mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import top.continew.admin.system.model.entity.UserRoleDO;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
import java.util.List;

View File

@@ -18,7 +18,7 @@ package top.continew.admin.system.mapper;
import org.apache.ibatis.annotations.Param;
import top.continew.admin.system.model.entity.UserSocialDO;
import top.continew.starter.data.mybatis.plus.base.BaseMapper;
import top.continew.starter.data.mp.base.BaseMapper;
/**
* 用户社会化关联 Mapper

View File

@@ -20,7 +20,7 @@ import top.continew.admin.system.model.entity.DeptDO;
import top.continew.admin.system.model.query.DeptQuery;
import top.continew.admin.system.model.req.DeptReq;
import top.continew.admin.system.model.resp.DeptResp;
import top.continew.starter.data.mybatis.plus.service.IService;
import top.continew.starter.data.mp.service.IService;
import top.continew.starter.extension.crud.service.BaseService;
import java.util.List;

View File

@@ -20,7 +20,7 @@ import top.continew.admin.system.model.entity.DictItemDO;
import top.continew.admin.system.model.query.DictItemQuery;
import top.continew.admin.system.model.req.DictItemReq;
import top.continew.admin.system.model.resp.DictItemResp;
import top.continew.starter.data.mybatis.plus.service.IService;
import top.continew.starter.data.mp.service.IService;
import top.continew.starter.extension.crud.model.resp.LabelValueResp;
import top.continew.starter.extension.crud.service.BaseService;

View File

@@ -20,7 +20,7 @@ import top.continew.admin.system.model.entity.DictDO;
import top.continew.admin.system.model.query.DictQuery;
import top.continew.admin.system.model.req.DictReq;
import top.continew.admin.system.model.resp.DictResp;
import top.continew.starter.data.mybatis.plus.service.IService;
import top.continew.starter.data.mp.service.IService;
import top.continew.starter.extension.crud.model.resp.LabelValueResp;
import top.continew.starter.extension.crud.service.BaseService;

View File

@@ -23,7 +23,7 @@ import top.continew.admin.system.model.query.FileQuery;
import top.continew.admin.system.model.req.FileReq;
import top.continew.admin.system.model.resp.FileResp;
import top.continew.admin.system.model.resp.FileStatisticsResp;
import top.continew.starter.data.mybatis.plus.service.IService;
import top.continew.starter.data.mp.service.IService;
import top.continew.starter.extension.crud.service.BaseService;
import java.util.List;

View File

@@ -21,7 +21,7 @@ import top.continew.admin.system.model.query.MenuQuery;
import top.continew.admin.system.model.req.MenuReq;
import top.continew.admin.system.model.resp.MenuResp;
import top.continew.starter.extension.crud.service.BaseService;
import top.continew.starter.data.mybatis.plus.service.IService;
import top.continew.starter.data.mp.service.IService;
import java.util.List;
import java.util.Set;

View File

@@ -23,7 +23,7 @@ import top.continew.admin.system.model.resp.NoticeDetailResp;
import top.continew.admin.system.model.resp.NoticeResp;
import top.continew.admin.system.model.resp.DashboardNoticeResp;
import top.continew.starter.extension.crud.service.BaseService;
import top.continew.starter.data.mybatis.plus.service.IService;
import top.continew.starter.data.mp.service.IService;
import java.util.List;

View File

@@ -22,7 +22,7 @@ import top.continew.admin.system.model.query.RoleQuery;
import top.continew.admin.system.model.req.RoleReq;
import top.continew.admin.system.model.resp.RoleDetailResp;
import top.continew.admin.system.model.resp.RoleResp;
import top.continew.starter.data.mybatis.plus.service.IService;
import top.continew.starter.data.mp.service.IService;
import top.continew.starter.extension.crud.service.BaseService;
import java.util.List;

View File

@@ -20,7 +20,7 @@ import top.continew.admin.system.model.entity.StorageDO;
import top.continew.admin.system.model.query.StorageQuery;
import top.continew.admin.system.model.req.StorageReq;
import top.continew.admin.system.model.resp.StorageResp;
import top.continew.starter.data.mybatis.plus.service.IService;
import top.continew.starter.data.mp.service.IService;
import top.continew.starter.extension.crud.service.BaseService;
/**

View File

@@ -25,7 +25,7 @@ import top.continew.admin.system.model.resp.UserDetailResp;
import top.continew.admin.system.model.resp.UserImportParseResp;
import top.continew.admin.system.model.resp.UserImportResp;
import top.continew.admin.system.model.resp.UserResp;
import top.continew.starter.data.mybatis.plus.service.IService;
import top.continew.starter.data.mp.service.IService;
import top.continew.starter.extension.crud.service.BaseService;
import java.io.IOException;

View File

@@ -58,7 +58,7 @@ public class DeptServiceImpl extends BaseServiceImpl<DeptMapper, DeptDO, DeptRes
public List<DeptDO> listChildren(Long id) {
DatabaseType databaseType = MetaUtils.getDatabaseTypeOrDefault(SpringUtil
.getBean(DynamicRoutingDataSource.class), DatabaseType.MYSQL);
return baseMapper.lambdaQuery().apply(databaseType.findInSet(), id, "ancestors").list();
return baseMapper.lambdaQuery().apply(databaseType.findInSet(id, "ancestors")).list();
}
@Override
@@ -187,7 +187,7 @@ public class DeptServiceImpl extends BaseServiceImpl<DeptMapper, DeptDO, DeptRes
DatabaseType databaseType = MetaUtils.getDatabaseTypeOrDefault(SpringUtil
.getBean(DynamicRoutingDataSource.class), DatabaseType.MYSQL);
return ids.stream()
.mapToLong(id -> baseMapper.lambdaQuery().apply(databaseType.findInSet(), id, "ancestors").count())
.mapToLong(id -> baseMapper.lambdaQuery().apply(databaseType.findInSet(id, "ancestors")).count())
.sum();
}

View File

@@ -33,7 +33,7 @@ import top.continew.admin.system.model.resp.MessageResp;
import top.continew.admin.system.service.MessageService;
import top.continew.admin.system.service.MessageUserService;
import top.continew.starter.core.util.validate.CheckUtils;
import top.continew.starter.data.mybatis.plus.util.QueryWrapperHelper;
import top.continew.starter.data.mp.util.QueryWrapperHelper;
import top.continew.starter.extension.crud.model.query.PageQuery;
import top.continew.starter.extension.crud.model.resp.PageResp;

View File

@@ -38,7 +38,7 @@ import top.continew.starter.cache.redisson.util.RedisUtils;
import top.continew.starter.core.constant.StringConstants;
import top.continew.starter.core.util.validate.CheckUtils;
import top.continew.starter.core.util.validate.ValidationUtils;
import top.continew.starter.data.mybatis.plus.util.QueryWrapperHelper;
import top.continew.starter.data.mp.util.QueryWrapperHelper;
import java.util.List;
import java.util.Map;

View File

@@ -110,7 +110,7 @@ public class LogDaoLocalImpl implements LogDao {
private void setResponse(LogDO logDO, LogResponse logResponse) {
Map<String, String> responseHeaders = logResponse.getHeaders();
logDO.setResponseHeaders(JSONUtil.toJsonStr(responseHeaders));
logDO.setTraceId(responseHeaders.get(traceProperties.getHeaderName()));
logDO.setTraceId(responseHeaders.get(traceProperties.getTraceIdName()));
String responseBody = logResponse.getBody();
logDO.setResponseBody(responseBody);
// 状态

View File

@@ -5,5 +5,5 @@
\____|\___/ |_| |_| \__||_||_| \_| \___| \_/\_/ /_/ \_\\__,_||_| |_| |_||_||_| |_|
:: ${project.name} :: v${project.version}
:: ContiNew Starter :: v2.5.2
:: ContiNew Starter :: v2.6.0
:: Spring Boot :: v${spring-boot.version}

View File

@@ -53,6 +53,8 @@ continew-starter.web:
response:
# 是否开启国际化默认false
i18n: false
# 自定义失败 HTTP 状态码默认200建议业务和通信状态码区分
default-http-status-code-on-error: 200
# 自定义成功响应码默认0
default-success-code: 0
# 自定义成功提示默认ok

View File

@@ -13,7 +13,7 @@
<parent>
<groupId>top.continew</groupId>
<artifactId>continew-starter</artifactId>
<version>2.5.2</version>
<version>2.6.0</version>
</parent>
<groupId>top.continew</groupId>