Fix 'schedule' shortcode when rooms do not have events on all days
This commit is contained in:
parent
2de66d7789
commit
2463c21096
|
@ -9,10 +9,12 @@
|
|||
{{ $rooms := dict }}
|
||||
{{ range $day := .conference.days }}
|
||||
{{ range $room := $data.schedule.conference.rooms }}
|
||||
{{ with index $day.rooms $room.name }}
|
||||
{{ if index $rooms $room.name }}
|
||||
{{ $rooms = merge $rooms (dict $room.name ((index $rooms $room.name) | append (index $day.rooms .name))) }}
|
||||
{{ $rooms = merge $rooms (dict $room.name ((index $rooms $room.name) | append .)) }}
|
||||
{{ else }}
|
||||
{{ $rooms = merge $rooms (dict $room.name (index $day.rooms .name)) }}
|
||||
{{ $rooms = merge $rooms (dict $room.name .) }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
|
Loading…
Reference in New Issue