Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save keithmancuso/99d97755a867db691e708d4410a948cf to your computer and use it in GitHub Desktop.
Save keithmancuso/99d97755a867db691e708d4410a948cf to your computer and use it in GitHub Desktop.
events with repeating?
{% set classIds = craft.calendar.events({ loadOccurrences: false, dateRangeStart: today }).relatedTo( category ).ids() %}
{% for id in classIds %}
{% set event = craft.calendar.event(id, {
occurrenceRangeStart: "today",
occurrenceRangeEnd: "6 months",
occurrenceLimit: 1
}) %}
{% if event.occurrenceCount > 0 or event.startDate > today %}
{{ event.title }}
{% endif %}
{% endfor %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment