DataScroller - Basic DataScroller displays data with on demand loading using scroll.
Scroll Down to Load More Cars
  • Id: 5cd61fc8
    Year: 1966
    Color: Green
  • Id: 1ea40359
    Year: 1996
    Color: Silver
  • Id: d55ed9f1
    Year: 2002
    Color: Yellow
  • Id: 26e3da5b
    Year: 1989
    Color: Brown
  • Id: 4a26b3c5
    Year: 1995
    Color: White
  • Id: 6fd6cd1b
    Year: 2007
    Color: Red
  • Id: 9c071246
    Year: 1984
    Color: Yellow
  • Id: 33c8892e
    Year: 1965
    Color: Yellow
  • Id: e89ce790
    Year: 1966
    Color: Maroon
  • Id: 0a04a0e9
    Year: 1973
    Color: Maroon
<h:form> 
    <p:dataScroller value="#{dataScrollerView.cars}" var="car" chunkSize="10">
        <f:facet name="header">
            Scroll Down to Load More Cars
        </f:facet>

        <h:panelGrid columns="2" style="width:100%" columnClasses="logo,detail">
            <p:graphicImage name="demo/images/car/#{car.brand}-big.gif" /> 

            <p:outputPanel>
                <h:panelGrid columns="2" cellpadding="5">
                    <h:outputText value="Id:" />
                    <h:outputText value="#{car.id}" style="font-weight: bold"/>

                    <h:outputText value="Year:" />
                    <h:outputText value="#{car.year}" style="font-weight: bold"/>

                    <h:outputText value="Color:" />
                    <h:outputText value="#{car.color}" style="font-weight: bold"/>
                </h:panelGrid>
            </p:outputPanel>
        </h:panelGrid>
    </p:dataScroller>
</h:form>
                
PrimeTek, Copyright © 2017
All rights reserved.
Running PrimeFaces-6.2-SNAPSHOT on Mojarra-2.3.2.