You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
docker-infisical/backend/src/models/incidentContactOrg.ts

32 lines
553 B

import { Schema, model, Types } from 'mongoose';
export interface IIncidentContactOrg {
_id: Types.ObjectId;
email: string;
organization: Types.ObjectId;
}
const incidentContactOrgSchema = new Schema<IIncidentContactOrg>(
{
email: {
type: String,
required: true
},
organization: {
type: Schema.Types.ObjectId,
ref: 'Organization',
required: true
}
},
{
timestamps: true
}
);
const IncidentContactOrg = model<IIncidentContactOrg>(
'IncidentContactOrg',
incidentContactOrgSchema
);
export default IncidentContactOrg;