Add an Event bundle class

This commit is contained in:
Oliver Davies 2025-06-12 02:10:08 +01:00
parent f56eb931c2
commit 14cd79a960
6 changed files with 49 additions and 14 deletions

View file

@ -2,6 +2,7 @@
declare(strict_types=1);
use Drupal\opd_presentations\Entity\Event;
use Drupal\opd_presentations\Entity\Presentation;
/**
@ -13,4 +14,8 @@ function opd_presentations_entity_bundle_info_alter(array &$bundles): void {
if (isset($bundles['node'])) {
$bundles['node']['presentation']['class'] = Presentation::class;
}
if (isset($bundles['paragraph'])) {
$bundles['paragraph'][Event::PARAGRAPH_TYPE]['class'] = Event::class;
}
}