Skip to main content
Drupal is a registered trademark of Dries Buytaert
Release: OpenID Connect / OAuth client 3.0.0-alpha9 New alpha version released for module openid_connect (3.0.0-alpha9). Release: Opensolr Search 4.5.0 Minor update available for module opensolr_search (4.5.0). Release: Timelinr 1.0.1 Minor update available for module timelinr (1.0.1). Usage Milestone: Simplify Module simplify crossed 10,000 active installs. Usage Milestone: Views Reference Filter Module entityreference_filter crossed 10,000 active installs. Usage Milestone: Dropdown Language Module dropdown_language crossed 10,000 active installs. Usage Milestone: Paragraphs Browser Module paragraphs_browser crossed 10,000 active installs. Usage Milestone: OpenAPI Module openapi crossed 10,000 active installs. Usage Milestone: Decoupled Router Module decoupled_router crossed 10,000 active installs. Module Revived: Entityqueue Buttons 1.1.2 Module entityqueue_buttons updated after 8 months of inactivity (1.1.2).

This module allows you to sort content by its moderation state in Drupal Views. It exposes moderation state weight information to Views, enabling custom ordering of content based on the defined workflow. This is useful for displaying content in a specific, user-defined order within your site's moderation processes.

Introduction

Out of the box, Drupal's content moderation module does not expose moderation state weight information to Views. This module provides field and sort handlers to facilitate this functionality.

This module can be used if you need to display Views results sorted by moderation state, but in a specific user-defined order. Simply set the order in which you want states to appear in the content moderation workflow configuration, then add the "Moderation state weight" sort criteria to your View.

How it works

Since Views sorts are executed by the database, moderation state weight information needs to be easily accessible from the database. Upon installation, this module creates a table containing moderation state weight information for each content moderation workflow. Each time a content moderation workflow is updated, the database table is also updated.

When adding one of the Views handlers provided by this module to a View, the handler will automatically join the moderation state weight table in the database, which allows the database to order the result set by moderation state weight.

Internal API usage

To fulfill the functionality delivered by this module, we rely on parts of Drupal that are likely considered to be part of its internal API; specifically, the content_moderation_state entity type and any related database structure and machine names. However, the risk should be minimal since we believe a backward incompatible change is unlikely.

Depends on

Dependencies of the latest stable release

  • content_moderation Drupal core
  • views Drupal core
  • workflows Drupal core

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
1
Tracked since
Feb 2025
Latest release
1 year ago
Releases (12 mo)
0 ▼ from 1
Maintenance
Dormant

Releases

Version Type Core Release date
1.1.1 Stable 10–11 Feb 10, 2025