![](/img/trans.png)
[英]JavaScript and CSS files won't work in html (spring boot app)
[英]Spring Boot .html files not resolving
我有一个Spring Boot应用程序-
我有一个控制器-
@Controller("CWOController")
@RequestMapping(value = "/cworequest")
public class CWOController {
@RequestMapping(value = {"/index.html"}, method = {RequestMethod.GET})
public String getCwoIdSearchForm(Model model) {
model.addAttribute("cwoRequestForm", new CWORequest());
return "index";
}
这适用于url- > http:// localhost:8080 / cworequest /
但我需要-> http:// localhost:8080 / cworequest / index.html才能映射到上述GET。
我怎么做?
使用映射/添加另一个默认方法,并返回错误或其他任何信息。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.