diff --git a/themes/nluug/layouts/evenementen/list.html b/themes/nluug/layouts/evenementen/list.html index 71c5983..016c522 100644 --- a/themes/nluug/layouts/evenementen/list.html +++ b/themes/nluug/layouts/evenementen/list.html @@ -1,7 +1,30 @@ {{ define "main" }} + + {{ $.Scratch.Set "highlighted_events" slice }} + + {{ range .Pages }} + {{ if isset .Params "event_start" }} + {{ $event_start := .Params.event_start | time }} + + {{ if le now $event_start }} + {{ $.Scratch.Add "highlighted_events" . }} + {{ end }} + {{ end }} + {{ end }} + + {{ if (gt ($.Scratch.Get "highlighted_events" | len) 0) }} +

Aankomende evenementen

+
+ {{ range $.Scratch.Get "highlighted_events" }} + {{ partial "show-highlighted-event.html" . }} + {{ end }} +
+ {{ end }} + +

Overzicht