Section list pages now show pages from all sub-sections
This commit is contained in:
parent
d64874ece6
commit
640bac2dbe
@ -4,28 +4,42 @@
|
|||||||
<div class="title-header">
|
<div class="title-header">
|
||||||
<h1>{{ .Title }}</h1>
|
<h1>{{ .Title }}</h1>
|
||||||
</div>
|
</div>
|
||||||
{{ range .Pages }}
|
{{ if gt (len .Sections) 0 }}
|
||||||
<article class="all-list">
|
<h2>Categories</h2>
|
||||||
<div class="title-list">
|
<ul>
|
||||||
<h2><a href="{{ .RelPermalink }}">{{ if .Draft }}<i>(Draft)</i> {{ end }}{{ .Title }}</a></h2>
|
{{ range .Sections }}
|
||||||
<div class="title-list-date">
|
<li><a href="{{ .RelPermalink }}">{{ .Title }}</a></li>
|
||||||
{{ if eq .Date.IsZero false }}
|
{{ end }}
|
||||||
<time>{{ .Date.Format "Monday, January 2, 2006" }}</time>
|
</ul>
|
||||||
{{ end }}
|
<h2>All Posts</h2>
|
||||||
{{ if (and (eq .Lastmod.IsZero false) (ne .Lastmod .Date)) }}
|
{{ end }}
|
||||||
(updated)
|
{{ $cs := .CurrentSection }}
|
||||||
{{ end }}
|
{{ with $cs }}
|
||||||
</div>
|
{{ range (where .Site.RegularPages "Section" .Section) }}
|
||||||
</div>
|
{{ if .IsDescendant $cs }}
|
||||||
<div class="body-list">
|
<article class="all-list">
|
||||||
<p></p> {{/* Spacing is weird if we don't include this */}}
|
<div class="title-list">
|
||||||
<p>
|
<h3><a href="{{ .RelPermalink }}">{{ if .Draft }}<i>(Draft)</i> {{ end }}{{ .Title }}</a></h3>
|
||||||
{{ .Summary }}
|
<div class="title-list-date">
|
||||||
</p>
|
{{ if eq .Date.IsZero false }}
|
||||||
{{ if .Truncated }}
|
<time>{{ .Date.Format "Monday, January 2, 2006" }}</time>
|
||||||
<a href="{{ .RelPermalink }}">Read More…</a>
|
{{ end }}
|
||||||
|
{{ if (and (eq .Lastmod.IsZero false) (ne .Lastmod .Date)) }}
|
||||||
|
(updated)
|
||||||
{{ end }}
|
{{ end }}
|
||||||
</div>
|
</div>
|
||||||
</article>
|
</div>
|
||||||
|
<div class="body-list">
|
||||||
|
<p></p> {{/* Spacing is weird if we don't include this */}}
|
||||||
|
<p>
|
||||||
|
{{ .Summary }}
|
||||||
|
</p>
|
||||||
|
{{ if .Truncated }}
|
||||||
|
<a href="{{ .RelPermalink }}">Read More…</a>
|
||||||
|
{{ end }}
|
||||||
|
</div>
|
||||||
|
</article>
|
||||||
|
{{ end }}
|
||||||
|
{{ end }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user