cartodb-4.42/lib/assets/javascripts/dashboard/views/public-profile/user-feed/feed-collection.js
2024-04-06 05:25:13 +00:00

19 lines
413 B
JavaScript

var Backbone = require('backbone');
module.exports = Backbone.Collection.extend({
url: '/api/v1/viz',
parse: function (models) {
this.total_entries = models.total_entries;
return models.visualizations;
},
initialize: function (models, options) {
if (!options.config) {
throw new Error('config model is required for feed collection');
}
this._config = options.config;
}
});