Skip to content

Add support for related_pages parameter to the events include#412

Open
sitjart wants to merge 2 commits intoELIXIR-Belgium:mainfrom
sitjart:better-events
Open

Add support for related_pages parameter to the events include#412
sitjart wants to merge 2 commits intoELIXIR-Belgium:mainfrom
sitjart:better-events

Conversation

@sitjart
Copy link
Copy Markdown

@sitjart sitjart commented Mar 27, 2026

Add the related_pages parameter to be able to display events by a filter on any page.

Add the related_pages parameter to be able to display events by a filter on any page.
@sitjart
Copy link
Copy Markdown
Author

sitjart commented Mar 27, 2026

See ELITma for an example of how this would render in practice without affecting previous events pages. This only adds the capability to use a filter to display some events in certain pages
https://elixir-europe-training.github.io/ELIXIR-ELITMa/modules/data-management/

{%- else %}
{%- assign events = site.data.events | sort: "startDate" | reverse %}
{%- assign count = 0 %}
{%- endif %}
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think {%- assign count = 0 %} has to stay if you list both past and future events, no? otherwhise the counter does not get reset I think

@sitjart
Copy link
Copy Markdown
Author

sitjart commented Mar 27, 2026

You're right. I was playing with other things for the 0, and I removed that important part.

udpate error on count 0
@bedroesb bedroesb changed the title Update events.html Add support for related_pages parameter to the events include Mar 30, 2026
@bedroesb
Copy link
Copy Markdown
Member

@sitjart Thanks for this! Could you also add a line describing the parameter on this page: https://elixir-belgium.github.io/elixir-toolkit-theme/events ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants