Welsh
1
Hi there
In my project I use in the theme a partial for the series, based on .Site.RegularPages.Related
.
I’d like to have the current page in the partial. But .Site.RegularPages.Related
doesn’t include the current page.
An example :
Here Août 1914 (the page for Août 1914) you have Sur le même sujet
which contains
Juillet 1914
Septembre 1914
Octobre 1914
Novembre 1914
Décembre 1914
and I’d like to have the current page :
Juillet 1914
Août 1914
Septembre 1914
Octobre 1914
Novembre 1914
Décembre 1914
The partial code is here : hugo_site/themes/welsh/layouts/partials/related.html · main · Fred GALLOIS / genealogie-docs · GitLab
Have I missed something ?
Thanks in advance
Welsh
Il me semble qu’il faudrait configurer related dans config.toml pour prendre en compte l’année et non serie.
Welsh
3
Hi
Thanks for the reply.
In the config.toml you have 
[related]
includeNewer = true
threshold = 80
toLower = false
[[related.indices]]
name = "serie"
weight = 90
so series
parameter is configured to be the base of related.
It works as I got the list. What I want is the same but with the current page in it…
Welsh
4
Finally I found the explanation in this postt.
You have to append the current page to the collection of related pages.
system
Closed
5
This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.