Open kreynen opened 2 years ago
Add this to the list of repositories.
{
"type": "package",
"package": {
"name": "drupal/taxonomy_revision_ui",
"type": "drupal-module",
"version": "1.0.0",
"source": {
"type": "git",
"url": "https://git.drupalcode.org/sandbox/hugronaphor-3064521.git",
"reference": "8ecf8c3757cd5f4c2e3dde5ce05bdbb5d2f865e1"
}
}
}
Add this to dependencies...
"drupal/taxonomy_revision_ui": "^1.0"
Add to patches...
"Taxonomy Index for unpublished entities": "https://www.drupal.org/files/issues/2021-02-03/962664-drupal-add-unpublished-nodes-to-taxonomy-index-168.patch",
"Enable Content Moderation integration for taxonomy terms": "https://www.drupal.org/files/issues/2021-07-23/3047110-32.patch"
Manual Steps:
Steps for testing basic Moderation State functionality on terms:
Expected Result: Term title on page
The expected result is a 404
Expected Result: Term title on page
Manual Steps for SHS test:
When there is a published and unpublished term, the expectation is that the CE user wouldn't see the unpublished term in SHS. Instead, the term is displayed as an option, but the validation fails if the CE user tries to save the page with that term selected.
Manual Steps for Webform SHS test:
If you visit the Webform as an Anonymous user first, you will see the expect result. Only the published terms... unless the parent term is unpublished. BUT you will also see that when viewing the Webform as an admin user. If the cache is cleared (twice?) and the form is reloaded as an admin user, the anonymous user will see the unpublished terms.
To replicate this with just SHS, you have to allow anonymous users to create the content type the SHS field is attached to. An unlikely configuration, but it is the endpoint itself that is exposing the unpublished terms.
/shs-term-data/tags/tags/1
[{"tid":"4","name":"Test 3 - Unpublished Draft Level 2","description__value":null,"langcode":"1","hasChildren":false}]
The rc3 update to https://www.drupal.org/project/shs solves part the Draft/Unpublished problem, but additional support for moderation states in the core Taxonomy View handlers will be required to fully support an Archived state.
I opened https://www.drupal.org/project/drupal/issues/3274845 to address the lack of Published or Admin filters in Taxonomy Views.
A basic State of published/unpublished was added to taxonomy terms along with support for revisioning was added to Drupal core with https://www.drupal.org/project/drupal/issues/2880149, but there are still several limitations to using a Content Moderation Workflow with taxonomy terms.
online.cu.edu leverages terms for managing Degree Levels, Programs and Specializations because of the support for hierarchies included included in taxonomy and implemented in modules like https://www.drupal.org/project/webform_shs, but without support for some of the same features content nodes have, working with terms in different states problematic.
We need to create a simpler use case to work though the issues with managing terms in a draft, published and archived states.