Refactor Protected and Public Routes for Consistent Loading UI; Enhance HomePage with User Company and Branch Details; Update LoginPage Layout; Introduce User Relations in Auth Services
This commit is contained in:
@@ -1,11 +1,27 @@
|
||||
export type RoleName = "admin" | "director" | "manager";
|
||||
|
||||
export interface Branch {
|
||||
id: string;
|
||||
name: string;
|
||||
address: string | null;
|
||||
city: string | null;
|
||||
country: string | null;
|
||||
}
|
||||
|
||||
export interface Company {
|
||||
id: string;
|
||||
name: string;
|
||||
description: string | null;
|
||||
}
|
||||
|
||||
export interface User {
|
||||
id: string;
|
||||
email: string;
|
||||
fullName: string;
|
||||
role: RoleName;
|
||||
createdAt: string;
|
||||
currentBranch?: Branch;
|
||||
currentCompany?: Company;
|
||||
}
|
||||
|
||||
export interface LoginData {
|
||||
@@ -35,4 +51,3 @@ export interface RegisterResponse {
|
||||
export interface MeResponse {
|
||||
user: User;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user