Make compatible with Scheduler

Created on 24 October 2020, over 3 years ago
Updated 29 February 2024, 4 months ago

Problem/Motivation

At first I was thinking it would be good to have an auto publishing scheduler for events which offsets the publishing time of each event instance relevant to their individual Start Dates but I then quickly realised that my use case, and probably most other use cases, needs all instances in a series published at the same time, however, there is a need to schedule the publishing of entire series. So making RE compatible with the Scheduler module β†’ would be a very useful feature add. Especially in situations where series' with consecutive and daily recurrences have lots of instances cluttering the space in a site.

✨ Feature request
Status

Needs work

Version

2.0

Component

Recurring Events (Main module)

Created by

πŸ‡¦πŸ‡ΊAustralia the_glitch

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • First commit to issue fork.
  • Status changed to Needs review 4 months ago
  • πŸ‡©πŸ‡°Denmark kasperg

    I took a stab at implementing support for Scheduler for event series.

    I implemented support directly within the main Recurring Events module like it is the case for the integration with Migrate, Views and Fullcalendar. Another approach would be to add a new submodule like group_recurring_events_series which integrates with the Group module. I ended up with this approach as the amount and complexity of the integration is quite limited.

  • πŸ‡©πŸ‡°Denmark kasperg

    It is worth noting that the Scheduler configuration option "Change creation time to match the scheduled publish time" (publish_touch) will not work with event series. It will throw a hard error during cron when an event is to be published.

    The option requires a setCreatedTime() method being available on the scheduled entity. Event series do not provide one at the moment. As I see it there is currently no way to prevent this option from being offered on certain entity types.

  • πŸ‡¨πŸ‡¦Canada endless_wander

    @kasperg this would be a very welcome feature for my client and I would love to help as I can. I will take some time to test your modifications. Let me know if I can do anything else

  • πŸ‡¨πŸ‡¦Canada endless_wander

    @kasperg this isn't working for me. I can set the Scheduler options for my Event Series type and make the fields appear when creating or editing an Event Series. If saving the Event Series with a "Publish on" or "Unpublish on" value, I do not see that value reflected in the EventSeries entity values. There are no "publish_on" or "unpublish_on" values. As a result, re-loading the Event Series editing form shows the "Publish on" and "Unpublish on" fields are blank again. No scheduling occurs. I am using the "default" Event Series type.

    To reproduce, install Devel module and check the entity values on the Devel tab after saving an Event Series with scheduler values. You will see that no publish_on or unpublish_on values are stored.

  • Status changed to Needs work 4 months ago
  • πŸ‡©πŸ‡°Denmark kasperg

    @endless_wanderer: Thanks for taking the time to take a look at this.

    Currently I have the luxury of being able to reinstall our project frequently and the new fields are added here as expected. Given your findings I assume that something needs to be done to add this support to running systems. I expect this to involve an update hook of some kind.

    If someone can point me in the right direction I am willing to take another look at this.

Production build 0.69.0 2024