import { Document } from 'mongoose'; import { IDefaultAttributes } from './commonInterface'; import { CATEGORY, COMMAN_STATUS, DISABILITY_TYPE, EMPLOYMENT_TYPE, FILE_TYPE, IMAGE__NAME, IS_PRINCIPAL, NATIONALITY, NO_TYPE, RELATION, RELIGION_CASTE, USER_DETAILS, USER_TYPES, WORK_CATEGORY, WORK_TYPE } from '../constants/app'; export interface IUserHasFiles { fileType: FILE_TYPE; status?: COMMAN_STATUS; fileName: IMAGE__NAME; fileStorageId: string; } export interface IUserHasQualification { degree: string; schoolCollege: string | null; boardUniversity: string | null; passingYear: Date | null; } export interface IUserSchoolInfo { firstName: string; lastName: string; middleName: string; dob: string; birthPlace?: string; gender?: string; fatherName?: string; motherName?: string; category?: CATEGORY; nationality?: NATIONALITY; religionCaste?: RELIGION_CASTE; caste?: string; } export interface IExperienceSchema { jobTitle: string; subJobTitle: string; jobDescription: string; employmentType: EMPLOYMENT_TYPE; startTime: Date; endTime: Date; status: string; entities: string[]; isPrincipal: IS_PRINCIPAL; instituteId: string; institutedName: string; userType: USER_TYPES; isSchool?: boolean; } export interface ILastSchoolSchema { startTime: Date; endTime: Date; name: string; address1: string; address2: string; area: string; city: number; district: string; state: number; country: number; pinCode: string; taluka?: string; reason: string; instituteId: string; result?: number; haveLeavingCertificate?: boolean; entities: string[]; leavingCertificateIssueDate: Date; isSchool?: boolean; } export interface IAddressSchema { address1: string; address2: string; area?: string; city: number; district: string; state: number; country: number; pinCode: string; taluka?: string; } export interface IEmergencyContactSchema { name: string; relation: RELATION; mobile: string; } export interface IWorkingDetailsSchema { workType: WORK_TYPE | null; workCategory: WORK_CATEGORY | null; occupation: string; organizationAddress: string | null; organizationName: string; } export interface IUserDetailsAttributes extends IDefaultAttributes, Document { id: string; intersetedEntities?: string[]; experiences?: IExperienceSchema[]; lastSchool?: ILastSchoolSchema[]; userId: string; files?: IUserHasFiles[]; qualifications?: IUserHasQualification[]; bio?: string; birthPlace: string; fatherName: string; motherName: string; aadharCard: string; driverlicense: string; panCard?: string; category: CATEGORY; nationality: NATIONALITY; religionCaste: RELIGION_CASTE; caste: string; currentAddress: IAddressSchema; uidNo: string; teacherUidNo: string; uniqueNumber: string; numberType: NO_TYPE; gpfNo: string; epfNo: string; userDetailsType: USER_DETAILS; userDetails: DISABILITY_TYPE; emergencyContact: IEmergencyContactSchema; workingDetails: IWorkingDetailsSchema; userSchoolInfo: IUserSchoolInfo; domicileState?: string; studentPen?: string; apaarId?: string; currentInstituteId?: string; }