diff --git a/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/interceptor/mybatis/MybatisInterceptor.java b/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/interceptor/mybatis/MybatisInterceptor.java index 2c63db4..98af73a 100644 --- a/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/interceptor/mybatis/MybatisInterceptor.java +++ b/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/interceptor/mybatis/MybatisInterceptor.java @@ -79,7 +79,7 @@ public class MybatisInterceptor implements Interceptor { CacheKey cacheKey = executor.createCacheKey(ms, parameterObject, rowBounds, boundSql); for (MybatisPreHandler item : preHandlersChain) { item.preHandle(targetExecutor, ms, args[1], (RowBounds) args[2], - (ResultHandler) args[3], cacheKey, boundSql); + (ResultHandler) args[3], cacheKey, boundSql); } } Object result = invocation.proceed(); @@ -93,7 +93,7 @@ public class MybatisInterceptor implements Interceptor { if (preHandlersChain != null && preHandlersChain.size() > 0) { for (MybatisPreHandler item : preHandlersChain) { item.preHandle(targetExecutor, (MappedStatement) args[0], args[1], (RowBounds) args[2], - (ResultHandler) args[3], (CacheKey) args[4], (BoundSql) args[5]); + (ResultHandler) args[3], (CacheKey) args[4], (BoundSql) args[5]); } } Object result = invocation.proceed(); diff --git a/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/MybatisPreHandler.java b/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/MybatisPreHandler.java index 5e9e2eb..b0a61fe 100644 --- a/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/MybatisPreHandler.java +++ b/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/MybatisPreHandler.java @@ -6,10 +6,9 @@ import org.apache.ibatis.mapping.BoundSql; import org.apache.ibatis.mapping.MappedStatement; import org.apache.ibatis.session.ResultHandler; import org.apache.ibatis.session.RowBounds; - public interface MybatisPreHandler { void preHandle(Executor executor, MappedStatement mappedStatement, Object params, - RowBounds rowBounds, ResultHandler resultHandler, CacheKey cacheKey, BoundSql boundSql) + RowBounds rowBounds, ResultHandler resultHandler, CacheKey cacheKey, BoundSql boundSql) throws Throwable; } diff --git a/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/dataSecurity/DataSecurityPreHandler.java b/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/dataSecurity/DataSecurityPreHandler.java index fc49c05..c1e8c86 100644 --- a/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/dataSecurity/DataSecurityPreHandler.java +++ b/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/dataSecurity/DataSecurityPreHandler.java @@ -43,7 +43,7 @@ public class DataSecurityPreHandler implements MybatisPreHandler { @Override public void preHandle(Executor executor, MappedStatement mappedStatement, Object params, RowBounds rowBounds, - ResultHandler resultHandler, CacheKey cacheKey, BoundSql boundSql) throws Throwable { + ResultHandler resultHandler, CacheKey cacheKey, BoundSql boundSql) throws Throwable { if (SqlContextHolder.isSecurity()) { Statement sql = parseSql(SqlUtil.parseSql(boundSql.getSql())); sqlFiled.set(boundSql, sql.toString()); diff --git a/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/page/PageAfterHandler.java b/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/page/PageAfterHandler.java index dec4efd..4826924 100644 --- a/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/page/PageAfterHandler.java +++ b/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/page/PageAfterHandler.java @@ -17,7 +17,7 @@ public class PageAfterHandler implements MybatisAfterHandler { public Object handleObject(Object object) throws Throwable { if (PageContextHolder.isPage()) { if (object instanceof List) { - TableInfo tableInfo = new TableInfo<>((List) object); + TableInfo tableInfo = new TableInfo((List) object); tableInfo.setTotal(PageContextHolder.getTotal()); PageContextHolder.clear(); return tableInfo; diff --git a/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/page/PagePreHandler.java b/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/page/PagePreHandler.java index 835fd12..0e21921 100644 --- a/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/page/PagePreHandler.java +++ b/ruoyi-plugins/ruoyi-mybatis-interceptor/src/main/java/com/ruoyi/mybatisinterceptor/sql/page/PagePreHandler.java @@ -44,7 +44,7 @@ public class PagePreHandler implements MybatisPreHandler { @Override public void preHandle(Executor executor, MappedStatement mappedStatement, Object params, RowBounds rowBounds, - ResultHandler resultHandler, CacheKey cacheKey, BoundSql boundSql) throws Throwable { + ResultHandler resultHandler, CacheKey cacheKey, BoundSql boundSql) throws Throwable { if (PageContextHolder.isPage()) { String originSql = boundSql.getSql(); Statement sql = SqlUtil.parseSql(originSql); @@ -95,7 +95,7 @@ public class PagePreHandler implements MybatisPreHandler { } public static Long getCount(Executor executor, MappedStatement mappedStatement, Object parameter, - BoundSql boundSql, RowBounds rowBounds, ResultHandler resultHandler, String countSql) + BoundSql boundSql, RowBounds rowBounds, ResultHandler resultHandler, String countSql) throws SQLException { Map additionalParameters = boundSql.getAdditionalParameters();