|
@@ -10,29 +10,30 @@ const expert = {
|
|
user_id: { type: ObjectId }, // 关联的personal的id
|
|
user_id: { type: ObjectId }, // 关联的personal的id
|
|
// user
|
|
// user
|
|
name: { type: String, required: true }, // 用户名
|
|
name: { type: String, required: true }, // 用户名
|
|
- phone: { type: String, required: false, maxLength: 200 }, // 电话号码
|
|
|
|
- addr: { type: String, required: false, maxLength: 500 }, // 地址
|
|
|
|
- office_phone: { type: String, required: false, maxLength: 500 }, // 办公电话
|
|
|
|
- profession: { type: String, required: false, maxLength: 500 }, // 所属行业
|
|
|
|
|
|
+ phone: { type: String, required: false }, // 电话号码
|
|
|
|
+ passwd: { type: Secret, required: true, select: false }, // 登录密码
|
|
|
|
+ addr: { type: String, required: false }, // 地址
|
|
|
|
+ office_phone: { type: String, required: false }, // 办公电话
|
|
|
|
+ profession: { type: String, required: false }, // 所属行业
|
|
|
|
|
|
- education: { type: String, required: false, maxLength: 200 }, // 最高学历
|
|
|
|
- school: { type: String, required: false, maxLength: 200 }, // 毕业院校
|
|
|
|
- birthDate: { type: String, required: false, maxLength: 200 }, // 出生日期
|
|
|
|
- qqwx: { type: String, required: false, maxLength: 200 }, // qq&微信
|
|
|
|
- email: { type: String, required: false, maxLength: 200 }, // 邮箱
|
|
|
|
- company: { type: String, required: false, maxLength: 500 }, // 单位名称
|
|
|
|
- zwzc: { type: String, required: false, maxLength: 200 }, // 职务职称
|
|
|
|
- expertise: { type: String, required: false, maxLength: 200 }, // 擅长领域
|
|
|
|
- img_path: { type: String, required: false }, // 头像图片
|
|
|
|
- workexperience: { type: String, required: false, maxLength: 500 }, // 工作经历
|
|
|
|
|
|
+ education: { type: String, required: false }, // 最高学历
|
|
|
|
+ school: { type: String, required: false }, // 毕业院校
|
|
|
|
+ birthDate: { type: String, required: false }, // 出生日期
|
|
|
|
+ qqwx: { type: String, required: false }, // qq&微信
|
|
|
|
+ email: { type: String, required: false }, // 邮箱
|
|
|
|
+ company: { type: String, required: false }, // 单位名称
|
|
|
|
+ zwzc: { type: String, required: false }, // 职务职称
|
|
|
|
+ expertise: { type: String, required: false }, // 擅长领域
|
|
|
|
+ img_path: { type: Array, required: false }, // 头像图片
|
|
|
|
+ workexperience: { type: String, required: false }, // 工作经历
|
|
scientific: { type: String, required: false, maxLength: 300 }, // 科研综述
|
|
scientific: { type: String, required: false, maxLength: 300 }, // 科研综述
|
|
- undertakingproject: { type: String, required: false, maxLength: 200 }, // 承担项目
|
|
|
|
- scienceaward: { type: String, required: false, maxLength: 200 }, // 科技奖励
|
|
|
|
- social: { type: String, required: false, maxLength: 200 }, // 社会任职
|
|
|
|
- // status: { type: String, required: false, default: '0', maxLength: 200 }, // 审核状态,0-注册,1-通过,2-拒绝
|
|
|
|
|
|
+ undertakingproject: { type: String, required: false }, // 承担项目
|
|
|
|
+ scienceaward: { type: String, required: false }, // 科技奖励
|
|
|
|
+ social: { type: String, required: false }, // 社会任职
|
|
|
|
+ status: { type: String, required: false, default: '0' }, // 审核状态,0-注册,1-通过,2-拒绝
|
|
|
|
|
|
isdel: { type: String, required: false, default: '0' }, // 0=>未删除;1=>已删除
|
|
isdel: { type: String, required: false, default: '0' }, // 0=>未删除;1=>已删除
|
|
- remark: { type: String, maxLength: 200 },
|
|
|
|
|
|
+ remark: { type: String },
|
|
create_time: { type: String, default: moment().format('YYYY-MM-DD HH:mm:ss') },
|
|
create_time: { type: String, default: moment().format('YYYY-MM-DD HH:mm:ss') },
|
|
};
|
|
};
|
|
const schema = new Schema(expert, { toJSON: { virtuals: true } });
|
|
const schema = new Schema(expert, { toJSON: { virtuals: true } });
|