![]() The workflow defines which states can flow to other states. With these modules, you can define arbitrary paths that describe the life cycle of the content on your site.įor example, by default, the Content Moderation module creates the " Editorial" workflow with three states: draft, archived, and published. If you have experimented with the Content Moderation module, you have already discovered that it depends on the Wor k flows module, where the concepts of " Workflow states" and " Transitions" are defined. The Content Moderation module from Drupal core brings some significant changes to the basic functionality we saw above, the most important ones being workflow states and forward revisions. For example, if you need to have your content go through several unpublished (but different) states before it gets published, or when you have a published page, and you need to get modifications on it approved by stakeholders before making them public. The functionalities described above allow some basic control over the publishing status of the content but fall short when sites need to implement more advanced editorial workflows. Increase the complexity with Content Moderation In a standard Drupal setup (i.e., without Content Moderation), once what is loaded in the edit form is the default revision, publishing or unpublishing a node will always affect the default (and also the latest) revision of that content. Out of the box, Drupal content can have a status of "published" or "unpublished." You could modify this behavior by allowing different roles access to unpublished content, but that's the general idea. Publishing statusĪll nodes (and most content entities) in Drupal have a status property that defines whether that particular piece of content should be "publicly visible" or not. Note that without Content Moderation, the default revision will always be the latest revision created. The contents of this new revision will be copied from the past revision you selected to revert to. ![]() The " Revert" action (also referred to as " Roll-back") will generate a new revision and set it to be the new default revision. The reference to which revision is the "default" one is stored in the column vid of the base entity table (for nodes, this means the node table). $node = \Drupal::entityTypeManager->getStorage('node')->load(123)
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |