Blogs

EMAIL: info@example.com

Specbee: Managing Editorial Workflows with the Content Moderation Module in Drupal 9

Managing Editorial Workflows with the Content Moderation Module in Drupal 9
Shefali Shetty
16 Feb, 2021

A good content management system should not only focus on the way your content is presented to the user. It should give you the flexibility to manage the content publishing workflow smoothly and effectively. Many times, teams must work together with the content teams to churn out content regularly. Without a structured editorial workflow, where content moves from one state to the other, managing a publication process becomes tedious and chaotic. Enter the Content Moderation module for Drupal 9.

The Drupal 9 Content Moderation module gives complete flexibility to content editors and marketing teams to manage their editorial workflows effortlessly. The module works in conjunction with the Workflows module to manage and create different workflow states and transitions. The Content Moderation module was first introduced to Drupal 8 as an experimental module in Drupal 8.2. It was based on the contributed “Workbench Moderation” module. With Drupal 8.5, a stable version was released and is now a Drupal core module! On a sidenote, did you know that 88% of the top 1000 Drupal projects are now Drupal 9 compatible? If you’re still on Drupal 8 (or 7), what are you waiting for? Migrate to Drupal 9 today!
Content Moderation

What can you do with the Drupal Content Moderation Module?

Here’s why you should be implementing this amazing module for all your content workflow needs:

You can have different states for your content workflow – Draft, Published, Archived (much improved from the previously Published and Unpublished states).
Create and add your own state to the list! It could be a Needs Work, a Ready to publish, or any state that is required by your business process and editorial workflow.
When you create your own state (or edit an existing one), you can choose if you want to publish the content soon after entering that particular state. Or/and you could also choose to make it as the default revision.
You can create a transition to define what to do when the content moves from one state to another. 
It allows for granular permission control for every state and transition.
You can select the content types that you want to apply the workflow to (Article or Basic page by default).
In addition to the default editorial workflow, you can create your own customized workflow too!

Implementing the Content Moderation Module

As previously discussed, the Drupal Content Moderation module is available in core (since Drupal 8.5). However, you will need to enable the module by navigating to /admin/modules. Next, click on Install. 
Content Moderation

Enabling the Content Moderation Module

Once the module has been enabled, go to Configuration -> Workflow -> Workflows. Here you will be able to see a default workflow called “Editorial”. Or if you have added multiple workflows, you can see a list of them in this page. Click on Edit to make changes to the existing workflow.
Default Workflow

Editing the default Workflow

Label: You can add or modify the name of the workflow.
States: By default, there are three states – Draft, Published and Archived. You can click on the “Add a new state” button to create your own state like “Needs Work” or “Needs a Second Review”.
Adding a New State

Adding a new state – Needs Work

Transitions: Transitions tell the content editors what to do after a change of state. In addition to the pre-existing transitions like “Create New Draft”, “Publish”, “Archive”, etc., you can also create your own transition to handle more complex workflows. For example, if you have just created a new state for “Needs Work”, you could support this state by adding a transition called “Move to Needs Work” from a “Draft” state to “Needs Work” state.
Adding a New Transition

Adding a new Transition

This Workflow Applies To: You can choose to apply this workflow to your custom block types (Basic blocks) and content types (Article and Basic page).

Custom Block Types            Content Types

 

 

Workflow Settings: When you create new content, you can choose to default a state in the form. By default, the state is always “Draft”.

Track it with Content Revisions

Now with all of this information, you know that your marketing and/or content team can create and move content from one state to another effectively with the Content Moderation module. But how would you know who made that change, when did they make it or was it even made? Yes, content revisions to the rescue! With the revisions feature in the content moderation Drupal 9 module, you can not only see who made the changes and why, you can also revert to the previous changes (if there are more than one revision).
Content Revisions

Content Revisions

Access Control with Permissions

Having a content workflow and moderation system for a one-person team or a team where each member has admin privileges, is never a great idea. The permissions and access control feature for the Drupal 9 content moderation module gives granular control to a team of multiple content authors and editors. For example, you would want only a content author and editor to be able to use the Create New Draft transition. While a content editor can be the only one to be permitted to use the Publish transition.

To setup permissions for different users, navigate to People -> Permissions.
Permissions 

Shefali ShettyApr 05, 2017