Update cell in calender links to orders filteredByDay

This commit is contained in:
Theo Reichert 2023-11-15 00:34:16 +01:00 committed by Simon Bruder
parent fcacb18111
commit ce06970972
Signed by: simon
GPG key ID: 8D3C82F9F309F8EC
2 changed files with 9 additions and 8 deletions

View file

@ -8,6 +8,7 @@ import org.springframework.web.bind.annotation.*;
import java.time.LocalDateTime;
import java.time.LocalDate;
import java.time.temporal.ChronoUnit;
import java.time.format.DateTimeFormatter;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Comparator;
@ -124,6 +125,7 @@ public class OrderController {
for (LocalDate date : datesOfTheWeek) {
ArrayList<String> x = new ArrayList<String>(2);
x.add(Integer.toString(date.getDayOfMonth()));
x.add(date.format(DateTimeFormatter.ISO_LOCAL_DATE));
week_to_add_to_month.add(x);
}
//datesOfTheWeek.clear();

View file

@ -64,18 +64,17 @@
<div class="content">
<div
class="header"
th:text="${day.get(0)}"
>
<a
href="orders.html" th:href="@{'/orders/' + ${day.get(1)}}"
th:text="${day.get(0)}"
class="description"
>
</a>
</div>
</div>
<div class="content">
<a
class="description"
>
<span th:text="${#lists.size(day)-1}"></span><br>
<span th:each="item, stat : ${day}" th:if="${stat.index} >= 1" th:text="${item}"></span>
<!-- <span th:text="${99+2}"></span>-->
</a>
<p th:each="item, stat : ${day}" th:if="${stat.index} > 1" th:text="${item}"></p>
</div>
</td>
</tr>