mirror of
https://gitee.com/dromara/sa-token.git
synced 2026-02-27 16:50:24 +08:00
路由拦截器 增加参数
This commit is contained in:
@@ -1,5 +1,8 @@
|
||||
package cn.dev33.satoken.interceptor;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
/**
|
||||
* 执行验证方法的辅助类
|
||||
* @author kong
|
||||
@@ -10,6 +13,6 @@ public interface SaFunction {
|
||||
/**
|
||||
* 执行验证的方法
|
||||
*/
|
||||
public void run();
|
||||
|
||||
public void run(HttpServletRequest request, HttpServletResponse response, Object handler);
|
||||
|
||||
}
|
||||
|
||||
@@ -237,7 +237,7 @@ public class SaRouteInterceptor implements HandlerInterceptor {
|
||||
getStpLogic().checkPermissionOr(codes);
|
||||
}
|
||||
} else if(this.type == SaRouteInterceptor.CUSTOM) {
|
||||
function.run();
|
||||
function.run(request, response, handler);
|
||||
}
|
||||
|
||||
// 通过验证
|
||||
|
||||
Reference in New Issue
Block a user