From 3c83911f522fa261c8a7d34203e67e8432970f81 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Simon=20B=C3=A4se?= Date: Wed, 25 Dec 2024 00:09:27 +0100 Subject: [PATCH] Fixes for site install --- .../questionnaire/questionnaire.install | 19 ------------------- .../projects/dummy/projects_dummy.info.yml | 1 + 2 files changed, 1 insertion(+), 19 deletions(-) diff --git a/web/modules/custom/academy/questionnaire/questionnaire.install b/web/modules/custom/academy/questionnaire/questionnaire.install index 55e2d927..bb3aa5a1 100644 --- a/web/modules/custom/academy/questionnaire/questionnaire.install +++ b/web/modules/custom/academy/questionnaire/questionnaire.install @@ -11,29 +11,10 @@ use Drupal\Core\Entity\EntityStorageException; use Drupal\Core\Utility\Error; use Drupal\paragraphs\Entity\ParagraphType; -/** - * Implements hook_install(). - */ -function questionnaire_install(): void { - // Add questionnaire target bundle to paragraph reference in lecture entity. - $config = \Drupal::configFactory()->getEditable('field.field.lecture.lecture.paragraphs'); - $current_types = $config->get('settings.handler_settings.target_bundles'); - $current_types['questionnaire'] = 'questionnaire'; - $config->set('settings.handler_settings.target_bundles', $current_types); - $config->save(TRUE); -} - /** * Implements hook_uninstall(). */ function questionnaire_uninstall(): void { - // Remove questionnaire target bundle to paragraph reference in lecture - // entity. - $config = \Drupal::configFactory()->getEditable('field.field.lecture.lecture.paragraphs'); - $current_types = $config->get('settings.handler_settings.target_bundles'); - unset($current_types['questionnaire']); - $config->set('settings.handler_settings.target_bundles', $current_types); - $config->save(TRUE); // Remove config entity for questionnaire paragraph type. try { diff --git a/web/modules/custom/projects/projects/dummy/projects_dummy.info.yml b/web/modules/custom/projects/projects/dummy/projects_dummy.info.yml index 7338d01d..abe074c0 100644 --- a/web/modules/custom/projects/projects/dummy/projects_dummy.info.yml +++ b/web/modules/custom/projects/projects/dummy/projects_dummy.info.yml @@ -6,6 +6,7 @@ package: Projects core_version_requirement: '^10.3 || ^11' dependencies: + - creatives_dummy:creatives_dummy - drupal:file - drupal:user - organizations_dummy:organizations_dummy