Initial Commit

This commit is contained in:
root
2013-05-06 03:38:29 -04:00
commit d392a540e7
134 changed files with 22012 additions and 0 deletions

12
app/model/counter.js Normal file
View File

@ -0,0 +1,12 @@
var mongoose = require('mongoose'),
Schema = mongoose.Schema,
ObjectId = Schema.ObjectId;
var counterSchema = new Schema({
name: String,
seq: { type: Number, default: 0 }
});
counterSchema.index({ field: 1, model: 1 }, { unique: true, required: true, index: -1 });
module.exports = mongoose.model('Counter', counterSchema);