public function EntityReferenceFieldFormatter::getFieldValue in Entity Embed 8
Get the field value required to pass into the field formatter.
Return value
mixed The field value.
Overrides FieldFormatterEntityEmbedDisplayBase::getFieldValue
1 call to EntityReferenceFieldFormatter::getFieldValue()
- FileFieldFormatter::getFieldValue in src/
Plugin/ entity_embed/ EntityEmbedDisplay/ FileFieldFormatter.php - Get the field value required to pass into the field formatter.
1 method overrides EntityReferenceFieldFormatter::getFieldValue()
- FileFieldFormatter::getFieldValue in src/
Plugin/ entity_embed/ EntityEmbedDisplay/ FileFieldFormatter.php - Get the field value required to pass into the field formatter.
File
- src/
Plugin/ entity_embed/ EntityEmbedDisplay/ EntityReferenceFieldFormatter.php, line 104
Class
- EntityReferenceFieldFormatter
- Entity Embed Display reusing entity reference field formatters.
Namespace
Drupal\entity_embed\Plugin\entity_embed\EntityEmbedDisplayCode
public function getFieldValue() {
return [
'target_id' => $this
->getContextValue('entity')
->id(),
];
}