function ModerationInformation::getUnsupportedFeatures
Same name in other branches
- 9 core/modules/content_moderation/src/ModerationInformation.php \Drupal\content_moderation\ModerationInformation::getUnsupportedFeatures()
- 8.9.x core/modules/content_moderation/src/ModerationInformation.php \Drupal\content_moderation\ModerationInformation::getUnsupportedFeatures()
- 10 core/modules/content_moderation/src/ModerationInformation.php \Drupal\content_moderation\ModerationInformation::getUnsupportedFeatures()
File
-
core/
modules/ content_moderation/ src/ ModerationInformation.php, line 202
Class
- ModerationInformation
- General service for moderation-related questions about Entity API.
Namespace
Drupal\content_moderationCode
public function getUnsupportedFeatures(EntityTypeInterface $entity_type) {
$features = [];
// Test if entity is publishable.
if (!$entity_type->entityClassImplements(EntityPublishedInterface::class)) {
$features['publishing'] = $this->t("@entity_type_plural_label do not support publishing statuses. For example, even after transitioning from a published workflow state to an unpublished workflow state they will still be visible to site visitors.", [
'@entity_type_plural_label' => $entity_type->getCollectionLabel(),
]);
}
return $features;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.