package com.stylefeng.guns.modular.system.auth;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.stereotype.Component;
|
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
|
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
|
|
|
@Component
|
public class Configuration implements WebMvcConfigurer {
|
|
@Autowired
|
private AuthIntercepter authIntercepter;
|
|
/**
|
* 重写添加拦截器方法并添加配置拦截器
|
*
|
* @param registry
|
*/
|
@Override
|
public void addInterceptors(InterceptorRegistry registry) {
|
// registry.addInterceptor(authIntercepter).addPathPatterns("/api/**")
|
// .excludePathPatterns("/base/**");
|
|
}
|
}
|