|
|
|
@ -2,7 +2,7 @@ package com.xxl.job.admin.controller.interceptor; |
|
|
|
|
|
|
|
|
|
import org.springframework.context.annotation.Configuration; |
|
|
|
|
import org.springframework.web.servlet.config.annotation.InterceptorRegistry; |
|
|
|
|
import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter; |
|
|
|
|
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer; |
|
|
|
|
|
|
|
|
|
import javax.annotation.Resource; |
|
|
|
|
|
|
|
|
@ -12,7 +12,7 @@ import javax.annotation.Resource; |
|
|
|
|
* @author xuxueli 2018-04-02 20:48:20 |
|
|
|
|
*/ |
|
|
|
|
@Configuration |
|
|
|
|
public class WebMvcConfig extends WebMvcConfigurerAdapter { |
|
|
|
|
public class WebMvcConfig implements WebMvcConfigurer { |
|
|
|
|
|
|
|
|
|
@Resource |
|
|
|
|
private PermissionInterceptor permissionInterceptor; |
|
|
|
@ -23,7 +23,6 @@ public class WebMvcConfig extends WebMvcConfigurerAdapter { |
|
|
|
|
public void addInterceptors(InterceptorRegistry registry) { |
|
|
|
|
registry.addInterceptor(permissionInterceptor).addPathPatterns("/**"); |
|
|
|
|
registry.addInterceptor(cookieInterceptor).addPathPatterns("/**"); |
|
|
|
|
super.addInterceptors(registry); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
} |