thymeleaf 双层for循环指定循环次数。

<div style="border:1px solid #ccc;margin-bottom: 10px;padding:12px;float:left;width:49%;margin-left:1%;" th:each="dict:${dics}">
    <span style="width:80%;display: block;">[[${dict.dictLabel}]]</span>

    <div  th:each="processList:${dict.processList} ">
        <span th:each="i:${#numbers.sequence(0, 0)}" style="width:80%;display: block;" class="progressBar" id="spaceused1">[[${processList.workRange}]]</span>

        <br>

        <div th:each="i:${#numbers.sequence(0, 2)}"  style="float: left;display: flex">
            <ul>
                <li>[[${processList.createUser}]]</li>
                <li>[[${processList.createTime}]]</li>
            </ul>
        </div>
    </div>
</div>

 传入数据的样式:

 

 

posted @ 2023-06-03 15:56  张载zz  阅读(250)  评论(0编辑  收藏  举报