<% String fieldName; %>
<div class="UIForm $uicomponent.id">
  <%uiform.begin()%>
  <div class="HorizontalLayout">
    <div class="FormContainer">
      <table class="UIFormGrid">
        <%
          for(field in uiform.getChildren()) {
            if(field.isRendered()) {
        %>
              <tr>
                <%fieldName = uicomponent.getLabel(field.getName());%>
                <%
                  if(fieldName != null && fieldName.length() > 0 && !fieldName.equals(uicomponent.getId())) {
                %>
                  <td class="FieldLabel">
                      <%=uicomponent.getLabel(field.getName()) %>
                  </td>
                  <td class="FieldComponent"><% uiform.renderField(field) %></td>
                <%} else {%>
                  <td class="FieldComponent" colspan="2"><% uiform.renderField(field) %></td>
                <%}%>
              </tr>
        <%
            }
          }
        %>
      </table>
      <script>
        titleField = document.getElementById("title");
        titleField.onchange = function() { eXo.ecm.SELocalization.cleanName(this.value, "name"); } ;
      </script>
      <div class="UIAction">
	      <% for(action in uicomponent.getActions()) {
	           String actionLabel = _ctx.appRes(uicomponent.getName() + ".action." + action);
	           String link = uicomponent.event(action);
	      %>
          <a href="javascript:void(0);" onclick="$link" class="ActionButton LightBlueStyle">$actionLabel</a>
	      <%}%>
      </div>
    </div>
  </div>
  <%uiform.end()%>
</div>