Skip to content

Instantly share code, notes, and snippets.

@astrotars
Created January 10, 2013 15:55
Show Gist options
  • Select an option

  • Save astrotars/4503140 to your computer and use it in GitHub Desktop.

Select an option

Save astrotars/4503140 to your computer and use it in GitHub Desktop.
submission.js
var Schema = mongoose.Schema,
ObjectId = Schema.ObjectId;
var submissionSchema = new Schema({
sweepstakes_id: {
type: Schema.Types.ObjectId,
ref: 'Sweepstakes'
},
email: {
type: String,
index: true,
unique: true
},
data: Schema.Types.Mixed
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment