UNPKG

@upv/ushi-shared

Version:

Shared DTOs, types, and utilities for the USHI platform (LMS, Trials, Social, Wallet).

37 lines (36 loc) 984 B
import { IBaseDtoInput, IBaseDtoOutput } from './base'; import { RoleDomain, PersonRole } from '../core'; /** * Status of a role assignment */ export type RoleAssignmentStatus = 'active' | 'revoked' | 'expired'; /** * IRoleAssignmentDto - Input type for role assignment */ export interface IRoleAssignmentDto extends IBaseDtoInput { userId: string; role: PersonRole; domain: RoleDomain; contextId?: string; assignedBy?: string; expiresAt?: number; status?: RoleAssignmentStatus; revokedAt?: number; revokedBy?: string; notes?: string; } /** * IRoleAssignment - Serialized role assignment structure */ export interface IRoleAssignment extends IBaseDtoOutput { userId: string; role: PersonRole; domain: RoleDomain; contextId: string | null; assignedBy: string | null; expiresAt: number | null; status: RoleAssignmentStatus; revokedAt: number | null; revokedBy: string | null; notes: string | null; }