Forum Discussion
LoundesM
8 years agoContributor
Hi
def queryParametersString = mockRequest.getHttpRequest().getQueryString()
will return all of the optional parameters within the request
you can get individual parameter values using the following
def queryParametersVarX = mockRequest.getHttpRequest().getParameter("ADD PARAM NAME HERE")
its worth noting that for some reason if you execute this within the ServiceV script you wont see any values, however if you have the virt running and output the values to the script log (i.e. log.info queryParametersVarX) then send a request into the virt from the projects tab the values will appear in the log
any logic based upon the values therefore will only be exercised at runtime
hope that helps
Related Content
- 9 years agoJames1