feiyu02
2024-08-15 196bb14112448857a885e32dc4149e308e00b01a
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
package cn.flightfeather.supervision.config
 
import org.springframework.context.annotation.Configuration
import org.springframework.web.servlet.config.annotation.InterceptorRegistry
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer
 
/**
 * web配置
 */
@Configuration
class WebMvcConfig : WebMvcConfigurer {
 
    override fun addInterceptors(registry: InterceptorRegistry) {
        super.addInterceptors(registry)
        // 添加自定义拦截器
        registry.addInterceptor(FFInterceptor())
    }
}