Files
IlLievitario-App/js/model/categoryItem/categoryItemCollection.js
T

22 lines
582 B
JavaScript

define(['app', 'jquery', 'underscore', 'backbone', 'model/categoryItem/categoryItemModel'],
function (app, $, _, Backbone, Category){
var CategoryItems=Backbone.Collection.extend({
categoryId: null,
initialize: function (options) {
this.categoryId = options.categoryId;
},
// Book is the model of the collection
model:Category,
url: function() {
return myManifest.Settings.DefaultURL + "/api/ricette/" + this.categoryId;
}
});
return CategoryItems;
});