Two details elements where the first summary is "Daily" with "Start date" and "End date" datetime inputs both with the value "19.11.1978" and "Interval type" radios input with the options "Absolute: Sun, 19. Nov ´78", "Daily", "Weekly: Sun", "Monthly: 19.", "Monthly: 3. Sun" and "Yearly: 19. Nov". The "Daily" option is selected. The second details element is identical but for the summary being "Weekly: Sun" and the "Weekly: Sun" option being selected.
A "Scheduling settings for Article" dialog with the usual "Label", "Help text", "Required field" and "Set default value" inputs. In the "Field Storage" section, in addition to the "Allowed number of values" input, there is an "Enabled intervals" checkboxes element with "Daily", "Weekly", "Monthly", "Monthly, by day of week" and "Yearly" options. At the bottom there are the "Change field type" and "Save" buttons

Allows scheduling content entities either for absolute ranges, for example to have content be published starting at a specific date in the future, or for recurring ranges, for example to have content be published on a specific weekday each week.

For recurring scheduling, content can be scheduled daily, weekly, monthly or yearly. To make this recurring scheduling less daunting for users, you start by selecting a given date range using a date range widget. If the range is applicable for a recurring schedule, you can then optionally select to enable a recurring schedule. For example, if you select a date range of 10am to 2pm on January 1 of a given year, you can then choose if you want to schedule this content daily from 10am to 2pm, on the 1st of every month from 10am to 2pm, etc.

Whether or not content is currently scheduled is checked at runtime, so that no cron job is required for this module, and the scheduling is precise to the second. The access checking is also query-aware and integrates with Drupal's caching API, so that, for example, for a list that will contain a piece of scheduled content in the future, the entire output of the view (without the scheduled content) can be cached until the very second that the content is scheduled at which point it will be recomputed and subsequently cached until the next scheduling change.

Note that Views, in particular, do not currently work with the caching logic, because Views' own cache handling is incompatible with the bubbling of cacheability metadata used elsewhere in core. This will be fixed in the future.

Note that currently the patch from #2352009: Bubbling of elements' max-age to the page's headers and the page cache needs to be applied in order for the core Page Cache to respect the cache max-age of scheduled content or pages that contain scheduled content (or may contain it in the future). Without this patch, content that should be unpublished may still be returned by a cached response, so it is recommended to uninstall Page Cache module if you cannot apply the patch.

Supporting organizations: 
Development

Project information

  • caution Seeking co-maintainer(s)
    Maintainers are looking for help reviewing issues.
  • caution Maintenance fixes only
    Considered feature-complete by its maintainers.
  • Project categories: Access control
  • Created by jan.stoeckler on , updated
  • shieldStable releases for this project are covered by the security advisory policy.
    There are currently no supported stable releases.

Releases