JS-Data override endpoint with ds.save

39 Views Asked by At

I'm trying to do a patch with DS.save but I want to override the endpoint, and js-data doesn't seem to let me do that. Here's the line of code:

DS.save('reviews', vm.review, {endpoint : 'reports/' + vm.report.id + '/reviews'}, {changesOnly: true})

instead, the endpoint stays as 'reviews/[vm.review.id]'

Does anyone have a suggestion or fix? Thanks!

0

There are 0 best solutions below