-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathservicesoffered.js
26 lines (19 loc) · 1016 Bytes
/
servicesoffered.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import mongoose from "mongoose";
import Entity from "./entity.js";
export default class ServicesOffered extends Entity {
static schema = new mongoose.Schema({
AvailableBeds: { type: "Number", required: true},
TotalBeds: { type: "Number", required: true},
VolunteerOpportunities: { type: "Number", required: true},
VolunteersNeeded: { type: "Number", required: true},
ServiceType: { type: "String", required: true},
ServicesDescription: { type: "String", required: true},
CriteriaForService: { type: "String", required: true},
WarmingStation: { type: "String", required: true},
CoolingStation: { type: "String", required: true},
createdAt: { type: "Date", default: new Date() },
updatedAt: { type: "Date", default: new Date() },
Provider: [{ type: mongoose.Schema.Types.ObjectId, ref: "Provider"}]
});
static model = mongoose.model("ServicesOffered", ServicesOffered.schema, "ServicesOffered");
}