@Configuration
public class DefaultView extends WebMvcConfigurerAdapter{
@Override
public void addViewControllers(ViewControllerRegistry registry) {super.addViewControllers(registry);
// 主页
registry.addViewController("/").setViewName("forward:/index");
}
}