You've already forked isop-mirror
feat: update data interfaces to include new role and company data structures
This commit is contained in:
@@ -4,5 +4,12 @@ export interface CompanyData {
|
|||||||
address: string;
|
address: string;
|
||||||
ico: number;
|
ico: number;
|
||||||
contact: number;
|
contact: number;
|
||||||
hiring: number;
|
hiring: boolean;
|
||||||
|
};
|
||||||
|
|
||||||
|
export interface NewCompanyData {
|
||||||
|
name: string;
|
||||||
|
address: string;
|
||||||
|
ico: number;
|
||||||
|
hiring: boolean;
|
||||||
};
|
};
|
||||||
@@ -3,3 +3,8 @@ export enum Role {
|
|||||||
EMPLOYER = 'EMPLOYER',
|
EMPLOYER = 'EMPLOYER',
|
||||||
ADMIN = 'ADMIN'
|
ADMIN = 'ADMIN'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum NewRole {
|
||||||
|
STUDENT = 'STUDENT',
|
||||||
|
EMPLOYER = 'EMPLOYER',
|
||||||
|
}
|
||||||
@@ -5,3 +5,10 @@ export interface StudentData {
|
|||||||
personal_email: string;
|
personal_email: string;
|
||||||
study_field: string;
|
study_field: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export interface NewStudentData {
|
||||||
|
user_id?: number;
|
||||||
|
address: string;
|
||||||
|
personal_email: string;
|
||||||
|
study_field: string;
|
||||||
|
};
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
import type { Role } from "./role";
|
import type { NewRole, Role } from "./role";
|
||||||
import type { CompanyData } from "./company_data";
|
import type { CompanyData, NewCompanyData } from "./company_data";
|
||||||
import type { StudentData } from "./student_data";
|
import type { NewStudentData, StudentData } from "./student_data";
|
||||||
|
|
||||||
export interface User {
|
export interface User {
|
||||||
id: number,
|
id: number,
|
||||||
@@ -13,3 +13,13 @@ export interface User {
|
|||||||
company_data?: CompanyData,
|
company_data?: CompanyData,
|
||||||
student_data?: StudentData,
|
student_data?: StudentData,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export interface NewUser {
|
||||||
|
email: string,
|
||||||
|
first_name: string,
|
||||||
|
last_name: string,
|
||||||
|
phone: string,
|
||||||
|
role: NewRole,
|
||||||
|
company_data?: NewCompanyData,
|
||||||
|
student_data?: NewStudentData,
|
||||||
|
};
|
||||||
Reference in New Issue
Block a user