feat(core): Add SAML settings and consolidate LDAP under SSO (#5574)
* consolidate SSO settings * update saml settings * fix type error
This commit is contained in:
committed by
GitHub
parent
f61d779667
commit
31cc8de829
@@ -766,9 +766,15 @@ export interface IN8nUISettings {
|
||||
enabled: boolean;
|
||||
};
|
||||
};
|
||||
ldap: {
|
||||
loginLabel: string;
|
||||
loginEnabled: boolean;
|
||||
sso: {
|
||||
saml: {
|
||||
loginLabel: string;
|
||||
loginEnabled: boolean;
|
||||
};
|
||||
ldap: {
|
||||
loginLabel: string;
|
||||
loginEnabled: boolean;
|
||||
};
|
||||
};
|
||||
onboardingCallPromptEnabled: boolean;
|
||||
allowedModules: {
|
||||
@@ -1197,6 +1203,10 @@ export interface ISettingsState {
|
||||
loginLabel: string;
|
||||
loginEnabled: boolean;
|
||||
};
|
||||
saml: {
|
||||
loginLabel: string;
|
||||
loginEnabled: boolean;
|
||||
};
|
||||
onboardingCallPromptEnabled: boolean;
|
||||
saveDataErrorExecution: string;
|
||||
saveDataSuccessExecution: string;
|
||||
|
||||
@@ -24,7 +24,7 @@ import {
|
||||
WorkflowCallerPolicyDefaultOption,
|
||||
ILdapConfig,
|
||||
} from '@/Interface';
|
||||
import { ITelemetrySettings } from 'n8n-workflow';
|
||||
import { IDataObject, ITelemetrySettings } from 'n8n-workflow';
|
||||
import { defineStore } from 'pinia';
|
||||
import Vue from 'vue';
|
||||
import { useRootStore } from './n8nRootStore';
|
||||
@@ -54,6 +54,10 @@ export const useSettingsStore = defineStore(STORES.SETTINGS, {
|
||||
loginLabel: '',
|
||||
loginEnabled: false,
|
||||
},
|
||||
saml: {
|
||||
loginLabel: '',
|
||||
loginEnabled: false,
|
||||
},
|
||||
onboardingCallPromptEnabled: false,
|
||||
saveDataErrorExecution: 'all',
|
||||
saveDataSuccessExecution: 'all',
|
||||
@@ -87,6 +91,12 @@ export const useSettingsStore = defineStore(STORES.SETTINGS, {
|
||||
ldapLoginLabel(): string {
|
||||
return this.ldap.loginLabel;
|
||||
},
|
||||
isSamlLoginEnabled(): boolean {
|
||||
return this.saml.loginEnabled;
|
||||
},
|
||||
samlLoginLabel(): string {
|
||||
return this.saml.loginLabel;
|
||||
},
|
||||
showSetupPage(): boolean {
|
||||
return this.userManagement.showSetupOnFirstLoad === true;
|
||||
},
|
||||
@@ -168,8 +178,10 @@ export const useSettingsStore = defineStore(STORES.SETTINGS, {
|
||||
this.userManagement.smtpSetup = settings.userManagement.smtpSetup;
|
||||
this.api = settings.publicApi;
|
||||
this.onboardingCallPromptEnabled = settings.onboardingCallPromptEnabled;
|
||||
this.ldap.loginEnabled = settings.ldap.loginEnabled;
|
||||
this.ldap.loginLabel = settings.ldap.loginLabel;
|
||||
this.ldap.loginEnabled = settings.sso.ldap.loginEnabled;
|
||||
this.ldap.loginLabel = settings.sso.ldap.loginLabel;
|
||||
this.saml.loginEnabled = settings.sso.saml.loginEnabled;
|
||||
this.saml.loginLabel = settings.sso.saml.loginLabel;
|
||||
},
|
||||
async getSettings(): Promise<void> {
|
||||
const rootStore = useRootStore();
|
||||
|
||||
Reference in New Issue
Block a user