public function ExampleEntityExtraFieldInfoSubscribers::fieldInfoAlter in Hook Event Dispatcher 8
Entity extra field info.
Parameters
\Drupal\hook_event_dispatcher\Event\EntityExtra\EntityExtraFieldInfoAlterEvent $event: The event.
File
- src/
Example/ ExampleEntityExtraFieldInfoSubscribers.php, line 52  
Class
- ExampleEntityExtraFieldInfoSubscribers
 - Class ExampleEntityExtraFieldInfoSubscribers.
 
Namespace
Drupal\hook_event_dispatcher\ExampleCode
public function fieldInfoAlter(EntityExtraFieldInfoAlterEvent $event) {
  $fieldInfo =& $event
    ->getFieldInfo();
  // Manipulate the field info.
  $fieldInfo['node']['test']['display']['field_test']['weight'] = -20;
}