@JavaScriptMethod
public HttpResponse render() {
return new HttpResponse() {
public void generateResponse(StaplerRequest req, StaplerResponse rsp, Object node) throws IOException, ServletException {
try {
new DefaultScriptInvoker() {
@Override
protected JellyContext createContext(StaplerRequest req, StaplerResponse rsp, Script script, Object it) {
JellyContext context = super.createContext(req, rsp, script, it);
for (int i=bodyStack.length-1; i>0; i--) {// exclude bodyStack[0]
context = new JellyContext(context);