feat(editor): Add Workflow history route and base page (no-changelog) (#7161)

This commit is contained in:
Csaba Tuncsik
2023-09-15 13:17:04 +02:00
committed by GitHub
parent 556a6132ba
commit 240b2f075e
6 changed files with 88 additions and 4 deletions

View File

@@ -40,6 +40,7 @@ import SamlOnboarding from '@/views/SamlOnboarding.vue';
import SettingsSourceControl from './views/SettingsSourceControl.vue';
import SettingsExternalSecrets from './views/SettingsExternalSecrets.vue';
import SettingsAuditLogs from './views/SettingsAuditLogs.vue';
import WorkflowHistory from '@/views/WorkflowHistory.vue';
import { EnterpriseEditionFeature, VIEWS } from '@/constants';
interface IRouteConfig {
@@ -293,6 +294,28 @@ export const routes = [
},
],
},
{
path: '/workflow/:workflowId/history/:historyId?',
name: VIEWS.WORKFLOW_HISTORY,
components: {
default: WorkflowHistory,
sidebar: MainSidebar,
},
meta: {
keepWorkflowAlive: true,
permissions: {
allow: {
loginStatus: [LOGIN_STATUS.LoggedIn],
},
deny: {
shouldDeny: () =>
!useSettingsStore().isEnterpriseFeatureEnabled(
EnterpriseEditionFeature.WorkflowHistory,
),
},
},
},
},
{
path: '/workflows/templates/:id',
name: VIEWS.TEMPLATE_IMPORT,
@@ -493,7 +516,7 @@ export const routes = [
shouldDeny: () => {
const settingsStore = useSettingsStore();
return (
settingsStore.settings.hideUsagePage === true ||
settingsStore.settings.hideUsagePage ||
settingsStore.settings.deployment?.type === 'cloud'
);
},
@@ -570,7 +593,7 @@ export const routes = [
deny: {
shouldDeny: () => {
const settingsStore = useSettingsStore();
return settingsStore.isPublicApiEnabled === false;
return !settingsStore.isPublicApiEnabled;
},
},
},
@@ -685,7 +708,7 @@ export const routes = [
deny: {
shouldDeny: () => {
const settingsStore = useSettingsStore();
return settingsStore.isCommunityNodesFeatureEnabled === false;
return !settingsStore.isCommunityNodesFeatureEnabled;
},
},
},
@@ -702,7 +725,7 @@ export const routes = [
pageCategory: 'settings',
getProperties(route: RouteLocation) {
return {
feature: route.params['featureId'],
feature: route.params.featureId,
};
},
},