wikijs-fork/models/entry.js

36 lines
445 B
JavaScript
Raw Normal View History

2017-02-09 01:52:37 +00:00
'use strict'
/**
* Entry schema
*
* @type {<Mongoose.Schema>}
*/
2016-11-21 01:09:50 +00:00
var entrySchema = Mongoose.Schema({
2017-02-09 01:52:37 +00:00
_id: String,
title: {
type: String,
required: true,
minlength: 2
},
subtitle: {
type: String,
default: ''
},
parent: {
type: String,
default: ''
2017-04-08 20:38:28 +00:00
},
parentPath: {
type: String,
default: ''
}
},
2017-02-09 01:52:37 +00:00
{
timestamps: {}
})
2017-02-09 01:52:37 +00:00
module.exports = Mongoose.model('Entry', entrySchema)