feat: implement collaborator reactivation logic, add access denied handling, and improve metric filtering

This commit is contained in:
2026-07-19 18:56:39 -03:00
parent af6c87acb6
commit 74d6ee6706
27 changed files with 3148 additions and 37 deletions
@@ -22,6 +22,14 @@ export interface IEmployee {
roles?: EmployeeRoles[];
guestOk?: boolean;
hostOk?: boolean;
removed?: boolean;
removedAt?: Date;
profileSnapshot?: {
firstName?: string;
lastName?: string;
email?: string;
avatar?: string;
};
}
export interface CompanyEmployeesView {
@@ -38,6 +46,14 @@ export interface CompanyEmployeesView {
hostOk: boolean;
fullOk: boolean;
calendarColor: string;
removed?: boolean;
removedAt?: Date;
profileSnapshot?: {
firstName?: string;
lastName?: string;
email?: string;
avatar?: string;
};
}
export type CreateEmployeeParams = {
@@ -66,6 +82,13 @@ export type ValidateEmployeeParams = {
sessionUser: string;
};
export type RemoveCollaboratorParams = {
employeeId: string;
companyId: string;
replacementEmployeeId?: string;
sessionUser: string;
};
export type FindEmployeesByIdParams = {
id?: string;
};