Skip to content

Commit 08e8bd2

Browse files
Zylphrexandrewshie-sentry
authored andcommitted
feat(explore): Update max pickable days for explore spans (#97922)
This updates the max pickable days for explore spans as follows - orgs with `visibility-explore-range-high` (business/enterprise) get 90 days - all others get 30 days Closes LOGS-300
1 parent c5ae198 commit 08e8bd2

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

static/app/views/explore/utils.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -402,8 +402,8 @@ export function viewSamplesTarget({
402402
});
403403
}
404404

405-
type MaxPickableDays = 7 | 14 | 30;
406-
type DefaultPeriod = '24h' | '7d' | '14d' | '30d';
405+
type MaxPickableDays = 7 | 14 | 30 | 90;
406+
type DefaultPeriod = '24h' | '7d' | '14d' | '30d' | '90d';
407407

408408
export interface PickableDays {
409409
defaultPeriod: DefaultPeriod;
@@ -422,21 +422,21 @@ export function limitMaxPickableDays(organization: Organization): PickableDays {
422422
7: '7d',
423423
14: '14d',
424424
30: '30d',
425+
90: '90d',
425426
};
426427

427428
const relativeOptions: Array<[DefaultPeriod, ReactNode]> = [
428429
['7d', t('Last 7 days')],
429430
['14d', t('Last 14 days')],
430431
['30d', t('Last 30 days')],
432+
['90d', t('Last 90 days')],
431433
];
432434

433435
const maxPickableDays: MaxPickableDays = organization.features.includes(
434436
'visibility-explore-range-high'
435437
)
436-
? 30
437-
: organization.features.includes('visibility-explore-range-medium')
438-
? 14
439-
: 7;
438+
? 90
439+
: 30;
440440
const defaultPeriod: DefaultPeriod = defaultPeriods[maxPickableDays];
441441

442442
const index = relativeOptions.findIndex(([period, _]) => period === defaultPeriod) + 1;

0 commit comments

Comments
 (0)