myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Leonardo Uribe (JIRA)" <>
Subject [jira] Commented: (MYFACES-1727) h:column footerClass and headerClass does not work (issue 4 of JSR 252)
Date Mon, 17 Sep 2007 04:32:32 GMT


Leonardo Uribe commented on MYFACES-1727:

I can see the problem on class (I'm working on myfaces-shared-3.0.1-SNAPSHOT):


    protected void renderColumnChildHeaderOrFooterRow(FacesContext facesContext,
        ResponseWriter writer, UIComponent uiComponent, String styleClass, boolean isHeader)
throws IOException
        if (uiComponent instanceof UIColumn)
            // allow column to override style class, new in JSF 1.2
            if (uiComponent instanceof HtmlColumn) {
                HtmlColumn column = (HtmlColumn)uiComponent;
                if (isHeader && column.getHeaderClass()!=null)
                    styleClass = column.getHeaderClass();
                else if (!isHeader && column.getFooterClass()!=null)
                    styleClass = column.getFooterClass();

But probing it, at this point or render phase all colums are children of UIColumn, so the
code is never executed. 
The code is well done, this should not happen. It should receive an instance of HtmlColumn
if I send this code:

				<h:dataTable id="data" styleClass="standardTable"
					var="country" value="#{countryList.countries}">
					<h:column headerClass="customTable_header" footerClass="customTable_footer">
						<f:facet name="header">
							<h:outputText value="#{example_messages['label_country_name']}" />
						<h:commandLink action="go_country" immediate="true">
							<h:outputText value="#{}" />
						<f:facet name="footer">
						    <h:outputText value="FOOTER"/>

						<f:facet name="header">
							<h:outputText value="#{example_messages['label_country_iso']}" />
						<h:outputText value="#{country.isoCode}" />

						<f:facet name="header">
							<h:outputText value="#{example_messages['label_country_cities']}" />
						<h:dataTable id="cities" styleClass="standardTable_Column"
							var="city" value="#{country.cities}">
								<h:outputText value="#{city}" style="font-size: 11px" />

 I'm probing on an environment with facelets 1.1.13 + myfaces 1.2.1-SNAPSHOT + trinidad-1.2.2-SNAPSHOT
(in order to probe myfaces core with a common configuration).

I have checked standard-faces-config.xml and h.tld and all are fine.

Any suggestions?

Att: Leonardo Uribe

> h:column footerClass and headerClass does not work (issue 4 of JSR 252)
> -----------------------------------------------------------------------
>                 Key: MYFACES-1727
>                 URL:
>             Project: MyFaces Core
>          Issue Type: Bug
>          Components: JSR-252
>    Affects Versions:  1.2.0, 1.2.1-SNAPSHOT
>         Environment: Tomcat 6 on Windows XP
>            Reporter: Leonardo Uribe
> When I tried to define headerClass and footerClass property on h:column, does not override
h:dataTable headerClass and footerClass
> I will send a patch to resolve this issue soon.
> Att: Leonardo Uribe

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message