feat(settings): Added feature toggling. (TV-564)
Squashed commit of the following: commit b67cced3bd44d1673173e5fa188d776d2d097fd4 Author: Erik Tiekstra <erik.tiekstra@arbetsformedlingen.se> Date: Fri Sep 10 11:59:37 2021 +0200 Added feature toggling for routes and navigation
This commit is contained in:
12
apps/mina-sidor-fa/src/environments/active-features.ts
Normal file
12
apps/mina-sidor-fa/src/environments/active-features.ts
Normal file
@@ -0,0 +1,12 @@
|
||||
import { Feature } from '@msfa-enums/feature.enum';
|
||||
|
||||
export const ACTIVE_FEATURES_PROD: Feature[] = [Feature.ADMINISTRATION, Feature.MY_ACCOUNT, Feature.MY_ORGANIZATION];
|
||||
|
||||
export const ACTIVE_FEATURES_TEST: Feature[] = [
|
||||
Feature.ADMINISTRATION,
|
||||
Feature.MY_ACCOUNT,
|
||||
Feature.DELTAGARE,
|
||||
Feature.AVROP,
|
||||
Feature.MY_ORGANIZATION,
|
||||
Feature.RELEASES,
|
||||
];
|
||||
19
apps/mina-sidor-fa/src/environments/ciam.ts
Normal file
19
apps/mina-sidor-fa/src/environments/ciam.ts
Normal file
@@ -0,0 +1,19 @@
|
||||
import { Ciam } from '@msfa-models/ciam.model';
|
||||
|
||||
export const CIAM_TEST: Ciam = {
|
||||
clientId: '5d08c2e4-763e-42f6-b858-24e4773bb83d',
|
||||
loginUrl: 'https://ciam-test.arbetsformedlingen.se:8443/uas/oauth2/authorization?response_type=code&scope=openid',
|
||||
logoutUrl: 'https://ciam-test.arbetsformedlingen.se:8443/uas/logout',
|
||||
};
|
||||
|
||||
export const CIAM_PROD: Ciam = {
|
||||
clientId: '71010833-e445-4bbc-926a-775247b7a6e3',
|
||||
loginUrl: 'https://ciam.arbetsformedlingen.se/uas/oauth2/authorization?response_type=code&scope=openid',
|
||||
logoutUrl: 'https://ciam.arbetsformedlingen.se/uas/logout',
|
||||
};
|
||||
|
||||
export const CIAM_MOCK: Ciam = {
|
||||
clientId: '',
|
||||
loginUrl: '/mock-login',
|
||||
logoutUrl: '/mock-login',
|
||||
};
|
||||
@@ -1,13 +1,14 @@
|
||||
import { Environment } from '@msfa-models/environment.model';
|
||||
import { ACTIVE_FEATURES_PROD } from './active-features';
|
||||
import { CIAM_TEST } from './ciam';
|
||||
|
||||
export const environment: Environment = {
|
||||
environment: 'acc',
|
||||
clientId: '5d08c2e4-763e-42f6-b858-24e4773bb83d',
|
||||
loginUrl: 'https://ciam-test.arbetsformedlingen.se:8443/uas/oauth2/authorization?response_type=code&scope=openid',
|
||||
logoutUrl: 'https://ciam-test.arbetsformedlingen.se:8443/uas/logout',
|
||||
production: true,
|
||||
api: {
|
||||
url: '/api',
|
||||
headers: {},
|
||||
},
|
||||
activeFeatures: [...ACTIVE_FEATURES_PROD],
|
||||
...CIAM_TEST,
|
||||
};
|
||||
|
||||
@@ -1,13 +1,14 @@
|
||||
import { Environment } from '@msfa-models/environment.model';
|
||||
import { ACTIVE_FEATURES_TEST } from './active-features';
|
||||
import { CIAM_TEST } from './ciam';
|
||||
|
||||
export const environment: Environment = {
|
||||
environment: 'api',
|
||||
clientId: '5d08c2e4-763e-42f6-b858-24e4773bb83d',
|
||||
loginUrl: 'https://ciam-test.arbetsformedlingen.se:8443/uas/oauth2/authorization?response_type=code&scope=openid',
|
||||
logoutUrl: 'https://ciam-test.arbetsformedlingen.se:8443/uas/logout',
|
||||
production: false,
|
||||
api: {
|
||||
url: '/api',
|
||||
headers: {},
|
||||
},
|
||||
activeFeatures: [...ACTIVE_FEATURES_TEST],
|
||||
...CIAM_TEST,
|
||||
};
|
||||
|
||||
@@ -1,13 +1,14 @@
|
||||
import { Environment } from '@msfa-models/environment.model';
|
||||
import { ACTIVE_FEATURES_PROD } from './active-features';
|
||||
import { CIAM_PROD } from './ciam';
|
||||
|
||||
export const environment: Environment = {
|
||||
environment: 'prod',
|
||||
clientId: '71010833-e445-4bbc-926a-775247b7a6e3',
|
||||
loginUrl: 'https://ciam.arbetsformedlingen.se/uas/oauth2/authorization?response_type=code&scope=openid',
|
||||
logoutUrl: 'https://ciam.arbetsformedlingen.se/uas/logout',
|
||||
production: true,
|
||||
api: {
|
||||
url: '/api',
|
||||
headers: {},
|
||||
},
|
||||
activeFeatures: [...ACTIVE_FEATURES_PROD],
|
||||
...CIAM_PROD,
|
||||
};
|
||||
|
||||
@@ -1,13 +1,15 @@
|
||||
import { Feature } from '@msfa-enums/feature.enum';
|
||||
import { Environment } from '@msfa-models/environment.model';
|
||||
import { ACTIVE_FEATURES_TEST } from './active-features';
|
||||
import { CIAM_MOCK } from './ciam';
|
||||
|
||||
export const environment: Environment = {
|
||||
environment: 'local',
|
||||
clientId: '',
|
||||
loginUrl: '/mock-login',
|
||||
logoutUrl: '/mock-login',
|
||||
production: false,
|
||||
api: {
|
||||
url: '/api',
|
||||
headers: {},
|
||||
},
|
||||
activeFeatures: [...ACTIVE_FEATURES_TEST, Feature.MOCK_LOGIN],
|
||||
...CIAM_MOCK,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user