description optional

This commit is contained in:
Yaman Qalieh 2016-08-13 17:36:35 -04:00
parent 83214bec01
commit 9957cba048

View File

@ -3,38 +3,38 @@ classes = new Mongo.Collection("Classes");
work = new Mongo.Collection("Work"); work = new Mongo.Collection("Work");
schools.schema = new SimpleSchema({ schools.schema = new SimpleSchema({
name: {type: String}, name: {type: String},
status: {type: Boolean}, status: {type: Boolean},
creator: {type: String}, creator: {type: String},
}); });
classes.schema = new SimpleSchema({ classes.schema = new SimpleSchema({
school: {type: String}, school: {type: String},
//icon: {type: String}, //icon: {type: String},
name: {type: String, label: "Class Name"}, name: {type: String, label: "Class Name"},
hour: {type: String, optional: true}, hour: {type: String, optional: true},
teacher: {type: String, optional: true}, teacher: {type: String, optional: true},
admin: {type: String, optional: true}, admin: {type: String, optional: true},
status: {type: Boolean, defaultValue: false}, status: {type: Boolean, defaultValue: false},
code: {type: String, defaultValue: ""}, code: {type: String, defaultValue: ""},
privacy: {type: Boolean}, privacy: {type: Boolean},
category: {type: String}, category: {type: String},
moderators: {type: [String], optional: true}, moderators: {type: [String], optional: true},
banned: {type: [String], optional: true}, banned: {type: [String], optional: true},
blockEdit: {type: [String], optional: true}, blockEdit: {type: [String], optional: true},
subscribers: {type: Number, optional: true} subscribers: {type: Number, optional: true}
}); });
work.schema = new SimpleSchema({ work.schema = new SimpleSchema({
name: {type: String}, name: {type: String},
class: {type: String}, class: {type: String},
dueDate: {type: Date}, dueDate: {type: Date},
description: {type: String}, description: {type: String, optional: true},
creator: {type: String}, creator: {type: String},
comments: {type: [String], optional: true}, comments: {type: [String], optional: true},
confirmations: {type: [String], optional: true}, confirmations: {type: [String], optional: true},
reports: {type: [String], optional: true}, reports: {type: [String], optional: true},
attachments: {type: [String], optional: true}, attachments: {type: [String], optional: true},
done: {type: [String], optional: true}, done: {type: [String], optional: true},
type: {type: String} type: {type: String}
}); });