2018-07-24 02:56:39 -04:00
|
|
|
const Backbone = require('backbone');
|
|
|
|
|
|
|
|
const model = Backbone.Model.extend({
|
|
|
|
idAttribute: 'id',
|
|
|
|
|
|
|
|
defaults: function () {
|
|
|
|
return {
|
2018-08-15 23:08:56 -04:00
|
|
|
id: undefined,
|
2018-07-24 02:56:39 -04:00
|
|
|
created_on: null,
|
|
|
|
modified_on: null,
|
2018-08-15 23:08:56 -04:00
|
|
|
name: '',
|
2018-08-18 03:16:23 -04:00
|
|
|
items: [],
|
2018-07-24 02:56:39 -04:00
|
|
|
// The following are expansions:
|
|
|
|
owner: null
|
|
|
|
};
|
|
|
|
}
|
|
|
|
});
|
|
|
|
|
|
|
|
module.exports = {
|
|
|
|
Model: model,
|
|
|
|
Collection: Backbone.Collection.extend({
|
|
|
|
model: model
|
|
|
|
})
|
|
|
|
};
|