This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"text": "This is the first question", | |
"options": ["answer1","answer2","answer3","answer4"], | |
"answer": 2 | |
}, | |
{ | |
"text": "This is the second question", | |
"options": ["answer 1","answer 2","answer 3", "answer 4"], | |
"answer": 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var mongoose = require('mongoose'); | |
mongoose.connect('localhost', 'testing_multiTenant'); | |
/** | |
* User schema. | |
*/ | |
var UserSchema = new mongoose.Schema({ | |
name: String | |
, prefix: { type: String, required: true } |
A simple Ecto custom type for the Postgres tsrange type.
Based on: http://pedroassumpcao.ghost.io/using-postgres-range-data-type-in-ecto/ and elixir-ecto/postgrex#27