{"size": 526, "ext": "js", "max_stars_repo_path": "app/models/chapter.server.model.js", "max_stars_repo_name": "sortofbusy/eatthebible", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "app/models/chapter.server.model.js", "max_issues_repo_name": "sortofbusy/eatthebible", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "app/models/chapter.server.model.js", "max_forks_repo_name": "sortofbusy/eatthebible", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 14.6111111111, "max_line_length": 41, "alphanum_fraction": 0.6406844106}
'use strict';

/**
 * Module dependencies.
 */
var mongoose = require('mongoose'),
	Schema = mongoose.Schema;

/**
 * Chapter Schema
 */
var ChapterSchema = new Schema({
	name: {
		type: String,
		required: 'Please fill Chapter name',
		trim: true
	},
	created: {
		type: Date,
		default: Date.now
	},
	user: {
		type: Schema.ObjectId,
		ref: 'User'
	},
	book: Number,
	chapter: Number,
	verse: Number,
	plan: {
		type: Schema.ObjectId,
		ref: 'Plan'
	},
	absoluteChapter: Number
});

mongoose.model('Chapter', ChapterSchema);