From efe6b828ff1c7d2e95ba406e6d12dba689a258d4 Mon Sep 17 00:00:00 2001 From: Eduard Gert Date: Mon, 25 Mar 2024 14:24:34 +0100 Subject: [PATCH] Add 'Permission' interface --- src/interfaces/Account.ts | 1 + src/interfaces/Permission.ts | 3 +++ src/interfaces/User.ts | 3 +++ 3 files changed, 7 insertions(+) create mode 100644 src/interfaces/Permission.ts diff --git a/src/interfaces/Account.ts b/src/interfaces/Account.ts index d98a0f43..c9515054 100644 --- a/src/interfaces/Account.ts +++ b/src/interfaces/Account.ts @@ -10,5 +10,6 @@ export interface Account { jwt_groups_enabled: boolean; jwt_groups_claim_name: string; jwt_allow_groups: string[]; + regular_users_view_blocked: boolean; }; } diff --git a/src/interfaces/Permission.ts b/src/interfaces/Permission.ts new file mode 100644 index 00000000..5bf318ca --- /dev/null +++ b/src/interfaces/Permission.ts @@ -0,0 +1,3 @@ +export interface Permission { + dashboard_view: "limited" | "full" | "blocked"; +} diff --git a/src/interfaces/User.ts b/src/interfaces/User.ts index 04be6a40..84df502a 100644 --- a/src/interfaces/User.ts +++ b/src/interfaces/User.ts @@ -1,3 +1,5 @@ +import { Permission } from "@/interfaces/Permission"; + export interface User { id: string; email?: string; @@ -9,6 +11,7 @@ export interface User { is_service_user?: boolean; is_blocked?: boolean; last_login?: Date; + permissions: Permission; } export enum Role {