Sector workflow doesn't check against content types that have active moderation

Created on 26 September 2023, about 1 year ago
Updated 27 September 2023, about 1 year ago

Problem/Motivation

If we disable content moderation for given Content types, we'd expect to see no trace of moderation when editing the node. Sector workflow doesn't appear to check against that so the "Edit" labels etc are renamed whilst the underlying functionality is still just a standard "Edit".

Steps to reproduce

Disable moderation for a given content type. View or edit a node and the local tasks are still name "Edit draft" etc.

Proposed resolution

Have Sector Workflow check against moderated content types and don't affect those if moderation is disabled.

🐛 Bug report
Status

Fixed

Version

10.0

Component

Code

Created by

🇳🇿New Zealand chroid

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @chroid
  • Status changed to Needs review about 1 year ago
  • 🇳🇿New Zealand dieuwe Auckland, NZ

    The module needs quite a bit of work to be completely up to scratch, so I think a followup ticket will be needed.

    But for now:

    • Remove the optional workflow that came from core's default install profile.
    • Rename the helper class from WorkflowExtrasBase to simply SectorWorkflow (todo: convert this to a proper container class).
    • Check that the node from the route has a moderation state before modifying local menu tabs.
    • Refactor a few bits and pieces, like the use of string translations, a var_dump, and other simple cleanup.
    • dieuwe committed c316dc4a on 10.0.x
      Issue #3389689 by dieuwe, Chroid: Sector workflow doesn't check against...
  • Status changed to Fixed about 1 year ago
  • 🇳🇿New Zealand dieuwe Auckland, NZ
  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024