protected function DepCalcExcludeLingotekContentMetadataSubscriber::includeField in Lingotek Translation 3.7.x
Same name and namespace in other branches
- 4.0.x src/EventSubscriber/DepCalcExcludeLingotekContentMetadataSubscriber.php \Drupal\lingotek\EventSubscriber\DepCalcExcludeLingotekContentMetadataSubscriber::includeField()
- 3.6.x src/EventSubscriber/DepCalcExcludeLingotekContentMetadataSubscriber.php \Drupal\lingotek\EventSubscriber\DepCalcExcludeLingotekContentMetadataSubscriber::includeField()
- 3.8.x src/EventSubscriber/DepCalcExcludeLingotekContentMetadataSubscriber.php \Drupal\lingotek\EventSubscriber\DepCalcExcludeLingotekContentMetadataSubscriber::includeField()
Whether we should include this field in the dependency calculation.
Parameters
\Drupal\Core\Field\FieldItemListInterface $field: The entity field.
Return value
bool TRUE if we should include the field, FALSE otherwise.
1 call to DepCalcExcludeLingotekContentMetadataSubscriber::includeField()
- DepCalcExcludeLingotekContentMetadataSubscriber::onFilterFields in src/
EventSubscriber/ DepCalcExcludeLingotekContentMetadataSubscriber.php - Filter fields.
File
- src/
EventSubscriber/ DepCalcExcludeLingotekContentMetadataSubscriber.php, line 46
Class
Namespace
Drupal\lingotek\EventSubscriberCode
protected function includeField(FieldItemListInterface $field) {
$definition = $field
->getFieldDefinition();
if ($definition
->getType() === 'entity_reference' && $field
->getSetting('target_type') === 'lingotek_content_metadata') {
return FALSE;
}
return TRUE;
}