FacultyCreative / ngActiveResource

Connects business objects and REST web services for Angular.js
255 stars 34 forks source link

URL parameter for .hasMany relationships #53

Open DibbsZA opened 10 years ago

DibbsZA commented 10 years ago

Is there a way to force the .hasMany() relationship to use URL parameters and not query strings?

My Rest API wants the parameters in the form:

 /API/Incident/Activity/:ProblemID
 which resolves to...
 /API/Incident/Activity/2

I can correctly call the model directly by passing in the correct named parameter, but the automatic association of parent-to-child is always called with the query string like:

 /API/Incident/Activity?problem_id=2