2019-09-04 21:01:54 +05:30
|
|
|
import invalidUrl from '~/lib/utils/invalid_url';
|
2020-06-23 00:09:42 +05:30
|
|
|
import { timezones } from '../format_date';
|
2019-09-04 21:01:54 +05:30
|
|
|
|
|
|
|
export default () => ({
|
2020-03-13 15:44:24 +05:30
|
|
|
// API endpoints
|
2019-09-04 21:01:54 +05:30
|
|
|
deploymentsEndpoint: null,
|
|
|
|
dashboardEndpoint: invalidUrl,
|
2020-06-23 00:09:42 +05:30
|
|
|
dashboardsEndpoint: invalidUrl,
|
2020-03-13 15:44:24 +05:30
|
|
|
|
|
|
|
// Dashboard request parameters
|
|
|
|
timeRange: null,
|
|
|
|
currentDashboard: null,
|
|
|
|
|
|
|
|
// Dashboard data
|
2019-09-04 21:01:54 +05:30
|
|
|
emptyState: 'gettingStarted',
|
|
|
|
showEmptyState: true,
|
2019-10-12 21:52:04 +05:30
|
|
|
showErrorBanner: true,
|
2020-05-24 23:13:21 +05:30
|
|
|
isUpdatingStarredValue: false,
|
2019-12-26 22:10:19 +05:30
|
|
|
dashboard: {
|
2020-04-08 14:13:33 +05:30
|
|
|
panelGroups: [],
|
2019-12-26 22:10:19 +05:30
|
|
|
},
|
2020-05-24 23:13:21 +05:30
|
|
|
/**
|
|
|
|
* Panel that is currently "zoomed" in as
|
|
|
|
* a single panel in view.
|
|
|
|
*/
|
|
|
|
expandedPanel: {
|
|
|
|
/**
|
|
|
|
* {?String} Panel's group name.
|
|
|
|
*/
|
|
|
|
group: null,
|
|
|
|
/**
|
|
|
|
* {?Object} Panel content from `dashboard`
|
|
|
|
* null when no panel is expanded.
|
|
|
|
*/
|
|
|
|
panel: null,
|
|
|
|
},
|
2020-03-13 15:44:24 +05:30
|
|
|
allDashboards: [],
|
2020-06-23 00:09:42 +05:30
|
|
|
/**
|
|
|
|
* User-defined custom variables are passed
|
|
|
|
* via the dashboard yml file.
|
|
|
|
*/
|
|
|
|
variables: {},
|
|
|
|
/**
|
|
|
|
* User-defined custom links are passed
|
|
|
|
* via the dashboard yml file.
|
|
|
|
*/
|
|
|
|
links: [],
|
2020-03-13 15:44:24 +05:30
|
|
|
// Other project data
|
2020-06-23 00:09:42 +05:30
|
|
|
dashboardTimezone: timezones.LOCAL,
|
2020-04-22 19:07:51 +05:30
|
|
|
annotations: [],
|
2019-09-04 21:01:54 +05:30
|
|
|
deploymentData: [],
|
|
|
|
environments: [],
|
2020-03-13 15:44:24 +05:30
|
|
|
environmentsSearchTerm: '',
|
|
|
|
environmentsLoading: false,
|
2020-06-23 00:09:42 +05:30
|
|
|
currentEnvironmentName: null,
|
2020-03-13 15:44:24 +05:30
|
|
|
|
|
|
|
// GitLab paths to other pages
|
2019-09-30 21:07:59 +05:30
|
|
|
projectPath: null,
|
2020-03-13 15:44:24 +05:30
|
|
|
logsPath: invalidUrl,
|
2019-09-04 21:01:54 +05:30
|
|
|
});
|