forked from Yara724/api
YARA-1034
This commit is contained in:
@@ -31,7 +31,8 @@
|
||||
"branchName": "شعبه غرب تهران(210050)",
|
||||
"city": "تهران",
|
||||
"state": "تهران",
|
||||
"title": "كارشناس ارزياب خسارت ثالث مالي"
|
||||
"title": "كارشناس ارزياب خسارت ثالث مالي",
|
||||
"expertCode": "4645"
|
||||
},
|
||||
{
|
||||
"nationalCode": "0066868521",
|
||||
@@ -40,7 +41,8 @@
|
||||
"lastName": "گودرزي پور",
|
||||
"branchCode": "210050",
|
||||
"branchName": "شعبه غرب تهران(210050)",
|
||||
"title": "كارشناس ارزياب خسارت بدنه"
|
||||
"title": "كارشناس ارزياب خسارت بدنه",
|
||||
"expertCode": "16"
|
||||
},
|
||||
{
|
||||
"nationalCode": "0076988961",
|
||||
@@ -60,7 +62,8 @@
|
||||
"lastName": "شاملوفرد",
|
||||
"branchCode": "210050",
|
||||
"branchName": "شعبه غرب تهران(210050)",
|
||||
"title": "كارشناس ارزياب خسارت ثالث مالي"
|
||||
"title": "كارشناس ارزياب خسارت ثالث مالي",
|
||||
"expertCode": "72"
|
||||
},
|
||||
{
|
||||
"nationalCode": "0083730397",
|
||||
@@ -80,7 +83,8 @@
|
||||
"lastName": "کرکي",
|
||||
"branchCode": "210050",
|
||||
"branchName": "شعبه غرب تهران(210050)",
|
||||
"title": "كارشناس ارزياب خسارت ثالث مالي"
|
||||
"title": "كارشناس ارزياب خسارت ثالث مالي",
|
||||
"expertCode": "29"
|
||||
},
|
||||
{
|
||||
"nationalCode": "0440245151",
|
||||
@@ -100,7 +104,8 @@
|
||||
"branchName": "شعبه غرب تهران(210050)",
|
||||
"city": "تهران",
|
||||
"state": "تهران",
|
||||
"title": "كارشناس ارزياب خسارت ثالث مالي"
|
||||
"title": "كارشناس ارزياب خسارت ثالث مالي",
|
||||
"expertCode": "3545"
|
||||
},
|
||||
{
|
||||
"nationalCode": "0670358118",
|
||||
|
||||
@@ -33,6 +33,7 @@ type FieldExpertSeed = {
|
||||
city?: string;
|
||||
state?: string;
|
||||
title?: string;
|
||||
expertCode?: string;
|
||||
};
|
||||
|
||||
function stripQuotes(value: string): string {
|
||||
@@ -172,6 +173,7 @@ const FieldExpertSchema = new Schema(
|
||||
phone: { type: String },
|
||||
role: { type: String, default: "field_expert" },
|
||||
otp: { type: String, default: "" },
|
||||
expertCode: { type: String, required: false },
|
||||
},
|
||||
{ collection: "field-expert", versionKey: false, timestamps: true },
|
||||
);
|
||||
@@ -273,6 +275,7 @@ async function main() {
|
||||
mobile: expert.mobile,
|
||||
role: "field_expert",
|
||||
otp: "",
|
||||
expertCode: expert.expertCode,
|
||||
};
|
||||
|
||||
const existing = await FieldExpert.findOne({
|
||||
|
||||
@@ -159,6 +159,9 @@ export class DamageExpertModel {
|
||||
@Prop({ type: "string" })
|
||||
city: string;
|
||||
|
||||
@Prop({type: "string", required: false})
|
||||
expertCode?: string;
|
||||
|
||||
createdAt: Date;
|
||||
}
|
||||
|
||||
|
||||
@@ -72,6 +72,9 @@ export class ExpertModel {
|
||||
@Prop({ type: "string" })
|
||||
otp: string;
|
||||
|
||||
@Prop({type: "string", required: false})
|
||||
expertCode?: string;
|
||||
|
||||
createdAt: Date;
|
||||
}
|
||||
|
||||
|
||||
@@ -46,6 +46,9 @@ export class FieldExpertModel {
|
||||
@Prop({ type: "string", default: "" })
|
||||
otp: string;
|
||||
|
||||
@Prop({type: "string", required: false})
|
||||
expertCode?: string;
|
||||
|
||||
createdAt: Date;
|
||||
}
|
||||
|
||||
|
||||
@@ -41,6 +41,9 @@ export class InsurerExpertModel {
|
||||
@Prop()
|
||||
address?: string;
|
||||
|
||||
@Prop({type: "string", required: false})
|
||||
expertCode?: string;
|
||||
|
||||
createdAt: Date;
|
||||
}
|
||||
export const InsurerExpertDbSchema =
|
||||
|
||||
@@ -27,6 +27,9 @@ export class RegistrarModel {
|
||||
|
||||
@Prop({ type: "string", default: "" })
|
||||
otp: string;
|
||||
|
||||
@Prop({type: "string", required: false})
|
||||
expertCode?: string;
|
||||
}
|
||||
|
||||
export const RegistrarDbSchema = SchemaFactory.createForClass(RegistrarModel);
|
||||
|
||||
Reference in New Issue
Block a user