feat(core): Add workflow history initial setup (no-changelog) (#6852)

* feat: Add workflow history initial setup

* fix: Add feature to missing controller
This commit is contained in:
Omar Ajoue 2023-08-04 12:27:06 +02:00 committed by GitHub
parent 0511458d41
commit 63ffe67dad
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 13 additions and 0 deletions

View file

@ -136,6 +136,10 @@ export class License {
return this.isFeatureEnabled(LICENSE_FEATURES.SOURCE_CONTROL);
}
isWorkflowHistoryLicensed() {
return this.isFeatureEnabled(LICENSE_FEATURES.WORKFLOW_HISTORY);
}
isAPIDisabled() {
return this.isFeatureEnabled(LICENSE_FEATURES.API_DISABLED);
}

View file

@ -75,6 +75,7 @@ export const LICENSE_FEATURES = {
VARIABLES: 'feat:variables',
SOURCE_CONTROL: 'feat:sourceControl',
API_DISABLED: 'feat:apiDisabled',
WORKFLOW_HISTORY: 'feat:workflowHistory',
} as const;
export const LICENSE_QUOTAS = {

View file

@ -61,6 +61,7 @@ export class E2EController {
[LICENSE_FEATURES.SOURCE_CONTROL]: false,
[LICENSE_FEATURES.VARIABLES]: false,
[LICENSE_FEATURES.API_DISABLED]: false,
[LICENSE_FEATURES.WORKFLOW_HISTORY]: false,
};
constructor(

View file

@ -0,0 +1,7 @@
import { License } from '@/License';
import Container from 'typedi';
export function isWorkflowHistoryLicensed() {
const license = Container.get(License);
return license.isWorkflowHistoryLicensed();
}