mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-06-02 19:55:18 +02:00
feat: add Role type for RBAC
This commit is contained in:
parent
bc6f7e15f1
commit
37f2b27451
1 changed files with 14 additions and 0 deletions
14
surfsense_web/contracts/types/rbac.types.ts
Normal file
14
surfsense_web/contracts/types/rbac.types.ts
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
import { z } from "zod";
|
||||
|
||||
export const role = z.object({
|
||||
id: z.number(),
|
||||
name: z.string().min(1).max(100),
|
||||
description: z.string().max(500).nullable(),
|
||||
permissions: z.array(z.string()),
|
||||
is_default: z.boolean(),
|
||||
is_system_role: z.boolean(),
|
||||
search_space_id: z.number(),
|
||||
created_at: z.string(),
|
||||
});
|
||||
|
||||
export type Role = z.infer<typeof role>;
|
||||
Loading…
Add table
Add a link
Reference in a new issue