{
StringBuilder b = new StringBuilder();
//TODO: Tung.Pham modified
//------------------------
b.append("javascript:");
WebuiRequestContext rcontext = WebuiRequestContext.getCurrentInstance();
UIComponent subComponent = findComponentById(componentId);
org.exoplatform.webui.config.Event event = subComponent.getComponentConfig().getUIComponentEventConfig(name);
if (event == null)
return "??config??";
String confirm = event.getConfirm();
if (confirm != null && confirm.trim().length() > 0)
{
confirm = rcontext.getApplicationResourceBundle().getString(confirm);
b.append("if(confirm('").append(confirm.replaceAll("'", "\\\\'")).append("'))");
}
b.append("eXo.webui.UIForm.submitEvent('").append(getFormId()).append("','");
//b.append("javascript:eXo.webui.UIForm.submitEvent('").append(getId()).append("','");
//-------------------------