protected int before(Writer out) throws Exception { super.before(out); UiUtil.writeOpenStartTag(out, "tbody"); UiUtil.writeAttribute(out, "id", globalId); UiUtil.writeCloseStartTag(out); return EVAL_BODY_INCLUDE; }
protected int after(Writer out) throws Exception { UiUtil.writeEndTag(out, "form"); // Continue super.after(out); return EVAL_PAGE; }
protected int after(Writer out) throws Exception { UiUtil.writeEndTag(out, "tbody"); return super.after(out); }
protected int before(Writer out) throws Exception { super.before(out); // Error check if (getAttribute(ID_KEY_REQUEST, PageContext.REQUEST_SCOPE) != null) throw new UiException("System form cannot be nested"); // Compute id id = id == null ? UiSystemFormTag.generateId(pageContext) : id; pushAttribute(ID_KEY_REQUEST, id, PageContext.REQUEST_SCOPE); pushAttribute(SYSTEM_FORM_ID_KEY, id, PageContext.REQUEST_SCOPE); // Write form UiUtil.writeOpenStartTag(out, "form"); UiUtil.writeAttribute(out, "id", id); UiUtil.writeAttribute(out, "name", id); UiUtil.writeAttribute(out, "method", method); UiUtil.writeAttribute(out, "enctype", enctype); UiUtil.writeAttribute(out, "accept-charset", getAcceptCharset()); UiUtil.writeAttribute(out, "action", getFormAction()); UiUtil.writeAttribute(out, "style", "margin: 0px"); UiUtil.writeCloseStartTag(out); // Script // Initialize the uiProperties object for this systemform // This object will store validators for UiLib forms contained in this systemform. UiUtil.writeOpenStartTag(out, "script"); UiUtil.writeAttribute(out, "type", "text/javascript"); UiUtil.writeCloseStartTag(out); out.write("uiSystemFormContext("); UiUtil.writeScriptString(out, id); out.write(");\n"); UiUtil.writeEndTag(out, "script"); // Continue return EVAL_BODY_INCLUDE; }