Thymeleaf后台传值读取
Posted object360
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Thymeleaf后台传值读取相关的知识,希望对你有一定的参考价值。
/**
* 测试用Controller
*
* @author
* @date 2019-08-15
*/
@Controller
@RequestMapping("/danyu/test")
public class DanyuTestController extends BaseController
private String prefix = "danyu/test";
@RequiresPermissions("danyu:test:view")
@GetMapping()//@RequestMapping(method = RequestMethod.GET)
public String test(Map<String,Object> model)
model.put("ttttttt", "我是你大爷啊啊");
model.put("aaaaaaa", "123");
return prefix + "/test";
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<head>
<th:block th:include="include :: header(‘爱上对方‘)" />
</head>
<body>
<span th:text="$ttttttt">Sebastian</span>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
</script>
</body>
</html>
以上是关于Thymeleaf后台传值读取的主要内容,如果未能解决你的问题,请参考以下文章