mirror of
https://github.com/Litlyx/litlyx
synced 2025-12-10 15:58:38 +01:00
17 lines
479 B
TypeScript
17 lines
479 B
TypeScript
import { model, Schema, Types } from 'mongoose';
|
|
|
|
|
|
export type TAnomalyEvents = {
|
|
project_id: Schema.Types.ObjectId
|
|
eventDate: string,
|
|
created_at: Date
|
|
}
|
|
|
|
const AnomalyEventsSchema = new Schema<TAnomalyEvents>({
|
|
project_id: { type: Types.ObjectId, required: true },
|
|
eventDate: { type: String, required: true },
|
|
created_at: { type: Date, required: true },
|
|
})
|
|
|
|
export const AnomalyEventsModel = model<TAnomalyEvents>('anomaly_events', AnomalyEventsSchema);
|