summaryrefslogtreecommitdiff
path: root/app/assets/javascripts/projects/settings/constants.js
blob: 595cbc9c99138b146fc0db75599440a4416c3927 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
import { __ } from '~/locale';

export const LEVEL_TYPES = {
  ROLE: 'role',
  USER: 'user',
  DEPLOY_KEY: 'deploy_key',
  GROUP: 'group',
};

export const LEVEL_ID_PROP = {
  ROLE: 'access_level',
  USER: 'user_id',
  DEPLOY_KEY: 'deploy_key_id',
  GROUP: 'group_id',
};

export const ACCESS_LEVELS = {
  MERGE: 'merge_access_levels',
  PUSH: 'push_access_levels',
  CREATE: 'create_access_levels',
};

export const ACCESS_LEVEL_NONE = 0;

// must match shared_runners_setting in update_service.rb
export const CC_VALIDATION_REQUIRED_ERROR = __(
  'Shared runners enabled cannot be enabled until a valid credit card is on file',
);