periodicjs
Version:
Periodic is a rapid enterprise application framework for data driven web and mobile applications.
26 lines (25 loc) • 591 B
JavaScript
;
const lowkie = require('lowkie');
const Schema = lowkie.Schema;
const ObjectId = Schema.ObjectId;
module.exports = (modelName) => {
return {
entitytype: {
type: String,
default: modelName,
},
_attributes: Schema.Types.Mixed,
entity_attributes: Schema.Types.Mixed,
contenttypeattributes: Schema.Types.Mixed,
extensionattributes: Schema.Types.Mixed,
random: Number,
createdat: {
type: Date,
'default': Date.now,
},
updatedat: {
type: Date,
'default': Date.now,
},
};
};