Skip to content

Commit

Permalink
Make grey bar and future footer allow for TBD
Browse files Browse the repository at this point in the history
Fixes devopsdays#233


Former-commit-id: 74d76e7
  • Loading branch information
mattstratton committed May 6, 2016
1 parent bd62e80 commit 6e88870
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 4 deletions.
16 changes: 13 additions & 3 deletions themes/devopsdays-legacy/layouts/partials/future.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,13 @@
{{ range seq .Now.Year (add .Now.Year 1) }}
{{ $future_year := (chomp .) }}
{{ range $.Site.Data.events }}
{{ if and (eq .year $future_year) (eq .status "current") ( .startdate ) }}
{{ if and (eq .year $future_year) (eq .status "current") }}
{{ $.Scratch.SetInMap "future_years" $future_year $future_year }}
{{ $.Scratch.SetInMap (print "future" $future_year) .startdate .friendly }}
{{ if .startdate }}
{{ $.Scratch.SetInMap (print "future" $future_year) .startdate .friendly }}
{{ else }}
{{ $.Scratch.SetInMap (print "future" $future_year) "TBD" .friendly }}
{{ end }}
{{ end }}
{{ end }}
{{ end }}
Expand All @@ -33,7 +37,13 @@ <h1>Future</h1>
<strong>{{ . }}</strong><br/>
{{ range ($.Scratch.GetSortedMapValues (print "future" .)) }}
{{ $c_event := (index $.Site.Data.events .) }}
<a href="/events/{{ $c_event.name }}">{{ $c_event.city }}: {{ dateFormat "Jan 2" $c_event.startdate }} - {{ dateFormat "Jan 2" $c_event.enddate }}</a><br />
<a href="/events/{{ $c_event.name }}">{{ $c_event.city }}:
{{ if $c_event.startdate }}
{{ dateFormat "Jan 2" $c_event.startdate }} - {{ dateFormat "Jan 2" $c_event.enddate }}
{{ else }}
Coming Soon!
{{ end }}
</a><br />
{{ end }}
{{ end }}
</div>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<div class="submenu" style="width:550px">
<h3>
{{ range sort $.Site.Data.events "startdate" }}
{{ if eq .status "current" }}
{{ if and ( eq .status "current") ( .startdate ) }}
{{ $.Scratch.Add "events" "<a href = '/events/" }}
{{ $.Scratch.Add "events" .name }}
{{ $.Scratch.Add "events" "/welcome'>" }}
Expand Down

0 comments on commit 6e88870

Please sign in to comment.