ajaxParams.put("_action", expr);
} catch (JSONException e) {
throw new RuntimeException(e);
}
}
automaticChangeHandler = new ScriptBuilder().functionCall("O$._ajaxReload",
initializer.getRenderArray(context, this, render),
ajaxParams).semicolon().append("return false;");
} else {
MethodExpression actionExpression = getActionExpression();
if (actionExpression != null) {
automaticChangeHandler = new ScriptBuilder().functionCall("O$.submitWithParam",
new ScriptBuilder().O$(chart), getActionFieldName(), "true");
}
}
onchange = Rendering.joinScripts(onchange,
automaticChangeHandler != null ? automaticChangeHandler.toString() : null);
ScriptBuilder buf = new ScriptBuilder().initScript(context, chart, "O$.Chart._initSelection", onchange);
Rendering.renderInitScript(context, buf,
Resources.utilJsURL(context),
Resources.internalURL(context, "chart/chart.js"));
AjaxUtil.renderJSLinks(context);