Skip to content

Commit

Permalink
fix esQuery registration view in app
Browse files Browse the repository at this point in the history
  • Loading branch information
XavierM committed Sep 21, 2023
1 parent a6babf2 commit 4bf2089
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions x-pack/plugins/stack_alerts/public/rule_types/es_query/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,4 +59,20 @@ function registerNavigation(alerting: AlertingSetup) {
return;
}
);
alerting.registerNavigation(
'logs',
ES_QUERY_ID,
(rule: SanitizedRule<EsQueryRuleParams<SearchType.searchSource>>) => {
if (isSearchSourceRule(rule.params)) return `/app/discover#/viewAlert/${rule.id}`;
return;
}
);
alerting.registerNavigation(
'infrastructure',
ES_QUERY_ID,
(rule: SanitizedRule<EsQueryRuleParams<SearchType.searchSource>>) => {
if (isSearchSourceRule(rule.params)) return `/app/discover#/viewAlert/${rule.id}`;
return;
}
);
}

0 comments on commit 4bf2089

Please sign in to comment.