From 66642daef258ee0a13d98c92ac8af8265cbbde56 Mon Sep 17 00:00:00 2001 From: Michael Stenta Date: Fri, 12 Aug 2022 08:22:32 -0400 Subject: [PATCH] Make Data Stream Notifications a sub-tab of Notifications (and depend on farm_notification). --- .../data_stream_notification.info.yml | 1 + .../data_stream_notification.links.task.yml | 4 ++-- .../data_stream_notification.post_update.php | 15 +++++++++++++++ 3 files changed, 18 insertions(+), 2 deletions(-) create mode 100644 modules/core/data_stream/modules/notification/data_stream_notification.post_update.php diff --git a/modules/core/data_stream/modules/notification/data_stream_notification.info.yml b/modules/core/data_stream/modules/notification/data_stream_notification.info.yml index 61f78edab..765ad01e4 100644 --- a/modules/core/data_stream/modules/notification/data_stream_notification.info.yml +++ b/modules/core/data_stream/modules/notification/data_stream_notification.info.yml @@ -5,3 +5,4 @@ package: farmOS core_version_requirement: ^9 dependencies: - farm:data_stream + - farm:farm_notification diff --git a/modules/core/data_stream/modules/notification/data_stream_notification.links.task.yml b/modules/core/data_stream/modules/notification/data_stream_notification.links.task.yml index fc5ba4458..8ef158f7b 100644 --- a/modules/core/data_stream/modules/notification/data_stream_notification.links.task.yml +++ b/modules/core/data_stream/modules/notification/data_stream_notification.links.task.yml @@ -1,5 +1,5 @@ data_stream_notification.settings: - base_route: farm_settings.settings_page route_name: entity.data_stream_notification.collection - title: 'Data Stream Notifications' + parent_id: farm_notification.settings + title: 'Data Streams' weight: 10 diff --git a/modules/core/data_stream/modules/notification/data_stream_notification.post_update.php b/modules/core/data_stream/modules/notification/data_stream_notification.post_update.php new file mode 100644 index 000000000..1ad6bfc78 --- /dev/null +++ b/modules/core/data_stream/modules/notification/data_stream_notification.post_update.php @@ -0,0 +1,15 @@ +moduleExists('farm_notification')) { + \Drupal::service('module_installer')->install(['farm_notification']); + } +}