Skip to content

Instantly share code, notes, and snippets.

@ronfe
Created May 5, 2016 08:33
Show Gist options
  • Save ronfe/7cfc626522a4c65d0a1deb78b7912280 to your computer and use it in GitHub Desktop.
Save ronfe/7cfc626522a4c65d0a1deb78b7912280 to your computer and use it in GitHub Desktop.
var practiceFinishSchema = new Schema({
"user": ObjectId,
"eventTime": Number, // time of finish practice
"serverTime": ISODate, // time of finish practice
"topic": String,
"type": String(enum: ["A", "B", "C", "D", "E", "S"]),
"finishState": String(enum: ["perfect", "imperfect"]),
"duration": Number, //the duration from start practice to finish
"practiceLog": [ // not contained in first version
{"level": String, "problemId": ObjectId, "duration": Number, "correctness": Boolean}
]
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment