feat(auth): introduce explicit planning read permission
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { SystemRole } from "./enums.js";
|
||||
|
||||
export const PermissionKey = {
|
||||
VIEW_PLANNING: "viewPlanning",
|
||||
VIEW_COSTS: "viewCosts",
|
||||
USE_ASSISTANT_ADVANCED_TOOLS: "useAssistantAdvancedTools",
|
||||
EXPORT_DATA: "exportData",
|
||||
@@ -28,6 +29,7 @@ export interface PermissionOverrides {
|
||||
export const ROLE_DEFAULT_PERMISSIONS: Record<SystemRole, PermissionKey[]> = {
|
||||
ADMIN: Object.values(PermissionKey),
|
||||
MANAGER: [
|
||||
PermissionKey.VIEW_PLANNING,
|
||||
PermissionKey.VIEW_COSTS,
|
||||
PermissionKey.EXPORT_DATA,
|
||||
PermissionKey.IMPORT_DATA,
|
||||
@@ -40,6 +42,7 @@ export const ROLE_DEFAULT_PERMISSIONS: Record<SystemRole, PermissionKey[]> = {
|
||||
PermissionKey.VIEW_SCORES,
|
||||
],
|
||||
CONTROLLER: [
|
||||
PermissionKey.VIEW_PLANNING,
|
||||
PermissionKey.VIEW_COSTS,
|
||||
PermissionKey.EXPORT_DATA,
|
||||
PermissionKey.VIEW_ALL_RESOURCES,
|
||||
|
||||
Reference in New Issue
Block a user