Closed langlers closed 5 years ago
@langlers - I could propose adding a unique
flag to the three calendarize methods. This would limit the occurrence to 1.
{% set unique = true %}
{% set entries = craft.calendarize.upcoming({ section: ['events'] }, 'asc|desc', unique) %}
{% set entries = craft.calendarize.after('2019-01-04', { section: ['events'] }, 'asc|desc', unique) %}
{% set entries = craft.calendarize.between('2019-01-01', '2019-01-31', { section: ['events'] }, 'asc|desc', unique) %}
@fvaldes33 Sounds great. I think this will be very useful in, e.g., upcoming event widgets. Thanks for the quick response.
Added in latest commit.
First of all, thanks for a great plugin. I love the upcoming query option, but in a few cases, I need to get a list of unique upcoming events, e.g., with only the next upcoming instance of a repeating event---so that each event entry is listed once in the result set. I don't see a "calendarize" way of doing that. Am I missing something obvious or could this be a candidate for a new feature?