chore: 调整部分类的所在包

This commit is contained in:
Charles7c 2024-01-20 12:13:09 +08:00
parent 2fa8c254fc
commit 6efe1ad6f4
20 changed files with 32 additions and 41 deletions

View File

@ -17,24 +17,12 @@
<dependency> <dependency>
<groupId>org.dromara.sms4j</groupId> <groupId>org.dromara.sms4j</groupId>
<artifactId>sms4j-spring-boot-starter</artifactId> <artifactId>sms4j-spring-boot-starter</artifactId>
<exclusions>
<exclusion>
<groupId>cn.hutool</groupId>
<artifactId>hutool-core</artifactId>
</exclusion>
</exclusions>
</dependency> </dependency>
<!-- X File Storage一行代码将文件存储到本地、FTP、SFTP、WebDAV、阿里云 OSS、华为云 OBS...等其它兼容 S3 协议的存储平台) --> <!-- X File Storage一行代码将文件存储到本地、FTP、SFTP、WebDAV、阿里云 OSS、华为云 OBS...等其它兼容 S3 协议的存储平台) -->
<dependency> <dependency>
<groupId>org.dromara.x-file-storage</groupId> <groupId>org.dromara.x-file-storage</groupId>
<artifactId>x-file-storage-spring</artifactId> <artifactId>x-file-storage-spring</artifactId>
<exclusions>
<exclusion>
<groupId>cn.hutool</groupId>
<artifactId>hutool-core</artifactId>
</exclusion>
</exclusions>
</dependency> </dependency>
<!-- Amazon S3Amazon Simple Storage Service亚马逊简单存储服务通用存储协议 S3兼容主流云厂商对象存储 --> <!-- Amazon S3Amazon Simple Storage Service亚马逊简单存储服务通用存储协议 S3兼容主流云厂商对象存储 -->
<dependency> <dependency>

View File

@ -16,26 +16,23 @@
package top.charles7c.continew.admin.common.util.helper; package top.charles7c.continew.admin.common.util.helper;
import java.time.LocalDateTime;
import jakarta.servlet.http.HttpServletRequest;
import lombok.AccessLevel;
import lombok.NoArgsConstructor;
import cn.dev33.satoken.context.SaHolder; import cn.dev33.satoken.context.SaHolder;
import cn.dev33.satoken.session.SaSession; import cn.dev33.satoken.session.SaSession;
import cn.dev33.satoken.stp.StpUtil; import cn.dev33.satoken.stp.StpUtil;
import cn.hutool.core.util.StrUtil; import cn.hutool.core.util.StrUtil;
import cn.hutool.extra.servlet.JakartaServletUtil; import cn.hutool.extra.servlet.JakartaServletUtil;
import cn.hutool.extra.spring.SpringUtil; import cn.hutool.extra.spring.SpringUtil;
import jakarta.servlet.http.HttpServletRequest;
import lombok.AccessLevel;
import lombok.NoArgsConstructor;
import top.charles7c.continew.admin.common.constant.CacheConstants; import top.charles7c.continew.admin.common.constant.CacheConstants;
import top.charles7c.continew.admin.common.model.dto.LoginUser; import top.charles7c.continew.admin.common.model.dto.LoginUser;
import top.charles7c.continew.starter.core.util.ExceptionUtils; import top.charles7c.continew.starter.core.util.ExceptionUtils;
import top.charles7c.continew.starter.core.util.IpUtils; import top.charles7c.continew.starter.core.util.IpUtils;
import top.charles7c.continew.starter.core.util.ServletUtils;
import top.charles7c.continew.starter.extension.crud.base.CommonUserService; import top.charles7c.continew.starter.extension.crud.base.CommonUserService;
import top.charles7c.continew.starter.web.util.ServletUtils;
import java.time.LocalDateTime;
/** /**
* 登录助手 * 登录助手

View File

@ -33,7 +33,7 @@ import top.charles7c.continew.admin.monitor.mapper.LogMapper;
import top.charles7c.continew.admin.monitor.model.entity.LogDO; import top.charles7c.continew.admin.monitor.model.entity.LogDO;
import top.charles7c.continew.admin.system.service.UserService; import top.charles7c.continew.admin.system.service.UserService;
import top.charles7c.continew.starter.core.constant.StringConstants; import top.charles7c.continew.starter.core.constant.StringConstants;
import top.charles7c.continew.starter.core.model.R; import top.charles7c.continew.starter.web.model.R;
import top.charles7c.continew.starter.core.util.ExceptionUtils; import top.charles7c.continew.starter.core.util.ExceptionUtils;
import top.charles7c.continew.starter.log.common.dao.LogDao; import top.charles7c.continew.starter.log.common.dao.LogDao;
import top.charles7c.continew.starter.log.common.model.LogRecord; import top.charles7c.continew.starter.log.common.model.LogRecord;

View File

@ -38,11 +38,11 @@ import top.charles7c.continew.admin.system.model.resp.StorageResp;
import top.charles7c.continew.admin.system.service.FileService; import top.charles7c.continew.admin.system.service.FileService;
import top.charles7c.continew.admin.system.service.StorageService; import top.charles7c.continew.admin.system.service.StorageService;
import top.charles7c.continew.starter.core.constant.StringConstants; import top.charles7c.continew.starter.core.constant.StringConstants;
import top.charles7c.continew.starter.core.util.SpringUtils;
import top.charles7c.continew.starter.core.util.URLUtils; import top.charles7c.continew.starter.core.util.URLUtils;
import top.charles7c.continew.starter.core.util.validate.CheckUtils; import top.charles7c.continew.starter.core.util.validate.CheckUtils;
import top.charles7c.continew.starter.core.util.validate.ValidationUtils; import top.charles7c.continew.starter.core.util.validate.ValidationUtils;
import top.charles7c.continew.starter.extension.crud.base.BaseServiceImpl; import top.charles7c.continew.starter.extension.crud.base.BaseServiceImpl;
import top.charles7c.continew.starter.web.util.SpringWebUtils;
import java.util.Collections; import java.util.Collections;
import java.util.List; import java.util.List;
@ -130,7 +130,7 @@ public class StorageServiceImpl extends BaseServiceImpl<StorageMapper, StorageDO
config.setStoragePath(bucketName); config.setStoragePath(bucketName);
fileStorageList.addAll(FileStorageServiceBuilder.buildLocalPlusFileStorage(Collections fileStorageList.addAll(FileStorageServiceBuilder.buildLocalPlusFileStorage(Collections
.singletonList(config))); .singletonList(config)));
SpringUtils.registerResourceHandler(MapUtil.of(URLUtil.url(req.getDomain()).getPath(), bucketName)); SpringWebUtils.registerResourceHandler(MapUtil.of(URLUtil.url(req.getDomain()).getPath(), bucketName));
} }
case S3 -> { case S3 -> {
String accessKey = req.getAccessKey(); String accessKey = req.getAccessKey();
@ -159,7 +159,7 @@ public class StorageServiceImpl extends BaseServiceImpl<StorageMapper, StorageDO
FileStorage fileStorage = fileStorageService.getFileStorage(req.getCode()); FileStorage fileStorage = fileStorageService.getFileStorage(req.getCode());
fileStorageList.remove(fileStorage); fileStorageList.remove(fileStorage);
fileStorage.close(); fileStorage.close();
SpringUtils.deRegisterResourceHandler(MapUtil.of(URLUtil.url(req.getDomain()).getPath(), req.getBucketName())); SpringWebUtils.deRegisterResourceHandler(MapUtil.of(URLUtil.url(req.getDomain()).getPath(), req.getBucketName()));
} }
/** /**

View File

@ -31,9 +31,9 @@ import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.web.ServerProperties; import org.springframework.boot.autoconfigure.web.ServerProperties;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController; import org.springframework.web.bind.annotation.RestController;
import top.charles7c.continew.starter.core.annotation.EnableGlobalExceptionHandler;
import top.charles7c.continew.starter.core.autoconfigure.project.ProjectProperties; import top.charles7c.continew.starter.core.autoconfigure.project.ProjectProperties;
import top.charles7c.continew.starter.extension.crud.annotation.EnableCrudRestController; import top.charles7c.continew.starter.extension.crud.annotation.EnableCrudRestController;
import top.charles7c.continew.starter.web.annotation.EnableGlobalExceptionHandler;
import java.net.InetAddress; import java.net.InetAddress;

View File

@ -42,7 +42,7 @@ import top.charles7c.continew.admin.system.service.UserService;
import top.charles7c.continew.starter.cache.redisson.util.RedisUtils; import top.charles7c.continew.starter.cache.redisson.util.RedisUtils;
import top.charles7c.continew.starter.core.util.ExceptionUtils; import top.charles7c.continew.starter.core.util.ExceptionUtils;
import top.charles7c.continew.starter.core.util.validate.ValidationUtils; import top.charles7c.continew.starter.core.util.validate.ValidationUtils;
import top.charles7c.continew.starter.core.model.R; import top.charles7c.continew.starter.web.model.R;
import top.charles7c.continew.starter.log.common.annotation.Log; import top.charles7c.continew.starter.log.common.annotation.Log;
import java.util.List; import java.util.List;

View File

@ -34,7 +34,7 @@ import top.charles7c.continew.admin.auth.model.resp.LoginResp;
import top.charles7c.continew.admin.auth.service.LoginService; import top.charles7c.continew.admin.auth.service.LoginService;
import top.charles7c.continew.starter.core.exception.BadRequestException; import top.charles7c.continew.starter.core.exception.BadRequestException;
import top.charles7c.continew.starter.core.util.validate.ValidationUtils; import top.charles7c.continew.starter.core.util.validate.ValidationUtils;
import top.charles7c.continew.starter.core.model.R; import top.charles7c.continew.starter.web.model.R;
import top.charles7c.continew.starter.log.common.annotation.Log; import top.charles7c.continew.starter.log.common.annotation.Log;
import me.zhyd.oauth.model.AuthCallback; import me.zhyd.oauth.model.AuthCallback;

View File

@ -52,7 +52,7 @@ import top.charles7c.continew.starter.core.autoconfigure.project.ProjectProperti
import top.charles7c.continew.starter.core.util.TemplateUtils; import top.charles7c.continew.starter.core.util.TemplateUtils;
import top.charles7c.continew.starter.core.util.validate.CheckUtils; import top.charles7c.continew.starter.core.util.validate.CheckUtils;
import top.charles7c.continew.starter.core.util.validate.ValidationUtils; import top.charles7c.continew.starter.core.util.validate.ValidationUtils;
import top.charles7c.continew.starter.core.model.R; import top.charles7c.continew.starter.web.model.R;
import top.charles7c.continew.starter.log.common.annotation.Log; import top.charles7c.continew.starter.log.common.annotation.Log;
import top.charles7c.continew.starter.messaging.mail.util.MailUtils; import top.charles7c.continew.starter.messaging.mail.util.MailUtils;

View File

@ -44,7 +44,7 @@ import top.charles7c.continew.starter.core.autoconfigure.project.ProjectProperti
import top.charles7c.continew.starter.core.util.validate.ValidationUtils; import top.charles7c.continew.starter.core.util.validate.ValidationUtils;
import top.charles7c.continew.starter.data.mybatis.plus.base.IBaseEnum; import top.charles7c.continew.starter.data.mybatis.plus.base.IBaseEnum;
import top.charles7c.continew.starter.extension.crud.model.query.SortQuery; import top.charles7c.continew.starter.extension.crud.model.query.SortQuery;
import top.charles7c.continew.starter.core.model.R; import top.charles7c.continew.starter.web.model.R;
import top.charles7c.continew.starter.log.common.annotation.Log; import top.charles7c.continew.starter.log.common.annotation.Log;
import java.util.Arrays; import java.util.Arrays;

View File

@ -38,7 +38,7 @@ import top.charles7c.continew.admin.monitor.model.resp.DashboardTotalResp;
import top.charles7c.continew.admin.monitor.service.DashboardService; import top.charles7c.continew.admin.monitor.service.DashboardService;
import top.charles7c.continew.admin.system.model.resp.DashboardAnnouncementResp; import top.charles7c.continew.admin.system.model.resp.DashboardAnnouncementResp;
import top.charles7c.continew.starter.core.util.validate.ValidationUtils; import top.charles7c.continew.starter.core.util.validate.ValidationUtils;
import top.charles7c.continew.starter.core.model.R; import top.charles7c.continew.starter.web.model.R;
import top.charles7c.continew.starter.log.common.annotation.Log; import top.charles7c.continew.starter.log.common.annotation.Log;
import java.util.List; import java.util.List;

View File

@ -39,7 +39,7 @@ import top.charles7c.continew.admin.monitor.model.resp.SystemLogResp;
import top.charles7c.continew.admin.monitor.service.LogService; import top.charles7c.continew.admin.monitor.service.LogService;
import top.charles7c.continew.starter.extension.crud.model.query.PageQuery; import top.charles7c.continew.starter.extension.crud.model.query.PageQuery;
import top.charles7c.continew.starter.extension.crud.model.resp.PageResp; import top.charles7c.continew.starter.extension.crud.model.resp.PageResp;
import top.charles7c.continew.starter.core.model.R; import top.charles7c.continew.starter.web.model.R;
import top.charles7c.continew.starter.log.common.annotation.Log; import top.charles7c.continew.starter.log.common.annotation.Log;
/** /**

View File

@ -35,7 +35,7 @@ import top.charles7c.continew.admin.auth.service.OnlineUserService;
import top.charles7c.continew.starter.core.util.validate.CheckUtils; import top.charles7c.continew.starter.core.util.validate.CheckUtils;
import top.charles7c.continew.starter.extension.crud.model.query.PageQuery; import top.charles7c.continew.starter.extension.crud.model.query.PageQuery;
import top.charles7c.continew.starter.extension.crud.model.resp.PageResp; import top.charles7c.continew.starter.extension.crud.model.resp.PageResp;
import top.charles7c.continew.starter.core.model.R; import top.charles7c.continew.starter.web.model.R;
/** /**
* 在线用户 API * 在线用户 API

View File

@ -34,7 +34,7 @@ import top.charles7c.continew.starter.core.util.validate.ValidationUtils;
import top.charles7c.continew.starter.extension.crud.annotation.CrudRequestMapping; import top.charles7c.continew.starter.extension.crud.annotation.CrudRequestMapping;
import top.charles7c.continew.starter.extension.crud.base.BaseController; import top.charles7c.continew.starter.extension.crud.base.BaseController;
import top.charles7c.continew.starter.extension.crud.base.ValidateGroup; import top.charles7c.continew.starter.extension.crud.base.ValidateGroup;
import top.charles7c.continew.starter.core.model.R; import top.charles7c.continew.starter.web.model.R;
/** /**
* 公告管理 API * 公告管理 API

View File

@ -36,7 +36,7 @@ import top.charles7c.continew.starter.extension.crud.annotation.CrudRequestMappi
import top.charles7c.continew.starter.extension.crud.base.BaseController; import top.charles7c.continew.starter.extension.crud.base.BaseController;
import top.charles7c.continew.starter.extension.crud.base.ValidateGroup; import top.charles7c.continew.starter.extension.crud.base.ValidateGroup;
import top.charles7c.continew.starter.extension.crud.enums.Api; import top.charles7c.continew.starter.extension.crud.enums.Api;
import top.charles7c.continew.starter.core.model.R; import top.charles7c.continew.starter.web.model.R;
/** /**
* 菜单管理 API * 菜单管理 API

View File

@ -31,7 +31,7 @@ import top.charles7c.continew.admin.system.service.MessageService;
import top.charles7c.continew.admin.system.service.MessageUserService; import top.charles7c.continew.admin.system.service.MessageUserService;
import top.charles7c.continew.starter.extension.crud.model.query.PageQuery; import top.charles7c.continew.starter.extension.crud.model.query.PageQuery;
import top.charles7c.continew.starter.extension.crud.model.resp.PageResp; import top.charles7c.continew.starter.extension.crud.model.resp.PageResp;
import top.charles7c.continew.starter.core.model.R; import top.charles7c.continew.starter.web.model.R;
import top.charles7c.continew.starter.log.common.annotation.Log; import top.charles7c.continew.starter.log.common.annotation.Log;
import java.util.List; import java.util.List;

View File

@ -33,7 +33,7 @@ import top.charles7c.continew.admin.system.model.req.OptionReq;
import top.charles7c.continew.admin.system.model.req.OptionResetValueReq; import top.charles7c.continew.admin.system.model.req.OptionResetValueReq;
import top.charles7c.continew.admin.system.model.resp.OptionResp; import top.charles7c.continew.admin.system.model.resp.OptionResp;
import top.charles7c.continew.admin.system.service.OptionService; import top.charles7c.continew.admin.system.service.OptionService;
import top.charles7c.continew.starter.core.model.R; import top.charles7c.continew.starter.web.model.R;
/** /**
* 参数管理 API * 参数管理 API

View File

@ -48,7 +48,7 @@ import top.charles7c.continew.admin.system.service.UserSocialService;
import top.charles7c.continew.starter.cache.redisson.util.RedisUtils; import top.charles7c.continew.starter.cache.redisson.util.RedisUtils;
import top.charles7c.continew.starter.core.util.ExceptionUtils; import top.charles7c.continew.starter.core.util.ExceptionUtils;
import top.charles7c.continew.starter.core.util.validate.ValidationUtils; import top.charles7c.continew.starter.core.util.validate.ValidationUtils;
import top.charles7c.continew.starter.core.model.R; import top.charles7c.continew.starter.web.model.R;
import java.util.List; import java.util.List;
import java.util.stream.Collectors; import java.util.stream.Collectors;

View File

@ -39,7 +39,7 @@ import top.charles7c.continew.admin.system.service.UserService;
import top.charles7c.continew.starter.extension.crud.annotation.CrudRequestMapping; import top.charles7c.continew.starter.extension.crud.annotation.CrudRequestMapping;
import top.charles7c.continew.starter.extension.crud.base.BaseController; import top.charles7c.continew.starter.extension.crud.base.BaseController;
import top.charles7c.continew.starter.extension.crud.base.ValidateGroup; import top.charles7c.continew.starter.extension.crud.base.ValidateGroup;
import top.charles7c.continew.starter.core.model.R; import top.charles7c.continew.starter.web.model.R;
/** /**
* 用户管理 API * 用户管理 API

View File

@ -42,7 +42,7 @@ import top.charles7c.continew.starter.core.autoconfigure.project.ProjectProperti
import top.charles7c.continew.starter.core.util.validate.ValidationUtils; import top.charles7c.continew.starter.core.util.validate.ValidationUtils;
import top.charles7c.continew.starter.extension.crud.model.query.PageQuery; import top.charles7c.continew.starter.extension.crud.model.query.PageQuery;
import top.charles7c.continew.starter.extension.crud.model.resp.PageResp; import top.charles7c.continew.starter.extension.crud.model.resp.PageResp;
import top.charles7c.continew.starter.core.model.R; import top.charles7c.continew.starter.web.model.R;
/** /**
* 代码生成 API * 代码生成 API

View File

@ -31,7 +31,7 @@
</modules> </modules>
<properties> <properties>
<!-- 项目版本 --> <!-- 项目版本 -->
<revision>2.3.0-SNAPSHOT</revision> <revision>2.3.0-SNAPSHOT</revision>
</properties> </properties>
@ -76,6 +76,12 @@
</dependencyManagement> </dependencyManagement>
<dependencies> <dependencies>
<!-- Hutool小而全的 Java 工具类库,通过静态方法封装,降低相关 API 的学习成本,提高工作效率,使 Java 拥有函数式语言般的优雅,让 Java 语言也可以“甜甜的”) -->
<dependency>
<groupId>cn.hutool</groupId>
<artifactId>hutool-all</artifactId>
</dependency>
<!-- Lombok在 Java 开发过程中用注解的方式,简化了 JavaBean 的编写,避免了冗余和样板式代码,让编写的类更加简洁) --> <!-- Lombok在 Java 开发过程中用注解的方式,简化了 JavaBean 的编写,避免了冗余和样板式代码,让编写的类更加简洁) -->
<dependency> <dependency>
<groupId>org.projectlombok</groupId> <groupId>org.projectlombok</groupId>