报错信息
Exception processing template “show”: Error resolving template [show], template might not exist or might not be accessible by any of the configured Template Resolvers
[THYMELEAF][http-nio-8080-exec-1] Exception processing template "show": Error resolving template [show], template might not exist or might not be accessible by any of the configured Template Resolvers
org.thymeleaf.exceptions.TemplateInputException: Error resolving template [show], template might not exist or might not be accessible by any of the configured Template Resolvers
at org.thymeleaf.engine.TemplateManager.resolveTemplate(TemplateManager.java:869) ~[thymeleaf-3.0.11.RELEASE.jar:3.0.11.RELEASE]
at org.thymeleaf.engine.TemplateManager.parseAndProcess(TemplateManager.java:607) ~[thymeleaf-3.0.11.RELEASE.jar:3.0.11.RELEASE]
at org.thymeleaf.TemplateEngine.process(TemplateEngine.java:1098) [thymeleaf-3.0.11.RELEASE.jar:3.0.11.RELEASE]
原因
当spring boot应用程序配置为视图解析器时,将使用模板文件夹中的HTML文件来解析它们。
TemplateInputException: Error resolve template is throw if the template file can not be found in the template folder.
当模板文件在 src/main/resources/templates 文件夹中不可用或文件名不正确时,会发生 Spring Boot 错误模板可能不存在或任何配置的模板解析器都无法访问。异常抛出。
我这里是文件夹 template 少个 s …
改正后问题解决