_id: EType.objectId,
first_name: <ISchemaProperty>{
__type: EType.string,
validations: <IPropertyValidation>{
required: true
}
},
area_pincode: <ISchemaProperty>{
__type: EType.string,
validations: <IPropertyValidation>{
min: 6
}
},
monthly_salary: <ISchemaProperty>{
__type: EType.string,
validations: <IPropertyValidation>{
max: 9
}
},
last_name: <ISchemaProperty>{
__type: EType.string,
validations: <IPropertyValidation>{
minLength: 3
}
},
last_name: <ISchemaProperty>{
__type: EType.string,
validations: <IPropertyValidation>{
maxLength: 15
}
},
mobile_no: <ISchemaProperty>{
__type: EType.number,
validations: <IPropertyValidation>{
unique: true
}
},
mail_Id: <ISchemaProperty>{
__type: EType.string,
validations: <IPropertyValidation>{
email: true
}
},
country_name: <ISchemaProperty>{
__type: EType.string,
validations: <IPropertyValidation>{
validatorFun: <any><IFunctionJSON> {
hash: '12345645616148',
code: `(str) => {
if (str && ['AHMEDABAD', 'SURAT'].includes(str)) throw new Error("You can not save country_name as '"+ str+ "'");
else return true;
}`,
}
}
}