Skip to content

Commit

Permalink
Sortowanie projektów w archiwum od najświeższego trwającego do najsta…
Browse files Browse the repository at this point in the history
…rszego zamkniętego
  • Loading branch information
pktiuk committed Jun 29, 2024
1 parent eb8b0d2 commit eaa689a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion layouts/project/project.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@
</div>
<div class="square square-white"></div>
<div class="archive-gallery">
{{range .Pages}}
{{ $CurrentProjects := sort (collections.Where .Pages ".Params.end_date" nil) ".Params.start_date" "desc" }}
{{ $EndedProjects := sort (collections.Where .Pages "Params.end_date" "ne" nil) ".Params.end_date" "desc" }}
{{range append $EndedProjects $CurrentProjects}}
<div class="archive-item" data-aos="fade-up">
<a href="{{ .RelPermalink }}">
{{ if .Params.archive_image }}
Expand Down

0 comments on commit eaa689a

Please sign in to comment.