From d7db7423b25cb16969ab46caaf43ced9d859d630 Mon Sep 17 00:00:00 2001 From: Tyler Ohlsen Date: Mon, 3 Jul 2023 09:04:41 -0700 Subject: [PATCH] Change to anomaly start time; add test ids Signed-off-by: Tyler Ohlsen --- .../containers/AssociatedDetectors.tsx | 1 + .../CreateAnomalyDetector/AddAnomalyDetector.tsx | 8 ++++---- .../EnhancedAccordion/EnhancedAccordion.tsx | 1 + public/expressions/helpers.ts | 2 +- public/pages/DetectorConfig/containers/Features.tsx | 1 + 5 files changed, 8 insertions(+), 5 deletions(-) diff --git a/public/components/FeatureAnywhereContextMenu/AssociatedDetectors/containers/AssociatedDetectors.tsx b/public/components/FeatureAnywhereContextMenu/AssociatedDetectors/containers/AssociatedDetectors.tsx index 004c81d1..aaaed5dc 100644 --- a/public/components/FeatureAnywhereContextMenu/AssociatedDetectors/containers/AssociatedDetectors.tsx +++ b/public/components/FeatureAnywhereContextMenu/AssociatedDetectors/containers/AssociatedDetectors.tsx @@ -308,6 +308,7 @@ function AssociatedDetectors({ embeddable, closeFlyout, setMode }) {
{ diff --git a/public/components/FeatureAnywhereContextMenu/CreateAnomalyDetector/AddAnomalyDetector.tsx b/public/components/FeatureAnywhereContextMenu/CreateAnomalyDetector/AddAnomalyDetector.tsx index f55cc9b0..bea4cb76 100644 --- a/public/components/FeatureAnywhereContextMenu/CreateAnomalyDetector/AddAnomalyDetector.tsx +++ b/public/components/FeatureAnywhereContextMenu/CreateAnomalyDetector/AddAnomalyDetector.tsx @@ -566,7 +566,7 @@ function AddAnomalyDetector({ onAccordionToggle('detectorDetails')} @@ -671,7 +671,7 @@ function AddAnomalyDetector({ @@ -824,7 +824,7 @@ function AddAnomalyDetector({ onAccordionToggle('modelFeatures')} @@ -896,7 +896,7 @@ function AddAnomalyDetector({ {mode === FLYOUT_MODES.existing ? ( handleAssociate(selectedDetector)} > diff --git a/public/components/FeatureAnywhereContextMenu/EnhancedAccordion/EnhancedAccordion.tsx b/public/components/FeatureAnywhereContextMenu/EnhancedAccordion/EnhancedAccordion.tsx index 17075e27..b129bc20 100644 --- a/public/components/FeatureAnywhereContextMenu/EnhancedAccordion/EnhancedAccordion.tsx +++ b/public/components/FeatureAnywhereContextMenu/EnhancedAccordion/EnhancedAccordion.tsx @@ -51,6 +51,7 @@ const EnhancedAccordion = ({ buttonContent={
{ const events = anomalies.map((anomaly: AnomalyData) => { return { - timestamp: anomaly.startTime + (anomaly.endTime - anomaly.startTime) / 2, + timestamp: anomaly.startTime, metadata: {}, }; }); diff --git a/public/pages/DetectorConfig/containers/Features.tsx b/public/pages/DetectorConfig/containers/Features.tsx index d5b8e455..9cdb609d 100644 --- a/public/pages/DetectorConfig/containers/Features.tsx +++ b/public/pages/DetectorConfig/containers/Features.tsx @@ -234,6 +234,7 @@ export const Features = (props: FeaturesProps) => { titleSize="s" >