mirror of
https://github.com/n8n-io/n8n.git
synced 2025-02-21 02:56:40 -08:00
feat(core): Show a banner when running a non-prod license (no-changelog) (#6849)
* add feat:showNonProdBanner * fix linting * fix linting
This commit is contained in:
parent
775e73e0c3
commit
198a977f57
|
@ -66,6 +66,7 @@ import {
|
|||
GENERATED_STATIC_DIR,
|
||||
inDevelopment,
|
||||
inE2ETests,
|
||||
LICENSE_FEATURES,
|
||||
N8N_VERSION,
|
||||
RESPONSE_ERROR_MESSAGES,
|
||||
TEMPLATES_DIR,
|
||||
|
@ -311,6 +312,7 @@ export class Server extends AbstractServer {
|
|||
variables: false,
|
||||
sourceControl: false,
|
||||
auditLogs: false,
|
||||
showNonProdBanner: false,
|
||||
debugInEditor: false,
|
||||
},
|
||||
hideUsagePage: config.getEnv('hideUsagePage'),
|
||||
|
@ -441,6 +443,9 @@ export class Server extends AbstractServer {
|
|||
advancedExecutionFilters: isAdvancedExecutionFiltersEnabled(),
|
||||
variables: isVariablesEnabled(),
|
||||
sourceControl: isSourceControlLicensed(),
|
||||
showNonProdBanner: Container.get(License).isFeatureEnabled(
|
||||
LICENSE_FEATURES.SHOW_NON_PROD_BANNER,
|
||||
),
|
||||
debugInEditor: isDebugInEditorLicensed(),
|
||||
});
|
||||
|
||||
|
|
|
@ -75,6 +75,7 @@ export const LICENSE_FEATURES = {
|
|||
VARIABLES: 'feat:variables',
|
||||
SOURCE_CONTROL: 'feat:sourceControl',
|
||||
API_DISABLED: 'feat:apiDisabled',
|
||||
SHOW_NON_PROD_BANNER: 'feat:showNonProdBanner',
|
||||
WORKFLOW_HISTORY: 'feat:workflowHistory',
|
||||
DEBUG_IN_EDITOR: 'feat:debugInEditor',
|
||||
} as const;
|
||||
|
|
|
@ -61,6 +61,7 @@ export class E2EController {
|
|||
[LICENSE_FEATURES.SOURCE_CONTROL]: false,
|
||||
[LICENSE_FEATURES.VARIABLES]: false,
|
||||
[LICENSE_FEATURES.API_DISABLED]: false,
|
||||
[LICENSE_FEATURES.SHOW_NON_PROD_BANNER]: false,
|
||||
[LICENSE_FEATURES.WORKFLOW_HISTORY]: false,
|
||||
[LICENSE_FEATURES.DEBUG_IN_EDITOR]: false,
|
||||
};
|
||||
|
|
|
@ -18,6 +18,8 @@ const defaultSettings: IN8nUISettings = {
|
|||
variables: true,
|
||||
sourceControl: false,
|
||||
auditLogs: false,
|
||||
versionControl: false,
|
||||
showNonProdBanner: false,
|
||||
},
|
||||
executionMode: 'regular',
|
||||
executionTimeout: 0,
|
||||
|
|
|
@ -2185,6 +2185,7 @@ export interface IN8nUISettings {
|
|||
variables: boolean;
|
||||
sourceControl: boolean;
|
||||
auditLogs: boolean;
|
||||
showNonProdBanner: boolean;
|
||||
debugInEditor: boolean;
|
||||
};
|
||||
hideUsagePage: boolean;
|
||||
|
|
Loading…
Reference in a new issue