> On 09.09.2016, at 15:59, Cheng Bao <[email protected]> wrote:
> 
> However, what to do next? without StaplerRequest and StaplerResponse 
> parameters, after processing, how can display certain jelly file? how can I 
> make redirection to another url?
> How can I get query parameters as /foo/bar?query=xx?
> How can I get more part of url as /foo/bar1/bar2?

The object you return can have a doIndex method, or an index.jelly view. Or, in 
the /foo/bar1/bar2 example, a bar2.jelly view.

I actually gave a presentation on this just a few days ago, and the recording 
is at https://www.youtube.com/watch?v=iAJBKFe8mMo

You can access the current request object without changing your method 
signature using the static Stapler.currentRequest() method.

Likewise with the response -- you should also be able to return and/or throw a 
HttpResponse (there are predefined ones in HttpResponses) to redirect.

Daniel

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-dev/9E1CF2F1-B21C-4B13-B8F8-CE0D81F88D06%40beckweb.net.
For more options, visit https://groups.google.com/d/optout.

Reply via email to