Module Description
Provides buttons for content moderation, with each button based on configured workflow transitions, instead of a select dropdown of states.

Each transition available for a piece of content in the current workflow state it is in, that the person editing has permission to access given their user role, will be presented as buttons replacing the Save button, the workflow dropdown, and the Publish checkbox. (It is highly recommended to disable previews when using this— a draft state is a better, safer preview!)

Configuration

* Set up your content workflow(s).
* For each content type for which you wish to use buttons, go to Manage form display and change the Moderation state field to use the "Workflow buttons" widget.
* If you do not want the workflow buttons to also appear when viewing the content in particular view modes, then be sure that the "Workflow buttons" pseudo field is not visible by going to Manage display and moving it to the disabled list.

For example, the Find It program locator platform and distribution has nine workflow transitions configured, including a delete-to-trash and restore-from-trash transitions that we use to replace the usual delete button with one that uses workflows to make a soft delete functionality, but at any given moment only three or four can apply, for example for a currently-published piece of content:


* Update (publish changes immediately)
* Save draft (leave current version published)
* Unpublish
* Delete

Note that it replaces the usual save/submit button. (And in this case, it replaces the usual delete button-styled link, simply by not giving people permission to hard ("true") delete.) Nor do we place "Save and" in front of every transition, the way Publishing dropdown buttons does (the module from which this one is forked); if you would like to emphasize that each button on the edit form will in fact save any changes you have made, you can simply rename your transitions to include the word Save.

This approach works best if each transition is non-ambiguous in that it does not need the "Published" checkbox to be used. This may involve configuring more states than one is used to. For instance, you'll need a separate Unpublished state rather than re-using Draft, in order to configure Unpublished state to make itself the default revision, so you always go from Published to Unpublished without creating a new draft instead.

Note that each workflow transition has permissions which are respected by workflow buttons; you can determine which role can perform a content moderation transition (and so which buttons are shown) at /admin/people/permissions/module/content_moderation. Tip: If you wish for a role with greater permissions to not see a basic transition button which regular authenticated users can see but the more privileged role does not need, you can create a role that is treated the same as core's authenticated user role but has the benefit of not having its permissions inherited by other roles. So for example create a "Regular user" role and use Registration role module to autoassign it to all new users. Then give "Regular user" role the permission to, say, "Request publication" while not giving that permission to "Editor" role.

Project Usage
401
Creation Date
Changed Date
Security Covered
Covered By Security Advisory
Version Available
Production
Module Summary
This module aims to provide buttons for content moderation based on configured workflow transitions instead of a select dropdown of states.
Data Name
workflow_buttons

OPENAI CHATBOT

OPENAI CHATBOT

14:37:12
Generic Chatbot
Hi, I'm a Drupal module expert powered by OpenAI, answering your questions about the Drupal module ecosystem. How can I be helpful today? Please note that we will log your question.