调用图
映射
@Configuration
public class MyMvcConfig implements WebMvcConfigurer {
@Override
public void addViewControllers(ViewControllerRegistry registry) {
registry.addViewController("/lyear_ui_other.html").setViewName("/lyear_ui_other.html");
}
@Override
public void addResourceHandlers(ResourceHandlerRegistry registry) {
registry.addResourceHandler("/static/**").addResourceLocations("classpath:/static/");
}
Controller
@RestController
@RequestMapping("/saleManage")
public class SalesManagementController {
@GetMapping("/customer.html")
public ModelAndView customer(Model model) {
model.addAttribute("title", "客户管理");
return new ModelAndView("/saleManage/customer");
}
}