1、正常url标签
<form th:action="@{/u/admin/profile}" method="post" th:object="${userModel.user}" id="userForm">
2、特殊的格式,如果url标签中含有对象的属性,则为下方:
th:action="'/u/'+${userModel.user.username}+'/profile'"
<form th:action="'/u/'+${userModel.user.username}+'/profile'" method="post" th:object="${userModel.user}" id="userForm">
<button type="submit" class="btn btn-primary">保存</button>