use of top.tangyh.basic.database.mybatis.auth.DataScopeInnerInterceptor in project lamp-job by zuihou.
the class ExtendExecutorMybatisAutoConfiguration method getPaginationBeforeInnerInterceptor.
/**
* 数据权限插件
*
* @return 数据权限插件
*/
@Override
protected List<InnerInterceptor> getPaginationBeforeInnerInterceptor() {
List<InnerInterceptor> list = new ArrayList<>();
Boolean isDataScope = databaseProperties.getIsDataScope();
if (isDataScope) {
list.add(new DataScopeInnerInterceptor(userId -> SpringUtils.getBean(UserService.class).getDataScopeById(userId)));
}
return list;
}
use of top.tangyh.basic.database.mybatis.auth.DataScopeInnerInterceptor in project lamp-job by zuihou.
the class BaseExecutorMybatisAutoConfiguration method getPaginationBeforeInnerInterceptor.
/**
* 数据权限插件
*
* @return 数据权限插件
*/
@Override
protected List<InnerInterceptor> getPaginationBeforeInnerInterceptor() {
List<InnerInterceptor> list = new ArrayList<>();
Boolean isDataScope = databaseProperties.getIsDataScope();
if (isDataScope) {
list.add(new DataScopeInnerInterceptor(userId -> SpringUtils.getBean(UserService.class).getDataScopeById(userId)));
}
return list;
}
Aggregations