1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-06-09 01:17:06 +02:00

Executive Dashboard page setup (#5949)

This commit is contained in:
Tymoteusz Czech 2024-01-18 12:32:25 +01:00 committed by GitHub
parent d3215335c9
commit 4b02d6aa9c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
7 changed files with 35 additions and 1 deletions

View File

@ -0,0 +1,5 @@
import { VFC } from 'react';
export const ExecutiveDashboard: VFC = () => {
return <>test</>;
};

View File

@ -426,5 +426,14 @@ exports[`returns all baseRoutes 1`] = `
"title": "Profile", "title": "Profile",
"type": "protected", "type": "protected",
}, },
{
"component": [Function],
"enterprise": true,
"flag": "executiveDashboard",
"menu": {},
"path": "/dashboard",
"title": "Executive dashboard",
"type": "protected",
},
] ]
`; `;

View File

@ -45,6 +45,7 @@ import { FeatureTypesList } from 'component/featureTypes/FeatureTypesList';
import { ViewIntegration } from 'component/integrations/ViewIntegration/ViewIntegration'; import { ViewIntegration } from 'component/integrations/ViewIntegration/ViewIntegration';
import { ApplicationList } from '../application/ApplicationList/ApplicationList'; import { ApplicationList } from '../application/ApplicationList/ApplicationList';
import { AddonRedirect } from 'component/integrations/AddonRedirect/AddonRedirect'; import { AddonRedirect } from 'component/integrations/AddonRedirect/AddonRedirect';
import { ExecutiveDashboard } from 'component/executiveDashboard/ExecutiveDashboard';
export const routes: IRoute[] = [ export const routes: IRoute[] = [
// Splash // Splash
@ -429,6 +430,17 @@ export const routes: IRoute[] = [
menu: {}, menu: {},
}, },
// Executive dashboard
{
path: '/dashboard',
title: 'Executive dashboard',
component: ExecutiveDashboard,
type: 'protected',
menu: {},
flag: 'executiveDashboard',
enterprise: true,
},
/* If you update this route path, make sure you update the path in SWRProvider.tsx */ /* If you update this route path, make sure you update the path in SWRProvider.tsx */
{ {
path: '/login', path: '/login',

View File

@ -75,6 +75,7 @@ export type UiFlags = {
newStrategyConfigurationFeedback?: boolean; newStrategyConfigurationFeedback?: boolean;
extendedUsageMetricsUI?: boolean; extendedUsageMetricsUI?: boolean;
adminTokenKillSwitch?: boolean; adminTokenKillSwitch?: boolean;
executiveDashboard?: boolean;
}; };
export interface IVersionInfo { export interface IVersionInfo {

View File

@ -90,6 +90,7 @@ exports[`should create default config 1`] = `
"embedProxyFrontend": true, "embedProxyFrontend": true,
"enableLicense": false, "enableLicense": false,
"encryptEmails": false, "encryptEmails": false,
"executiveDashboard": false,
"extendedUsageMetrics": false, "extendedUsageMetrics": false,
"extendedUsageMetricsUI": false, "extendedUsageMetricsUI": false,
"featureSearchAPI": false, "featureSearchAPI": false,

View File

@ -44,7 +44,8 @@ export type IFlagKey =
| 'extendedUsageMetrics' | 'extendedUsageMetrics'
| 'extendedUsageMetricsUI' | 'extendedUsageMetricsUI'
| 'adminTokenKillSwitch' | 'adminTokenKillSwitch'
| 'changeRequestConflictHandling'; | 'changeRequestConflictHandling'
| 'executiveDashboard';
export type IFlags = Partial<{ [key in IFlagKey]: boolean | Variant }>; export type IFlags = Partial<{ [key in IFlagKey]: boolean | Variant }>;
@ -203,6 +204,10 @@ const flags: IFlags = {
process.env.UNLEASH_EXPERIMENTAL_CHANGE_REQUEST_CONFLICT_HANDLING, process.env.UNLEASH_EXPERIMENTAL_CHANGE_REQUEST_CONFLICT_HANDLING,
false, false,
), ),
executiveDashboard: parseEnvVarBoolean(
process.env.UNLEASH_EXPERIMENTAL_EXECUTIVE_DASHBOARD,
false,
),
}; };
export const defaultExperimentalOptions: IExperimentalOptions = { export const defaultExperimentalOptions: IExperimentalOptions = {

View File

@ -50,6 +50,7 @@ process.nextTick(async () => {
featureSearchFeedback: true, featureSearchFeedback: true,
newStrategyConfigurationFeedback: true, newStrategyConfigurationFeedback: true,
extendedUsageMetricsUI: true, extendedUsageMetricsUI: true,
executiveDashboard: true,
}, },
}, },
authentication: { authentication: {