初始化代码

This commit is contained in:
lpd
2026-04-09 11:52:02 +08:00
parent bb5937c5b7
commit 8319ac9516
565 changed files with 965 additions and 658 deletions

View File

@@ -12,7 +12,7 @@ import org.springframework.transaction.annotation.EnableTransactionManagement;
/**
* 数据库配置类
*
* @author lyz源码
* @author 芋道源码
*/
@AutoConfiguration
@EnableTransactionManagement(proxyTargetClass = true) // 启动事务管理

View File

@@ -12,7 +12,7 @@ import java.io.IOException;
/**
* Druid 底部广告过滤器
*
* @author lyz源码
* @author 芋道源码
*/
public class DruidAdRemoveFilter extends OncePerRequestFilter {

View File

@@ -18,7 +18,7 @@ import java.util.Set;
/**
* 当 IdType 为 {@link IdType#NONE} 时,根据 PRIMARY 数据源所使用的数据库,自动设置
*
* @author lyz源码
* @author 芋道源码
*/
@Slf4j
public class IdTypeEnvironmentPostProcessor implements EnvironmentPostProcessor {
@@ -41,7 +41,7 @@ public class IdTypeEnvironmentPostProcessor implements EnvironmentPostProcessor
}
// 设置 Quartz JobStore 对应的 Driver
// TODO 鹭鹭:暂时没有找到特别合适的地方,先放在这里
// TODO 芋艿:暂时没有找到特别合适的地方,先放在这里
setJobStoreDriverIfPresent(environment, dbType);
// 如果非 NONE则不进行处理

View File

@@ -29,7 +29,7 @@ import java.util.concurrent.TimeUnit;
/**
* MyBaits 配置类
*
* @author lyz源码
* @author 芋道源码
*/
@AutoConfiguration(before = MybatisPlusAutoConfiguration.class) // 目的:先于 MyBatis Plus 自动配置,避免 @MapperScan 可能扫描不到 Mapper 打印 warn 日志
@MapperScan(value = "${lyzsys.info.base-package}", annotationClass = Mapper.class,

View File

@@ -17,7 +17,7 @@ import java.time.LocalDateTime;
* 为什么实现 {@link TransPojo} 接口?
* 因为使用 Easy-Trans TransType.SIMPLE 模式,集成 MyBatis Plus 查询
*
* @author lyz源码
* @author 芋道源码
*/
@Data
@JsonIgnoreProperties(value = "transMap") // 由于 Easy-Trans 会添加 transMap 属性,避免 Jackson 在 Spring Cache 反序列化报错

View File

@@ -45,11 +45,11 @@ public enum DbTypeEnum {
/**
* SQL Server
*/
SQL_SERVER(DbType.SQL_SERVER, "Microsoft SQL Server", "CHARINDEX(',' + '#{value}' + ',', ',' + #{column} + ',') <> 0"),
SQL_SERVER(DbType.SQL_SERVER, "Microsoft SQL Server", "CHARINDEX(',' + #{value} + ',', ',' + #{column} + ',') <> 0"),
/**
* SQL Server 2005
*/
SQL_SERVER2005(DbType.SQL_SERVER2005, "Microsoft SQL Server 2005", "CHARINDEX(',' + '#{value}' + ',', ',' + #{column} + ',') <> 0"),
SQL_SERVER2005(DbType.SQL_SERVER2005, "Microsoft SQL Server 2005", "CHARINDEX(',' + #{value} + ',', ',' + #{column} + ',') <> 0"),
/**
* 达梦

View File

@@ -142,7 +142,7 @@ public class QueryWrapperX<T> extends QueryWrapper<T> {
/**
* 设置只返回最后一条
*
* TODO 鹭鹭:不是完美解,需要在思考下。如果使用多数据源,并且数据源是多种类型时,可能会存在问题:实现之返回一条的语法不同
* TODO 芋艿:不是完美解,需要在思考下。如果使用多数据源,并且数据源是多种类型时,可能会存在问题:实现之返回一条的语法不同
*
* @return this
*/

View File

@@ -16,7 +16,7 @@ import java.sql.SQLException;
* 字段字段的 TypeHandler 实现类,基于 {@link AES} 实现
* 可通过 jasypt.encryptor.password 配置项,设置密钥
*
* @author lyz源码
* @author 芋道源码
*/
public class EncryptTypeHandler extends BaseTypeHandler<String> {

View File

@@ -16,7 +16,7 @@ import java.util.List;
/**
* List<Long> 的类型转换器实现类,对应数据库的 varchar 类型
*
* @author lyz源码
* @author 芋道源码
*/
@MappedJdbcTypes(JdbcType.VARCHAR)
@MappedTypes(List.class)

View File

@@ -17,7 +17,7 @@ import java.util.Set;
/**
* Set<Long> 的类型转换器实现类,对应数据库的 varchar 类型
*
* @author lyz源码
* @author 芋道源码
*/
@MappedJdbcTypes(JdbcType.VARCHAR)
@MappedTypes(List.class)

View File

@@ -15,7 +15,7 @@ import java.sql.SQLException;
/**
* JDBC 工具类
*
* @author lyz源码
* @author 芋道源码
*/
public class JdbcUtils {

View File

@@ -9,7 +9,7 @@ import java.util.List;
/**
* VO 数据翻译 Utils
*
* @author lyz源码
* @author 芋道源码
*/
public class TranslateUtils {