JARCH SHOWCASE
JARCH SHOWCASE
DataTable - Header and Footer Header and Footer section are defined using facets.
List of Cars
IdYearBrandColor
e7c34ebb2004AudiOrange
5ec5a9d11998MercedesWhite
4d06c3ce1993JaguarRed
eb625b881990BMWYellow
7b6821232002BMWYellow
a32d8f161962HondaBrown
aab51d0b1983AudiBlue
278ff9372005FiatMaroon
0912573f1989FiatBrown
e29409e31964FiatMaroon
<a:dataTable var="car" value="#{dtBasicView.cars}">
    <f:facet name="header">
        List of Cars
    </f:facet>

    <a:column headerText="Id">
        <h:outputText value="#{car.id}" />
    </a:column>

    <a:column headerText="Year">
        <h:outputText value="#{car.year}" />
    </a:column>

    <a:column headerText="Brand">
        <h:outputText value="#{car.brand}" />
    </a:column>

    <a:column headerText="Color">
        <h:outputText value="#{car.color}" />
    </a:column>

    <f:facet name="footer">
        In total there are #{fn:length(dtBasicView.cars)} cars.
    </f:facet>
</a:dataTable>
                
JARCH, Copyright © 2022 All rights reserved. Running JARCH 24.3.0-SNAPSHOT on PrimeFaces-12.0.0 on Mojarra-2.3.13.