From 6559bfbc71186f599713c4c732822b091d49109a Mon Sep 17 00:00:00 2001 From: Coen Warmer Date: Mon, 5 Sep 2022 14:32:22 +0200 Subject: [PATCH] [Actionable Observability] Update links to Observability rule management (#140009) * [Actionable Observability] Update links to Observability rule management * Use path config file for links --- .../public/components/app/observability_status/content.ts | 3 ++- .../observability/public/pages/overview/empty_section.ts | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/x-pack/plugins/observability/public/components/app/observability_status/content.ts b/x-pack/plugins/observability/public/components/app/observability_status/content.ts index 6ab022ef81bba..319c701fd96c2 100644 --- a/x-pack/plugins/observability/public/components/app/observability_status/content.ts +++ b/x-pack/plugins/observability/public/components/app/observability_status/content.ts @@ -7,6 +7,7 @@ import { i18n } from '@kbn/i18n'; import { HttpSetup, DocLinksStart } from '@kbn/core/public'; import { ObservabilityFetchDataPlugins } from '../../../typings/fetch_overview_data'; +import { paths } from '../../../config/paths'; export interface ObservabilityStatusContent { id: ObservabilityFetchDataPlugins | 'alert'; @@ -135,7 +136,7 @@ export const getContent = ( addTitle: i18n.translate('xpack.observability.statusVisualization.alert.link', { defaultMessage: 'Create rules', }), - addLink: http.basePath.prepend('/app/management/insightsAndAlerting/triggersActions/rules'), + addLink: http.basePath.prepend(paths.observability.rules), learnMoreLink: docLinks.links.observability.createAlerts, goToAppTitle: i18n.translate('xpack.observability.statusVisualization.alert.goToAppTitle', { defaultMessage: 'Show alerts', diff --git a/x-pack/plugins/observability/public/pages/overview/empty_section.ts b/x-pack/plugins/observability/public/pages/overview/empty_section.ts index 9e74ec482f50d..78db690cd5c0d 100644 --- a/x-pack/plugins/observability/public/pages/overview/empty_section.ts +++ b/x-pack/plugins/observability/public/pages/overview/empty_section.ts @@ -8,6 +8,7 @@ import { i18n } from '@kbn/i18n'; import { HttpSetup } from '@kbn/core/public'; import { ISection } from '../../typings/section'; +import { paths } from '../../config/paths'; export const getEmptySections = ({ http }: { http: HttpSetup }): ISection[] => { return [ @@ -97,7 +98,7 @@ export const getEmptySections = ({ http }: { http: HttpSetup }): ISection[] => { linkTitle: i18n.translate('xpack.observability.emptySection.apps.alert.link', { defaultMessage: 'Create rule', }), - href: http.basePath.prepend('/app/management/insightsAndAlerting/triggersActions/alerts'), + href: http.basePath.prepend(paths.observability.rules), }, ]; };