mirror of
https://github.com/chillzhuang/blade-tool
synced 2025-01-24 05:31:44 +08:00
✨ 调整优化 mybatis 模块依赖
This commit is contained in:
parent
2f8837b855
commit
1eae535fd5
@ -35,7 +35,6 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.baomidou</groupId>
|
<groupId>com.baomidou</groupId>
|
||||||
<artifactId>mybatis-plus-spring-boot-autoconfigure</artifactId>
|
<artifactId>mybatis-plus-spring-boot-autoconfigure</artifactId>
|
||||||
<scope>provided</scope>
|
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.mybatis</groupId>
|
<groupId>org.mybatis</groupId>
|
||||||
|
@ -15,8 +15,8 @@
|
|||||||
*/
|
*/
|
||||||
package org.springblade.core.mp.config;
|
package org.springblade.core.mp.config;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.autoconfigure.MybatisPlusPropertiesCustomizer;
|
|
||||||
import com.baomidou.mybatisplus.autoconfigure.MybatisPlusProperties.CoreConfiguration;
|
import com.baomidou.mybatisplus.autoconfigure.MybatisPlusProperties.CoreConfiguration;
|
||||||
|
import com.baomidou.mybatisplus.autoconfigure.MybatisPlusPropertiesCustomizer;
|
||||||
import com.baomidou.mybatisplus.extension.plugins.MybatisPlusInterceptor;
|
import com.baomidou.mybatisplus.extension.plugins.MybatisPlusInterceptor;
|
||||||
import com.baomidou.mybatisplus.extension.plugins.handler.TenantLineHandler;
|
import com.baomidou.mybatisplus.extension.plugins.handler.TenantLineHandler;
|
||||||
import com.baomidou.mybatisplus.extension.plugins.inner.TenantLineInnerInterceptor;
|
import com.baomidou.mybatisplus.extension.plugins.inner.TenantLineInnerInterceptor;
|
||||||
@ -27,8 +27,8 @@ import org.apache.ibatis.logging.Log;
|
|||||||
import org.apache.ibatis.logging.nologging.NoLoggingImpl;
|
import org.apache.ibatis.logging.nologging.NoLoggingImpl;
|
||||||
import org.mybatis.spring.annotation.MapperScan;
|
import org.mybatis.spring.annotation.MapperScan;
|
||||||
import org.springblade.core.mp.intercept.QueryInterceptor;
|
import org.springblade.core.mp.intercept.QueryInterceptor;
|
||||||
import org.springblade.core.mp.plugins.SqlLogInterceptor;
|
|
||||||
import org.springblade.core.mp.plugins.BladePaginationInterceptor;
|
import org.springblade.core.mp.plugins.BladePaginationInterceptor;
|
||||||
|
import org.springblade.core.mp.plugins.SqlLogInterceptor;
|
||||||
import org.springblade.core.mp.props.MybatisPlusProperties;
|
import org.springblade.core.mp.props.MybatisPlusProperties;
|
||||||
import org.springblade.core.secure.utils.SecureUtil;
|
import org.springblade.core.secure.utils.SecureUtil;
|
||||||
import org.springblade.core.tool.constant.BladeConstant;
|
import org.springblade.core.tool.constant.BladeConstant;
|
||||||
@ -36,12 +36,10 @@ import org.springblade.core.tool.utils.Func;
|
|||||||
import org.springblade.core.tool.utils.ObjectUtil;
|
import org.springblade.core.tool.utils.ObjectUtil;
|
||||||
import org.springframework.beans.factory.ObjectProvider;
|
import org.springframework.beans.factory.ObjectProvider;
|
||||||
import org.springframework.boot.autoconfigure.AutoConfiguration;
|
import org.springframework.boot.autoconfigure.AutoConfiguration;
|
||||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
|
|
||||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
|
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
|
||||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
|
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
|
||||||
import org.springframework.boot.context.properties.EnableConfigurationProperties;
|
import org.springframework.boot.context.properties.EnableConfigurationProperties;
|
||||||
import org.springframework.context.annotation.Bean;
|
import org.springframework.context.annotation.Bean;
|
||||||
import org.springframework.context.annotation.Configuration;
|
|
||||||
import org.springframework.core.annotation.AnnotationAwareOrderComparator;
|
import org.springframework.core.annotation.AnnotationAwareOrderComparator;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -110,15 +108,6 @@ public class MybatisPlusConfiguration {
|
|||||||
return new SqlLogInterceptor(properties);
|
return new SqlLogInterceptor(properties);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* 内部类配置,避免 NoClassDefFoundError
|
|
||||||
*
|
|
||||||
* @author L.cm
|
|
||||||
*/
|
|
||||||
@Configuration
|
|
||||||
@ConditionalOnClass(MybatisPlusPropertiesCustomizer.class)
|
|
||||||
public static class MybatisPlusPropertiesCustomizerConfiguration {
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 关闭 mybatis 默认日志
|
* 关闭 mybatis 默认日志
|
||||||
*/
|
*/
|
||||||
@ -137,5 +126,3 @@ public class MybatisPlusConfiguration {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user