use of com.baomidou.mybatisplus.extension.plugins.inner.PaginationInnerInterceptor in project goodsKill by techa03.
the class MybatisPlusConfig method mybatisPlusInterceptor.
/**
* 新的分页插件,一缓和二缓遵循mybatis的规则,需要设置 MybatisConfiguration#useDeprecatedExecutor = false 避免缓存出现问题(该属性会在旧插件移除后一同移除)
*/
@Bean
public MybatisPlusInterceptor mybatisPlusInterceptor() {
MybatisPlusInterceptor interceptor = new MybatisPlusInterceptor();
interceptor.addInnerInterceptor(new PaginationInnerInterceptor(DbType.MYSQL));
return interceptor;
}
use of com.baomidou.mybatisplus.extension.plugins.inner.PaginationInnerInterceptor in project java-example by saxingz.
the class MybatisPlusConfig method mybatisPlusInterceptor.
/**
* 新的分页插件,一缓和二缓遵循mybatis的规则,需要设置 MybatisConfiguration#useDeprecatedExecutor = false 避免缓存出现问题
*/
@Bean
public MybatisPlusInterceptor mybatisPlusInterceptor() {
MybatisPlusInterceptor interceptor = new MybatisPlusInterceptor();
interceptor.addInnerInterceptor(new PaginationInnerInterceptor(DbType.MYSQL));
return interceptor;
}
use of com.baomidou.mybatisplus.extension.plugins.inner.PaginationInnerInterceptor in project knife-starter by 1120023921.
the class MybatisPlusAutoConfig method mybatisPlusInterceptor.
/**
* @param tenantLineHandler 租户处理器
* @description Mybaits插件配置
* @author 胡昊
* @email huhao9277@gmail.com
*/
@Bean
@ConditionalOnMissingBean(MybatisPlusInterceptor.class)
public MybatisPlusInterceptor mybatisPlusInterceptor(@Autowired(required = false) TenantLineHandler tenantLineHandler) {
MybatisPlusInterceptor interceptor = new MybatisPlusInterceptor();
if (tenantLineHandler != null) {
interceptor.addInnerInterceptor(new TenantLineInnerInterceptor(tenantLineHandler));
}
interceptor.addInnerInterceptor(new PaginationInnerInterceptor(DbType.MYSQL));
interceptor.addInnerInterceptor(new OptimisticLockerInnerInterceptor());
return interceptor;
}
use of com.baomidou.mybatisplus.extension.plugins.inner.PaginationInnerInterceptor in project ruoyi-vue-pro by YunaiV.
the class YudaoMybatisAutoConfiguration method mybatisPlusInterceptor.
@Bean
public MybatisPlusInterceptor mybatisPlusInterceptor() {
MybatisPlusInterceptor mybatisPlusInterceptor = new MybatisPlusInterceptor();
// 分页插件
mybatisPlusInterceptor.addInnerInterceptor(new PaginationInnerInterceptor());
return mybatisPlusInterceptor;
}
use of com.baomidou.mybatisplus.extension.plugins.inner.PaginationInnerInterceptor in project CSKY by SHU-Silence.
the class MybatisPlusConfig method mybatisPlusInterceptor.
// 加入mybatis-plus的分页插件
@Bean
public MybatisPlusInterceptor mybatisPlusInterceptor() {
MybatisPlusInterceptor mybatisPlusInterceptor = new MybatisPlusInterceptor();
mybatisPlusInterceptor.addInnerInterceptor(new PaginationInnerInterceptor());
return mybatisPlusInterceptor;
}
Aggregations