Author: hoang_to
Date: 2009-11-18 02:41:24 -0500 (Wed, 18 Nov 2009)
New Revision: 633
Modified:
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/account/webui/component/UIRegisterForm.java
portal/trunk/web/portal/src/main/webapp/groovy/webui/form/UIFormWithTitle.gtmpl
Log:
GTNPORTAL-244: Switch from UIForm.gtmpl to UIFormWithTitle.gtmpl
Modified:
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/account/webui/component/UIRegisterForm.java
===================================================================
---
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/account/webui/component/UIRegisterForm.java 2009-11-18
07:34:41 UTC (rev 632)
+++
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/account/webui/component/UIRegisterForm.java 2009-11-18
07:41:24 UTC (rev 633)
@@ -46,7 +46,7 @@
@ComponentConfig(
lifecycle = UIFormLifecycle.class,
- template = "system:/groovy/webui/form/UIForm.gtmpl",
+ template = "system:/groovy/webui/form/UIFormWithTitle.gtmpl",
events = {
@EventConfig( listeners = UIRegisterForm.SubscribeActionListener.class),
@EventConfig( listeners = UIRegisterForm.ResetActionListener.class, phase =
Phase.DECODE),
Modified: portal/trunk/web/portal/src/main/webapp/groovy/webui/form/UIFormWithTitle.gtmpl
===================================================================
---
portal/trunk/web/portal/src/main/webapp/groovy/webui/form/UIFormWithTitle.gtmpl 2009-11-18
07:34:41 UTC (rev 632)
+++
portal/trunk/web/portal/src/main/webapp/groovy/webui/form/UIFormWithTitle.gtmpl 2009-11-18
07:41:24 UTC (rev 633)
@@ -1,4 +1,7 @@
-<% String fieldName; %>
+<%
+ import org.exoplatform.webui.form.UIFormInputBase;
+
+ String fieldName; %>
<div class="UIFormWithTitle $uicomponent.id"
onkeypress="javascript:SubmitAction.call(this, event);">
<div class="TitleBar"><%=_ctx.appRes(uicomponent.getName() +
".title")%></div>
<% uiform.begin() %>
@@ -11,13 +14,13 @@
%>
<tr>
<%fieldName = uicomponent.getLabel(field.getName());%>
- <%if(!fieldName.equals(uicomponent.getId())) { %>
+ <%if(field instanceof UIFormInputBase &&
!fieldName.equals(uicomponent.getId())) { %>
<td class="FieldLabel">
<%if(fieldName != null && fieldName.length() > 0) {%>
<%=uicomponent.getLabel(field.getName()) %>
<%}%>
</td>
- <% if(field.isEditable()) { %>
+ <% if(field instanceof UIFormInputBase && field.isEditable()) {
%>
<td class="FieldComponent"><% uiform.renderField(field)
%></td>
<% }else { %>
<td class="NonEditableField"><% uiform.renderField(field)
%></td>
Show replies by date