Thymeleaf中each标签遍历list如何获取index
生活随笔
收集整理的這篇文章主要介紹了
Thymeleaf中each标签遍历list如何获取index
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
<tr th:each="user,userStat:${users}">
userStat是狀態變量,有 index,count,size,current,even,odd,first,last等屬性,如果沒有顯示設置狀態變量,thymeleaf會默 認給個“變量名+Stat"的狀態變量。
總結
以上是生活随笔為你收集整理的Thymeleaf中each标签遍历list如何获取index的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: org.apache.ibatis.bi
- 下一篇: oracle: 在sqlplus中,执行