We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I have a controller method with arguments annotated with @RequestParam, like this:
@RequestParam
@GetMapping(produces = MediaType.TEXT_HTML_VALUE) public ModelAndView showAsHtml(final @RequestParam("q") String query, final @RequestParam(value = "offset", defaultValue = "0") Long offset, final Locale locale) { // do stuff }
Now I build an Affordance that is an URI template:
AffordanceBuilder.linkTo(AffordanceBuilder.methodOn(MyController.class) .showAsHtml(null, null, null)) .rel("something") ...;
The serialized hydra:IriTemplate will look like this:
{ "@type": "hydra:IriTemplate", "hydra:template": "http://localhost:8080/something{?query}", "hydra:mapping": [ { "@type": "hydra:IriTemplateMapping", "hydra:variable": "query", "hydra:required": true, "hydra:property": "query" } ] }
So the variable "query" is wrong. It should be "q" as defined by the @RequestParam.
The text was updated successfully, but these errors were encountered:
fixed as of 0.4.1
Sorry, something went wrong.
dschulten
No branches or pull requests
I have a controller method with arguments annotated with
@RequestParam
, like this:Now I build an Affordance that is an URI template:
The serialized hydra:IriTemplate will look like this:
So the variable "query" is wrong. It should be "q" as defined by the
@RequestParam
.The text was updated successfully, but these errors were encountered: