public function ReferenceablePluginTypesSubscriber::onPluginTypes in Commerce Shipping 8.2
Registers the 'commerce_shipping_method' plugin type as referenceable.
Parameters
\Drupal\commerce\Event\ReferenceablePluginTypesEvent $event: The event.
File
- src/
EventSubscriber/ ReferenceablePluginTypesSubscriber.php, line 28
Class
Namespace
Drupal\commerce_shipping\EventSubscriberCode
public function onPluginTypes(ReferenceablePluginTypesEvent $event) {
$plugin_types = $event
->getPluginTypes();
$plugin_types['commerce_shipping_method'] = $this
->t('Shipping method');
$event
->setPluginTypes($plugin_types);
}