mgonto / restangular

AngularJS service to handle Rest API Restful Resources properly and easily
MIT License
7.87k stars 840 forks source link

Support for Matrix URIs #968

Open HenriqueLimas opened 9 years ago

HenriqueLimas commented 9 years ago

It be cool if Restangular gives support for Matrix URIs. Maybe could be created a new Restangular methods "matrixParams" where we can define the matrix URIs.

Today:

Restangular.all('cambridge;scale=50000').post();

Purpose:

Restangular.all('cambridge').matrixParams({scale: 5000}).post()

Doc: http://www.w3.org/DesignIssues/MatrixURIs.html

grabbou commented 9 years ago

Hey! Great suggestion, to be supported in V2. If you feel powerful enough - please consider doing a PR for this particular feature :) Should not be that hard, it all boils down to exposing matrixParams() method that can be called any time on requestless Restangular object just to modify current route element.

HenriqueLimas commented 9 years ago

Yeah, I am going to make a PR. But, what is the branch I can do that? The "2.0-wip"?

grabbou commented 9 years ago

Thanks! Would love to see that feature :) please use wip/cleanup-improvements to fork and submit PR which is actually our development branch for now.

pedromarce commented 8 years ago

Hi, I know it has been a long time, but trying to tidy a little bit, would still be interesting? Also, wouldn't it make more sense to use it as a configuration flag, so you define parameters same way and based on this parameter the final URL gets built as matrix URI or the existing one?

daviesgeek commented 8 years ago

@HenriqueLimas Is this still something you want to add?

HenriqueLimas commented 8 years ago

@daviesgeek, no nothing to add.

daviesgeek commented 8 years ago

@HenriqueLimas Sorry I should have been more clear. You have a PR up; is this still something that you would like to merge in? I'll work with you to merge it in if necessary.

HenriqueLimas commented 8 years ago

I think is something good to have, someone could want that. But I am not using it anymore..if you think is good to have that, we can merge or just close the pull request.

daviesgeek commented 8 years ago

Okay. This sounds like a good idea to add this, but I'm not familiar with it at all, so I won't merge right now, but will wait for other collaborators to check it out.