node to page: Handle taxonomies on home page etc.

Updates #2297
This commit is contained in:
Bjørn Erik Pedersen
2016-11-09 20:55:42 +01:00
parent d3d3863c05
commit ecedc85cb7
2 changed files with 64 additions and 35 deletions

View File

@@ -1340,8 +1340,6 @@ func (s *Site) buildSiteMeta() (err error) {
return
}
// TODO(bep) np order
// assembleTaxonomies: Needs pages (temp lookup) (maybe later nodes)
s.assembleTaxonomies()
// TODO(bep) np
@@ -1497,8 +1495,8 @@ func (s *Site) assembleTaxonomies() {
for singular, plural := range taxonomies {
s.Taxonomies[plural] = make(Taxonomy)
s.taxonomiesPluralSingular[plural] = singular
// TODO(np) tax other nodes
for _, p := range s.findPagesByNodeType(NodePage) {
for _, p := range s.Nodes {
vals := p.getParam(plural, !s.Info.preserveTaxonomyNames)
weight := p.GetParam(plural + "_weight")
if weight == nil {