Hi,
I'm trying to create a page which displays events ordered by date.
Upcoming events should be ordered ascending (so the event tomorrow is listed on the top, the event in 5 days further down) and past events descending (so the very first event ever held is listed at the bottom, but yesterdays event further up).
My current approach is to have all events on their own pages in their own namespace and have their cdate set to the actual date of the event with help of the meta plugin.
With help of the include plugin the page is rendered as I want to have it rendered with this directive:
{{namespace>event&order=created&rsort&link&permalink}}
But of course this doesn't respect to reverse the sort order for upcoming and past events.
The pagequery plugin has the possibility to filter results by date, so I can add two sections:
Next Events: {{pagequery>@event *;filter=cdate:now->}}
Past Events: {{pagequery>@event *;filter=cdate:->now}}
But this doesn't include the page content, only a small more or less unformatted preview snippet is possible.
And I don't see a way neither to have the pagequery plugin including the results nor the include plugin to filter the results by date.
A less hackish approach could be to use the data plugin to define the date of the event instead of abusing the cdate metadata… but the data plugin also doesn't have a way to include the whole pages of the results as far as I know.
Do you have any ideas or hints to a direction that could help me to solve this issue?
Thanks!
jomat