protected function EntityReferenceRevisionsItem::parentIsEnabledEntityType in Multiversion 8
Checks whether parent entity is supported by Multiversion or not.
Return value
bool TRUE if parent entity is supported by Multiversion, FALSE otherwise.
2 calls to EntityReferenceRevisionsItem::parentIsEnabledEntityType()
- EntityReferenceRevisionsItem::postSave in src/
EntityReferenceRevisionsItem.php - Change the logic around revisions handling.
- EntityReferenceRevisionsItem::preSave in src/
EntityReferenceRevisionsItem.php - Change the logic around saving auto-created entities.
File
- src/
EntityReferenceRevisionsItem.php, line 162
Class
- EntityReferenceRevisionsItem
- Alternative entity reference revisions base field item type class.
Namespace
Drupal\multiversionCode
protected function parentIsEnabledEntityType() {
$parent_entity = $this
->getEntity();
$parent_entity_type = $parent_entity
->getEntityType();
if (\Drupal::service('multiversion.manager')
->isEnabledEntityType($parent_entity_type)) {
return TRUE;
}
return FALSE;
}