Events +

how are repeating events are saved
how are repeating events disabled when one event repeat passes and enabled again for another repetition.
how are evets displayed based on their repetition.
how "Click here to add another date to event" diff parts of events work
are there any hooks available for these events?

  • Vladislav

    Hello,

    All the events are stored as custom post types. The recurring events are a special case, with a "root" event (which will never get showed) - this event is holding the overall recurring and other information, and it's what you edit when you create/edit a recurring event. For each recurrence interval, a separate child instance is also spawned - these are actual event instances that will be displayed to visitors. This allows us robust handling of special-cases, such as rescheduling and specific entry content and such.

    In comparison, regular events are much simpler, including the multiple date ones. They are just regular custom post types, with some meta information stored. Most of the heavy lifting is done by model and collection classes (under lib/ directory), which are also relatively documented,

    As for the hooks, there's quite a few of them. We're using them extensively in our internal add-on system for the plugin, and also added some to allow our members to interact with the plugin the way they needed to. Just listing all of them would take some space and time. Perhaps it would be easier if you said what exactly would you like to do, and I'll give my best to provide some guidance.