File tree 1 file changed +8
-1
lines changed
static/app/views/detectors
1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -16,9 +16,11 @@ import {IconArrow, IconEdit} from 'sentry/icons';
16
16
import { t } from 'sentry/locale' ;
17
17
import { space } from 'sentry/styles/space' ;
18
18
import getDuration from 'sentry/utils/duration/getDuration' ;
19
+ import { useParams } from 'sentry/utils/useParams' ;
19
20
import { ConnectedAutomationsList } from 'sentry/views/detectors/components/connectedAutomationList' ;
20
21
import DetailsPanel from 'sentry/views/detectors/components/detailsPanel' ;
21
22
import IssuesList from 'sentry/views/detectors/components/issuesList' ;
23
+ import { useDetectorQuery } from 'sentry/views/detectors/hooks' ;
22
24
23
25
type Priority = {
24
26
sensitivity : string ;
@@ -32,9 +34,14 @@ const priorities: Priority[] = [
32
34
33
35
export default function DetectorDetail ( ) {
34
36
useWorkflowEngineFeatureGate ( { redirect : true } ) ;
37
+ const { detectorId} = useParams ( ) ;
38
+ if ( ! detectorId ) {
39
+ throw new Error ( `Unable to find detector.` ) ;
40
+ }
41
+ const { data : detector } = useDetectorQuery ( detectorId ) ;
35
42
36
43
return (
37
- < SentryDocumentTitle title = { '/endpoint' } noSuffix >
44
+ < SentryDocumentTitle title = { detector . id } noSuffix >
38
45
< BreadcrumbsProvider crumb = { { label : t ( 'Monitors' ) , to : '/issues/monitors' } } >
39
46
< ActionsProvider actions = { < Actions /> } >
40
47
< DetailLayout project = { { slug : 'project-slug' , platform : 'javascript-astro' } } >
You can’t perform that action at this time.
0 commit comments