Locale

Change the locale of the datepicker, schedule and client side validation messages.

Language
English
English
English
French
German
German
German
Italian
Korean
Spanish
Catalan
Dutch
Portuguese
Portuguese
Arabic
Arabic
Bulgarian
Bangla
Bosnian
Czech
Greek
Estonian
Persian
Finnish
Danish
Hindi
Indonesian
Icelandic
Croatian
Japanese
Hungarian
Hebrew
Georgian
Central Kurdish
Khmer
Kyrgyz
Kazakh
Lithuanian
Latvian
Malay
Norwegian
Polish
Romanian
Russian
Slovak
Slovenian
Serbian
Serbian
Swedish
Thai
Turkish
Ukrainian
Uzbek
Vietnamese
Chinese
Chinese

Input Style

Themes

PrimeUIX
Aura Light Emerald Aura Light Emerald
Aura Dark Emerald Aura Dark Emerald
PrimeOne
Saga Blue Saga Blue
Vela Blue Vela Blue
Arya Blue Arya Blue
Bootstrap
Bootstrap Blue Light Bootstrap Blue Light
Bootstrap Purple Light Bootstrap Purple Light
Bootstrap Blue Dark Bootstrap Blue Dark
Bootstrap Purple Dark Bootstrap Purple Dark
Material Design
Material Indigo Light Material Indigo Light
Material Deep Purple Light Material Deep Purple Light
Material Indigo Dark Material Indigo Dark
Material Deep Purple Dark Material Deep Purple Dark
Material Design Compact
Material Compact Indigo Light Material Compact Indigo Light
Material Compact Deep Purple Light Material Compact Deep Purple Light
Material Compact Indigo Dark Material Compact Indigo Dark
Material Compact Deep Purple Dark Material Compact Deep Purple Dark
Legacy
Nova Light Nova Light
Nova Dark Nova Dark
Nova Colored Nova Colored
Luna Amber Luna Amber
Luna Blue Luna Blue
Luna Green Luna Green
Luna Pink Luna Pink

DataView Basic

DataView displays data in grid or list layout.

DataView Tag Documentation

DataView displays data in grid or list layout.

NameTypeRequiredDefaultDescription
id String false generated Unique identifier of the component in a namingContainer.
rendered boolean false true Boolean value to specify the rendering of the component, when set to false component will not be rendered.
binding UIComponent false generated An EL expression referring to a server side UIComponent instance in a backing bean.
widgetVar String false generated ('widget_' + componentClientId) Name of the client side widget.
currentPageReportTemplate String false ({currentPage} of {totalPages}) Template of the currentPageReport UI.
emptyMessage String false i18n Text to display when there is no data to display.
first int false 0 Index of the first data to display.
flex Boolean false Use modern FlexGrid CSS for this component.
gridIcon String false Icon to display for grid layout toggle button.
gridRowStyle String false Inline style of each row (grid-cell) in grid layout.
gridRowStyleClass String false Style class of each row (grid-cell) in grid layout.
layout String false list Layout of the items, valid values are "list" and "grid".
lazy boolean false True, if the value-binding is instance of LazyDataModel. Defines if lazy loading is enabled for the data component.
listIcon String false Icon to display for list layout toggle button.
multiViewState boolean false false Whether to keep component state across views.
pageLinks int false 10 Maximum number of page links to display.
paginator boolean false false Enables pagination.
paginatorAlwaysVisible boolean false true Defines if paginator should be hidden if total data count is less than number of rows per page.
paginatorPosition String false bottom Position of the paginator.
paginatorTemplate String false {FirstPageLink} {PreviousPageLink} {PageLinks} {NextPageLink} {LastPageLink} {RowsPerPageDropdown} Template of the paginator.
rowIndexVar String false Name of iterator to refer each row index.
rowStatePreserved boolean false false Keeps state of its children on a per-row basis.
rowTitle String false Title for each row.
rows int false 0 Number of rows to display per page. Default value is 0 meaning to display all data available.
rowsPerPageTemplate String false Template of the rowsPerPage dropdown.
style String false Inline style of the component.
styleClass String false Style class of the component.
touchable Boolean false Enable touch if supported by device. NULL uses global default or primefaces.TOUCHABLE. Default: globally enabled.
value Object true Datasource of the component.
var String true Name of the iterator variable that references each element in the data set.
Loading...
Tag DocumentationNew DocumentationNew Documentation JSDoc Basic MultiViewState Lazy Responsive
ui-button
ui-button
  • Painted Phone Case
    Product Description
    Accessories
    $56.00 In Stock
  • Gaming Set
    Product Description
    Electronics
    $299.00 In Stock
  • Purple T-Shirt
    Product Description
    Clothing
    $49.00 Low Stock
  • Yoga Set
    Product Description
    Fitness
    $20.00 In Stock
  • Gaming Set
    Product Description
    Electronics
    $299.00 In Stock
  • Lime Band
    Product Description
    Fitness
    $79.00 In Stock
  • Gold Phone Case
    Product Description
    Accessories
    $24.00 Out of Stock
  • Black Watch
    Product Description
    Accessories
    $72.00 In Stock
  • Yoga Mat
    Product Description
    Fitness
    $20.00 In Stock
  • Pink Band
    Product Description
    Fitness
    $79.00 In Stock
  • Light Green T-Shirt
    Product Description
    Clothing
    $49.00 In Stock
  • Black Watch
    Product Description
    Accessories
    $72.00 In Stock

Usage


<div class="card product">
    <h:form id="form">
        <p:dataView var="product" value="#{dataGridView.products}" rows="12" paginator="true"
                    rowsPerPageTemplate="6,12,16"
                    paginatorTemplate="{CurrentPageReport} {FirstPageLink} {PreviousPageLink} {PageLinks} {NextPageLink} {LastPageLink} {RowsPerPageDropdown}"
                    gridIcon="pi pi-th-large" listIcon="pi pi-bars">

            <p:dataViewGridItem>
                <div class="product-grid-item card border-1">
                    <div class="product-grid-item-top">
                        <div>
                            <i class="pi pi-tag product-category-icon"/>
                            <span class="product-category">#{product.category}</span>
                        </div>
                        <span class="product-badge status-#{product.inventoryStatus.name().toLowerCase()}">#{product.inventoryStatus.text}</span>
                    </div>
                    <div class="product-grid-item-content">
                        <p:graphicImage name="images/product/#{product.image}" library="demo"/>
                        <div class="product-name">#{product.name}</div>
                        <div class="product-description">#{product.description}</div>
                        <p:rating readonly="true" value="#{product.rating}"/>
                    </div>
                    <div class="product-grid-item-bottom">
                        <h:outputText value="#{product.price}" styleClass="product-price">
                            <f:convertNumber currencySymbol="$" type="currency"/>
                        </h:outputText>
                        <p:commandButton type="button"
                                            value="Add To Cart"
                                            icon="pi pi-shopping-cart"
                                            disabled="#{product.inventoryStatus == 'OUTOFSTOCK'}">
                        </p:commandButton>
                    </div>
                </div>
            </p:dataViewGridItem>

            <p:dataViewListItem>
                <div class="product-list-item">
                    <p:graphicImage name="demo/images/product/#{product.image}"/>
                    <div class="product-list-detail">
                        <div class="product-name">#{product.name}</div>
                        <div class="product-description">#{product.description}</div>
                        <p:rating readonly="true" value="#{product.rating}"/>
                        <i class="pi pi-tag product-category-icon"/><span
                            class="product-category">#{product.category}</span>
                    </div>
                    <div class="product-list-action">
                        <h:outputText value="#{product.price}" styleClass="product-price">
                            <f:convertNumber currencySymbol="$" type="currency"/>
                        </h:outputText>
                        <p:commandButton type="button"
                                         value="Add To Cart"
                                         icon="pi pi-shopping-cart"
                                         disabled="#{product.inventoryStatus == 'OUTOFSTOCK'}">
                        </p:commandButton>
                        <span class="product-badge status-#{product.inventoryStatus.name().toLowerCase()}">#{product.inventoryStatus.text}</span>
                    </div>
                </div>
            </p:dataViewListItem>
        </p:dataView>
    </h:form>
</div>