Add form #state to force "Default revision" on when "Published" is checked for a new moderation state

Created on 17 May 2018, over 6 years ago
Updated 7 April 2023, over 1 year ago

Problem/Motivation

Lets resolve a @todo as old as time itself. Equivalent issue in the WBM queue: #2645614: Add form #state to force "make default" on when "published" is on for a state β†’ .

Currently you can create a state which is published but not default. Nothing prevents this and the comment "this is implied for published states" isn't actually true. Pending revisions can be created which are published, they are just confusing.

Proposed resolution

Resolve the todo and add validation to ensure published is always accompanied by default.

Remaining tasks

User interface changes

API changes

Data model changes

πŸ“Œ Task
Status

Needs work

Version

10.1 ✨

Component
Content moderationΒ  β†’

Last updated 1 day ago

  • Maintained by
  • πŸ‡¦πŸ‡ΊAustralia @Sam152
Created by

πŸ‡¦πŸ‡ΊAustralia Sam152

Live updates comments and jobs are added and updated live.
  • Needs change record

    A change record needs to be drafted before an issue is committed. Note: Change records used to be called change notifications.

  • Needs release note

    The major change should have a special release note written to summarize the importance of the change. See Write a release note for an issue.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡ΊπŸ‡ΈUnited States smustgrave

    Triggering D10.1 tests.

  • Status changed to RTBC almost 2 years ago
  • πŸ‡ΊπŸ‡ΈUnited States smustgrave

    This issue is being reviewed by the kind folks in Slack, #needs-review-queue-initiative. We are working to keep the size of Needs Review queue [2700+ issues] to around 400 (1 month or less), following Review a patch or merge request β†’ as a guide.

    All green #12 so reviewing now

    Tested manually by trying to create a workflow state. When I checked "published" "default" was auto checked.

    Unchecked default and tried to save and got an error.

    Ran test locally without fix to make sure it passes and got

    Behat\Mink\Exception\ResponseTextException : The text "Published states should always be the default revision." was not found anywhere in the text of the current page.
    

    Great work!

  • Status changed to Needs review over 1 year ago
  • πŸ‡¬πŸ‡§United Kingdom catch

    This doesn't cover existing configuration, is that just going to get force-updated when someone saves the form? At a minimum needs a change record and release note, but I'm not really sure it's such a problem if forward revisions are published - i.e. this is what workspaces relies on.

  • Status changed to Needs work over 1 year ago
  • πŸ‡ΊπŸ‡ΈUnited States smustgrave

    Moving to NW for the change record.

Production build 0.71.5 2024