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;
|
||||
ico: number;
|
||||
contact: number;
|
||||
hiring: number;
|
||||
hiring: boolean;
|
||||
};
|
||||
|
||||
export interface NewCompanyData {
|
||||
name: string;
|
||||
address: string;
|
||||
ico: number;
|
||||
hiring: boolean;
|
||||
};
|
||||
@@ -2,4 +2,9 @@ export enum Role {
|
||||
STUDENT = 'STUDENT',
|
||||
EMPLOYER = 'EMPLOYER',
|
||||
ADMIN = 'ADMIN'
|
||||
}
|
||||
|
||||
export enum NewRole {
|
||||
STUDENT = 'STUDENT',
|
||||
EMPLOYER = 'EMPLOYER',
|
||||
}
|
||||
@@ -4,4 +4,11 @@ export interface StudentData {
|
||||
address: string;
|
||||
personal_email: 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 { CompanyData } from "./company_data";
|
||||
import type { StudentData } from "./student_data";
|
||||
import type { NewRole, Role } from "./role";
|
||||
import type { CompanyData, NewCompanyData } from "./company_data";
|
||||
import type { NewStudentData, StudentData } from "./student_data";
|
||||
|
||||
export interface User {
|
||||
id: number,
|
||||
@@ -12,4 +12,14 @@ export interface User {
|
||||
role: Role,
|
||||
company_data?: CompanyData,
|
||||
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