diff options
Diffstat (limited to 'src/main/resources/templates/pkgs/sorting.html')
-rw-r--r-- | src/main/resources/templates/pkgs/sorting.html | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main/resources/templates/pkgs/sorting.html b/src/main/resources/templates/pkgs/sorting.html new file mode 100644 index 0000000..199ef68 --- /dev/null +++ b/src/main/resources/templates/pkgs/sorting.html @@ -0,0 +1,6 @@ +<th scope="col" th:fragment="sorting(field, label)"> + <a class="text-decoration-none text-dark" + th:href="@{'/pkgs?' + ${sortField!=null ? '&sort=' + field + ',' + (sortField == field ? reverseSortDirection : sortDirection) : ''}}">[[${label}]]</a> + <span th:if="${sortField == field}" + th:class="${sortDirection == 'asc' ? 'fas fa-arrow-down-short-wide' : 'fas fa-arrow-down-wide-short'}"></span> +</th>
\ No newline at end of file |