I'm using an API that doesn't have any /post
or anything at the end.
But Ember automatically adds things to the end of my url. Here is the code:
App.Store = DS.Store.extend({
revision: 12,
adapter: DS.RESTAdapter.create({
url: 'http://ift.tt/1CqHrtI'
})
});
App.Offer = DS.Model.extend({
name: DS.attr('string'),
sku: DS.attr('string')
});
App.ApplicationRoute = Ember.Route.extend({
model: function () {
return App.Offer.find();
}
});
Ember adds /offers
to the end of the url
and of course I get a 404.
Aucun commentaire:
Enregistrer un commentaire