Author: jholmes
Date: Wed Aug 1 09:02:23 2007
New Revision: 561850
URL: http://svn.apache.org/viewvc?view=rev&rev=561850
Log:
WW-2080 actionError, actionMessage and fieldError Freemarker templates do not
honor the cssClass and cssStyle attributes
Modified:
struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionerror.ftl
struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionmessage.ftl
struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/fielderror.ftl
Modified:
struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionerror.ftl
URL:
http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionerror.ftl?view=diff&rev=561850&r1=561849&r2=561850
==============================================================================
---
struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionerror.ftl
(original)
+++
struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionerror.ftl
Wed Aug 1 09:02:23 2007
@@ -23,7 +23,16 @@
<#if (actionErrors?exists && actionErrors?size > 0)>
<ul>
<#list actionErrors as error>
- <li><span class="errorMessage">${error}</span></li>
+ <li><span<#rt/>
+<#if parameters.cssClass?exists>
+ class="${parameters.cssClass?html}"<#rt/>
+<#else>
+ class="errorMessage"<#rt/>
+</#if>
+<#if parameters.cssStyle?exists>
+ style="${parameters.cssStyle?html}"<#rt/>
+</#if>
+>${error}</span></li>
</#list>
</ul>
</#if>
Modified:
struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionmessage.ftl
URL:
http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionmessage.ftl?view=diff&rev=561850&r1=561849&r2=561850
==============================================================================
---
struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionmessage.ftl
(original)
+++
struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/actionmessage.ftl
Wed Aug 1 09:02:23 2007
@@ -23,7 +23,16 @@
<#if (actionMessages?exists && actionMessages?size > 0)>
<ul>
<#list actionMessages as message>
- <li><span class="actionMessage">${message}</span></li>
+ <li><span<#rt/>
+<#if parameters.cssClass?exists>
+ class="${parameters.cssClass?html}"<#rt/>
+<#else>
+ class="actionMessage"<#rt/>
+</#if>
+<#if parameters.cssStyle?exists>
+ style="${parameters.cssStyle?html}"<#rt/>
+</#if>
+>${message}</span></li>
</#list>
</ul>
</#if>
Modified:
struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/fielderror.ftl
URL:
http://svn.apache.org/viewvc/struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/fielderror.ftl?view=diff&rev=561850&r1=561849&r2=561850
==============================================================================
---
struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/fielderror.ftl
(original)
+++
struts/struts2/branches/STRUTS_2_0_X/core/src/main/resources/template/simple/fielderror.ftl
Wed Aug 1 09:02:23 2007
@@ -37,7 +37,16 @@
<#assign doneStartUlTag=true><#t/>
</#if><#t/>
<#list eValue as eEachValue><#t/>
- <li><span
class="errorMessage">${eEachValue}</span></li>
+ <li><span<#rt/>
+<#if parameters.cssClass?exists>
+ class="${parameters.cssClass?html}"<#rt/>
+<#else>
+ class="errorMessage"<#rt/>
+</#if>
+<#if parameters.cssStyle?exists>
+ style="${parameters.cssStyle?html}"<#rt/>
+</#if>
+>${eEachValue}</span></li>
</#list><#t/>
</#if><#t/>
</#list><#t/>
@@ -46,13 +55,22 @@
</ul>
<#assign doneEndUlTag=true><#t/>
</#if><#t/>
-<#else><#t/>
+<#else><#t/>
<#if (eKeysSize > 0)><#t/>
<ul>
<#list eKeys as eKey><#t/>
<#assign eValue = fieldErrors[eKey]><#t/>
<#list eValue as eEachValue><#t/>
- <li><span
class="errorMessage">${eEachValue}</span></li>
+ <li><span<#rt/>
+<#if parameters.cssClass?exists>
+ class="${parameters.cssClass?html}"<#rt/>
+<#else>
+ class="errorMessage"<#rt/>
+</#if>
+<#if parameters.cssStyle?exists>
+ style="${parameters.cssStyle?html}"<#rt/>
+</#if>
+>${eEachValue}</span></li>
</#list><#t/>
</#list><#t/>
</ul>