public function GroupEventDeriver::getDerivativeDefinitions in Event 8
.
Overrides DeriverBase::getDerivativeDefinitions
File
- modules/
gevent/ src/ Plugin/ GroupContentEnabler/ GroupEventDeriver.php, line 13
Class
Namespace
Drupal\gevent\Plugin\GroupContentEnablerCode
public function getDerivativeDefinitions($base_plugin_definition) {
foreach (EventType::loadMultiple() as $name => $event_type) {
$label = $event_type
->label();
$this->derivatives[$name] = [
'entity_bundle' => $name,
'label' => t('Group event (@type)', [
'@type' => $label,
]),
'description' => t('Adds %type content to groups both publicly and privately.', [
'%type' => $label,
]),
] + $base_plugin_definition;
}
return $this->derivatives;
}