Unverified Commit 82570d72 authored by Mark Stenglein's avatar Mark Stenglein
Browse files

Merge branch '8-ics-generation' into issue21-ical-npm

There shouldnt be mutiple different branches here
parents eb6f368f cc8928d3
// grab the things we need
var mongoose = require('mongoose');
var Schema = mongoose.Schema;
var sectionSchema = require('./sectionSchema');
// create a schema
var semesterSchema = new Schema({
school: { type: String, required: true },
semester: { type: String, required: true },
slug: { type: String, required: true },
classes: [
{
crn: { type: String, required: true },
name: { type: String, required: true },
title: { type: String, required: true },
section: { type: String, required: true },
campus: { type: String, required: true },
session_templates: [
{
date_range: { type: String, required: true },
days: { type: String },
time: { type: String },
location: { type: String, required: true },
class_type: { type: String, required: true },
instructors: { type: String, required: true },
}
],
notification: { type: String, required: true }
}
]
classes: [ sectionSchema ]
});
semesterSchema.set('redisCache', true);
......
// grab the things we need
var mongoose = require('mongoose');
var Schema = mongoose.Schema;
// create a schema
var sectionSchema = new Schema({
crn: { type: String, required: true },
name: { type: String, required: true },
title: { type: String, required: true },
section: { type: String, required: true },
campus: { type: String, required: true },
session_templates: [
{
date_range: { type: String, required: true },
days: { type: String },
time: { type: String },
location: { type: String, required: true },
class_type: { type: String, required: true },
instructors: { type: String, required: true },
}
],
notification: { type: String, required: true }
});
sectionSchema.set('redisCache', true);
// make this available to our users in our Node applications
module.exports = sectionSchema;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment