feat(editor): Replace middleware for Role checks with Scope checks (#7847)

This commit is contained in:
Alex Grozav
2023-11-29 10:35:40 +02:00
committed by GitHub
parent d4970410e1
commit 72852a60eb
18 changed files with 267 additions and 111 deletions

View File

@@ -120,7 +120,6 @@ import { useWorkflowsStore } from '@/stores/workflows.store';
import { isNavigationFailure } from 'vue-router';
import ExecutionsUsage from '@/components/ExecutionsUsage.vue';
import MainSidebarSourceControl from '@/components/MainSidebarSourceControl.vue';
import { ROLE } from '@/utils/userUtils';
import { hasPermission } from '@/rbac/permissions';
export default defineComponent({
@@ -177,9 +176,7 @@ export default defineComponent({
return accessibleRoute !== null;
},
showUserArea(): boolean {
return hasPermission(['role'], {
role: [ROLE.Member, ROLE.Owner],
});
return hasPermission(['authenticated']);
},
workflowExecution(): IExecutionResponse | null {
return this.workflowsStore.getWorkflowExecution;