Code Coverage |
||||||||||||||||
Lines |
Branches |
Paths |
Functions and Methods |
Classes and Traits |
||||||||||||
| Total | |
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
CRAP | |
0.00% |
0 / 1 |
| DisplayBuilderUiHooks | |
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
2 | |
0.00% |
0 / 1 |
| entityTypeAlter | |
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
2 | |||
| 1 | <?php |
| 2 | |
| 3 | declare(strict_types=1); |
| 4 | |
| 5 | namespace Drupal\display_builder_ui\Hook; |
| 6 | |
| 7 | use Drupal\Core\Hook\Attribute\Hook; |
| 8 | |
| 9 | /** |
| 10 | * Hook implementations for display_builder_ui. |
| 11 | */ |
| 12 | class DisplayBuilderUiHooks { |
| 13 | |
| 14 | /** |
| 15 | * Alter the entity type definitions. |
| 16 | * |
| 17 | * @param \Drupal\Core\Entity\EntityTypeInterface[] $entity_types |
| 18 | * Entity types definitions. |
| 19 | */ |
| 20 | #[Hook('entity_type_alter')] |
| 21 | public function entityTypeAlter(array &$entity_types): void { |
| 22 | $entity_types['pattern_preset']->setLinkTemplate('edit-form', '/admin/structure/display-builder/preset/{pattern_preset}'); |
| 23 | } |
| 24 | |
| 25 | } |