package com.liangjian.dataplatform.member.config;

import com.liangjian.dataplatform.member.interceptor.DynamicParamAnalyser;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

/**
 * Created by huangziqi on 2019/12/17
 *
 * 用于解析Get请求时携带的参数，动态查询
 */
@Configuration
public class DynamicParamConfig implements WebMvcConfigurer {
    @Autowired
    private DynamicParamAnalyser analyser;

    @Override
    public void addInterceptors(InterceptorRegistry registry) {
        registry.addInterceptor(analyser);
    }
}
