Skip to content

Commit

Permalink
add data warehouse type
Browse files Browse the repository at this point in the history
  • Loading branch information
EDsCODE committed Mar 20, 2024
1 parent 4ca3c29 commit 470a208
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions frontend/src/scenes/experiments/MetricSelector.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,10 @@ import { IconInfo } from '@posthog/icons'
import { LemonSelect } from '@posthog/lemon-ui'
import { BindLogic, useActions, useValues } from 'kea'
import { TaxonomicFilterGroupType } from 'lib/components/TaxonomicFilter/types'
import { FEATURE_FLAGS } from 'lib/constants'
import { LemonBanner } from 'lib/lemon-ui/LemonBanner'
import { Tooltip } from 'lib/lemon-ui/Tooltip'
import { featureFlagLogic } from 'lib/logic/featureFlagLogic'
import { Attribution } from 'scenes/insights/EditorFilters/AttributionFilter'
import { SamplingFilter } from 'scenes/insights/EditorFilters/SamplingFilter'
import { ActionFilter } from 'scenes/insights/filters/ActionFilter/ActionFilter'
Expand Down Expand Up @@ -90,6 +92,8 @@ export function MetricSelector({
}

export function ExperimentInsightCreator({ insightProps }: { insightProps: InsightLogicProps }): JSX.Element {
const { featureFlags } = useValues(featureFlagLogic)

// insightVizDataLogic
const { isTrends, series, querySource } = useValues(insightVizDataLogic(insightProps))
const { updateQuerySource } = useActions(insightVizDataLogic(insightProps))
Expand Down Expand Up @@ -131,6 +135,15 @@ export function ExperimentInsightCreator({ insightProps }: { insightProps: Insig
TaxonomicFilterGroupType.Elements,
TaxonomicFilterGroupType.HogQLExpression,
]}
actionsTaxonomicGroupTypes={
featureFlags[FEATURE_FLAGS.DATA_WAREHOUSE] && featureFlags[FEATURE_FLAGS.HOGQL_INSIGHTS_TRENDS]
? [
TaxonomicFilterGroupType.Events,
TaxonomicFilterGroupType.Actions,
TaxonomicFilterGroupType.DataWarehouse,
]
: [TaxonomicFilterGroupType.Events, TaxonomicFilterGroupType.Actions]
}
/>
<div className="mt-4 space-y-4">
{!isTrends && (
Expand Down

0 comments on commit 470a208

Please sign in to comment.