rights system
This commit is contained in:
28
frontend/src/types/permissions.types.ts
Normal file
28
frontend/src/types/permissions.types.ts
Normal file
@@ -0,0 +1,28 @@
|
||||
export interface FeatureGroup {
|
||||
id: string;
|
||||
label: string;
|
||||
sort_order: number;
|
||||
maintenance: boolean;
|
||||
}
|
||||
|
||||
export interface Permission {
|
||||
id: string;
|
||||
feature_group_id: string;
|
||||
label: string;
|
||||
description?: string;
|
||||
sort_order: number;
|
||||
}
|
||||
|
||||
export interface MyPermissions {
|
||||
permissions: string[];
|
||||
maintenance: Record<string, boolean>;
|
||||
isAdmin: boolean;
|
||||
}
|
||||
|
||||
export interface PermissionMatrix {
|
||||
featureGroups: FeatureGroup[];
|
||||
permissions: Permission[];
|
||||
groups: string[];
|
||||
grants: Record<string, string[]>;
|
||||
maintenance: Record<string, boolean>;
|
||||
}
|
||||
Reference in New Issue
Block a user