public function EntityLegalDocumentVersion::getDocument in Entity Legal 3.0.x
Same name and namespace in other branches
- 8.2 src/Entity/EntityLegalDocumentVersion.php \Drupal\entity_legal\Entity\EntityLegalDocumentVersion::getDocument()
- 4.0.x src/Entity/EntityLegalDocumentVersion.php \Drupal\entity_legal\Entity\EntityLegalDocumentVersion::getDocument()
Get attached document entity.
Return value
EntityLegalDocumentInterface The attached document entity.
Overrides EntityLegalDocumentVersionInterface::getDocument
File
- src/
Entity/ EntityLegalDocumentVersion.php, line 185
Class
- EntityLegalDocumentVersion
- Defines the entity legal document version entity.
Namespace
Drupal\entity_legal\EntityCode
public function getDocument() {
return \Drupal::entityTypeManager()
->getStorage(ENTITY_LEGAL_DOCUMENT_ENTITY_NAME)
->load($this
->bundle());
}