author | Chloe Laisne <chloe.laisne@gmail.com> |
Fri, 22 Jul 2016 18:25:02 +0200 | |
changeset 248 | 256272c33349 |
parent 245 | c9dd78a43b07 |
child 261 | 02e2396bcbbc |
permissions | -rw-r--r-- |
import RESTAdapter from 'ember-data/adapters/rest'; import ENV from 'app-client/config/environment'; export default RESTAdapter.extend({ namespace: ENV.baseURL.replace(/\/$/,"")+'/api/v1', buildURL: function(modelName, id) { if(modelName === 'transcript') { return this.urlPrefix() + '/documents/' + id + '/' + modelName; } return this._super(...arguments); }, pathForType: function(modelName) { if(modelName === 'transcript') { return modelName; } return this._super(...arguments); } });