CGCalendar List Template: prev/next for month AND year?
Posted: Thu Apr 19, 2018 1:36 pm
I have a simple CGCalendar list template (shown below) that lets me navigate months of an event calendar. Now I would like to add prev/next navigation for the year as well. Do you have a tip how to do it without resorting to a separate yearlist template? Maybe it's possible with a js-tweak of the standard Ajax list template?
Any hints are much appreciated
Any hints are much appreciated

Code: Select all
<div class="cal-upcominglist">
<div id="springer">
<span class="calendar-prev"><a href="{$nav.prev_url}"><</a></span><span class="calendar-next"><a href="{$nav.next_url}">></a></span>
<span class="calendar-month">{$start_ts|date_format:'%B %y'}</span>
</div>
{foreach from=$events key=key item=event}
<a href="{$event.url}">
<div class="calendar-event">
<div class="four">
<div class="wochentag">{$event.event_date_start|date_format:"%a"}</div>
<div class="monatstag">{$event.event_date_start|date_format:"%e"}</div>
<div class="monat">{$event.event_date_start|date_format:"%b"}</div>
</div>
<h2>{$event.event_title}</h2>
<div class="calendar-summary">{$event.event_summary}</div>
<div class="calendar-info">{$event.fields.Charakter.field_value} – {$event.fields.Ort.field_value} – {$event.event_date_start|date_format:"%H:%M"}</div>
</div>
</a>
{/foreach}
</div>