/public/js/app/collections/GenericCollection.js
JavaScript | 23 lines | 11 code | 8 blank | 4 comment | 0 complexity | abe4a141e54c98c6c0435ce4ce348f3b MD5 | raw file
- // GenericCollection.js
- // -------------
- define(["jquery", "backbone", "./BaseCollection", "models/GenericItemModel"],
-
- function($, Backbone, BaseCollection, GenericItemModel) {
-
- // Creates a new Backbone Collection class object
- var Collection = BaseCollection.extend({
-
- url: function() {
- return this.apiUrl + '/' + this.query;
- },
-
- model: GenericItemModel
-
- });
-
- // Returns the Model class
- return Collection;
-
- }
-
- );