angularjs - How to create complex query parameters in Restangular -


I need to create a purely complex query string.

  http: // vdmta.rd.mycompany.net//people?anr=Smith&attrs=givenName,displayName, name, cna   

I How do i do

So far I've been receiving it: AR = Smith is using it:

  RetiringRular. All ('/ people'). GetList ({anr: searchTerm});   

The last part attrs = x, y, x lets me control what I want to search back in and I can change every request.

Any advice appreciated

I

i

You should be able to add just another query parameter where the value is a list of attributes related to your comma.

  var attributes = ['givenName', 'displayName']; // properties are required for the request var attributesAsString = attributes.join (); Return Restangular.all ('/ people'). GetList ({anr: searchTerm, attrs: attributesAsString});    

Comments

Popular posts from this blog

php - PDO bindParam() fatal error -

logging - How can I log both the Request.InputStream and Response.OutputStream traffic in my ASP.NET MVC3 Application for specific Actions? -

java - Why my included JSP file won't get processed correctly? -