<!--

    Queue - A Queueing system that can be used to handle labs in higher education
    Copyright (C) 2016-2020  Delft University of Technology

    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU Affero General Public License as
    published by the Free Software Foundation, either version 3 of the
    License, or (at your option) any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU Affero General Public License for more details.

    You should have received a copy of the GNU Affero General Public License
    along with this program.  If not, see <https://www.gnu.org/licenses/>.

-->
<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org" xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout" layout:decorate="~{layout}">
    <!--@thymesVar id="edition" type="nl.tudelft.labracore.api.dto.EditionDetailsDTO"-->
    <!--@thymesVar id="student" type="nl.tudelft.labracore.api.dto.PersonDetailsDTO"-->
    <!--@thymesVar id="requests" type="org.springframework.data.domain.Page<nl.tudelft.queue.model.LabRequest>"-->

    <body>
        <section layout:fragment="content">
            <nav role="navigation" class="breadcrumbs">
                <ol class="breadcrumb">
                    <li class="breadcrumb-item"><a href="/">Home</a></li>
                    <li class="breadcrumb-item">History</li>
                </ol>
            </nav>

            <div class="page-header">
                <h1>
                    Requests of
                    <span th:text="${student.displayName}"></span>
                </h1>
            </div>

            <th:block
                th:replace="request/list/filters :: filters (returnPath=@{/history/course/{editionId}/student/{studentId}(editionId=${edition.id}, studentId=${student.id})}, multipleLabs=${true})"></th:block>
        </section>

        <section layout:fragment="outside-content">
            <div class="row mx-xl-5 mx-sm-3">
                <th:block th:replace="request/list/request-table :: request-table(showName=true, showOnlyRelevant=${false})"></th:block>
            </div>

            <div class="row mx-xl-5 mx-sm-3">
                <th:block th:replace="pagination :: pagination (page=${requests}, size=3)"></th:block>
            </div>
        </section>
    </body>
</html>
