Datatable with 'f:facet' fixed when scrolling !

UI Components for JSF
Post Reply
User avatar
neijunior
Posts: 74
Joined: 15 Jul 2010, 04:46
Location: São Paulo - Brasil

01 Feb 2012, 21:32

Consider the following image and code:

Image

Code: Select all

<pou:dataTable id="dtbTest"
               widgetVar="wgvDtbTest"
               value="#{mbTest.listName}"
               var="name"
               rowKey="#{name}"
               scrollable="true" 
               scrollWidth="505">

    <f:facet name="header">
        <pou:toolbar>

            <pou:toolbarGroup align="left">
                <pou:commandButton value="Update"/>
            </pou:toolbarGroup>

            <pou:toolbarGroup align="right">
                <h:panelGroup>
                    <h:outputText value="Filter" />
                    <h:inputText id="globalFilter"
                                 onkeyup="wgvDtbTest.filter()"/>
                </h:panelGroup>
            </pou:toolbarGroup>

        </pou:toolbar>  
    </f:facet>

    <pou:column headerText="Name"
                style="width: 650px;"
                filterBy="#{name}"
                filterMatchMode="contains"
                filterStyle="width: 100%;">
        <h:outputText value="#{name}"/>
    </pou:column>

</pou:dataTable>
I have an "f: facet name =''header" that holds a "pou:toolbar" so I can make a button on the left and right side of the global filter.
I want to leave the option to "scroll", but do not want the "f: facet" is at the scroll, I want it to be fixed and scroll lines only.

Does anyone know a way to do this ?

Thanks
Last edited by neijunior on 13 Mar 2012, 16:21, edited 1 time in total.
Mojarra 2.2.x, Facelets, Glassfish V4.1, Primefaces 5.1, Eclipse Mars 1, JPA 2, EJB 3

Nei Alcantara Jr.
http://twitter.com/NeiAlcantaraJr

User avatar
neijunior
Posts: 74
Joined: 15 Jul 2010, 04:46
Location: São Paulo - Brasil

02 Feb 2012, 16:10

I inspected the css of the dataTable, I saw that when has some divs "scroll=true", I tried to make the div fixed the header, but without success.

Does anyone have other sugestion ?
Mojarra 2.2.x, Facelets, Glassfish V4.1, Primefaces 5.1, Eclipse Mars 1, JPA 2, EJB 3

Nei Alcantara Jr.
http://twitter.com/NeiAlcantaraJr

danilo.magrini
Posts: 92
Joined: 30 Mar 2011, 22:57

13 Mar 2012, 14:45

hi @neijunior! Did you solve this issue? I think that the header should not scrolling...
PrimeFaces 7.0.8 | Payara 5 | Mojarra 2.4.x
Ubuntu, Firefox

User avatar
neijunior
Posts: 74
Joined: 15 Jul 2010, 04:46
Location: São Paulo - Brasil

13 Mar 2012, 15:30

Hi danilo.magrini

No, I still not resolve this issue.
I tested add the "p:toolBar" in "f:facet name="footer" and he was right, does not has scroll. The header should stay so too.
Mojarra 2.2.x, Facelets, Glassfish V4.1, Primefaces 5.1, Eclipse Mars 1, JPA 2, EJB 3

Nei Alcantara Jr.
http://twitter.com/NeiAlcantaraJr

danilo.magrini
Posts: 92
Joined: 30 Mar 2011, 22:57

13 Mar 2012, 15:56

Will you open an issue?
PrimeFaces 7.0.8 | Payara 5 | Mojarra 2.4.x
Ubuntu, Firefox

User avatar
neijunior
Posts: 74
Joined: 15 Jul 2010, 04:46
Location: São Paulo - Brasil

13 Mar 2012, 17:06

I opened an issue, here's the link:

http://code.google.com/p/primefaces/iss ... il?id=3716
Mojarra 2.2.x, Facelets, Glassfish V4.1, Primefaces 5.1, Eclipse Mars 1, JPA 2, EJB 3

Nei Alcantara Jr.
http://twitter.com/NeiAlcantaraJr

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 25 guests