Skip to content
Snippets Groups Projects
Select Git revision
  • 515031-add-member-role-admin-delete-mutation
  • 521163-failed-delete-tasks-might-get-try-to-index-again
  • pedropombeiro/504965/2-replace-ci_runner_machines-with-partitioned-table
  • pedropombeiro/504963/replace-ci_runners-with-partitioned-table
  • el-update-user-member-roles-preloaders
  • vij-remove-group_remove_dormant_members
  • 521264-vue3-migration-devops_adoption_overview_table_spec
  • 519964-group-dependency-path-drawer
  • master default protected
  • 521039/aslota-rename-status-widget-to-verification-status-widget
  • 513321-remove-ff-proj-comp-filter
  • delete-old-feature-flags-zoekt_scheduling_worker
  • michold-replace-license-ci-metric
  • tachyons_service_account_update
  • remove-feature-flag-allow-merge-request-pipelines-from-fork
  • 442091-basic-search
  • 519958-pipeline-inputs-endpoints-1
  • 516183-update-parallel-deployments-documentation-to-explain-more-what-this-feature-is
  • 470699-standards-adhernce-v2-api-aggregated
  • e2e_enable_scan_runner
  • v17.7.6-ee protected
  • v17.8.4-ee protected
  • v17.9.1-ee protected
  • v17.8.3-ee protected
  • v17.7.5-ee protected
  • v17.9.0-ee protected
  • v17.9.0-rc42-ee protected
  • v17.6.5-ee protected
  • v17.7.4-ee protected
  • v17.8.2-ee protected
  • v17.6.4-ee protected
  • v17.7.3-ee protected
  • v17.8.1-ee protected
  • v17.8.0-ee protected
  • v17.7.2-ee protected
  • v17.8.0-rc42-ee protected
  • v17.5.5-ee protected
  • v17.6.3-ee protected
  • v17.7.1-ee protected
  • v17.7.0-ee protected
40 results

constants.js

constants.js 878 B
import { __ } from '~/locale';

export const INVALID_CURRENT_ENVIRONMENT_NAME = '–';

const INTERVALS = {
  minute: 'minute',
  hour: 'hour',
  day: 'day',
};

export const TIME_WINDOWS = {
  thirtyMinutes: {
    name: __('30 minutes'),
    durationInMilliseconds: 30 * 60 * 1000,
    interval: INTERVALS.minute,
  },
  oneHour: {
    name: __('1 hour'),
    durationInMilliseconds: 60 * 60 * 1000,
    interval: INTERVALS.minute,
  },
  twentyFourHours: {
    name: __('24 hours'),
    durationInMilliseconds: 24 * 60 * 60 * 1000,
    interval: INTERVALS.hour,
  },
  sevenDays: {
    name: __('7 days'),
    durationInMilliseconds: 7 * 24 * 60 * 60 * 1000,
    interval: INTERVALS.hour,
  },
  thirtyDays: {
    name: __('30 days'),
    durationInMilliseconds: 30 * 24 * 60 * 60 * 1000,
    interval: INTERVALS.day,
  },
};

export const DEFAULT_TIME_WINDOW = 'thirtyDays';