1 Reply Latest reply on Jun 24, 2011 4:44 AM by kardanov

    Problems with <rich:columnGroup>.

    kardanov

      Hello, I try to use <rich:columnGroup> to create complex header for my table exactly the same as it is described in the example here:

      http://docs.jboss.org/richfaces/latest_3_3_X/en/devguide/html/rich_columnGroup.html

       

      Here is part of my code:

       

      <f:facet name="header">
           <rich:columnGroup>
                <rich:column rowspan="2">
                     <h:outputText value=" " />
                </rich:column>
                <rich:column rowspan="2">
                     <h:panelGroup>
                          <a4j:commandLink value="Nationality" styleClass="text1" render="sensorStateTable"
                               action="#{sensorStateSortingBean.sortByNationality}" />
                           
                          <h:inputText value="#{sensorStateFilteringBean.nationalityFilter}" style="width:40;">
                               <a4j:ajax event="blur" render="sensorStateForm:sensorStateTable" execute="@this" />
                          </h:inputText>
                     </h:panelGroup>
                 </rich:column>
                 <rich:column rowspan="2">
                      <h:panelGroup>
                           <a4j:commandLink value="Chassis Number" styleClass="text1" render="sensorStateTable"
                                action="#{sensorStateSortingBean.sortByChassisNumber}" />
                            
                           <h:inputText value="#{sensorStateFilteringBean.chassisNumberFilter}" style="width:40;">
                                <a4j:ajax event="blur" render="sensorStateForm:sensorStateTable" execute="@this" />
                           </h:inputText>
                      </h:panelGroup>
                  </rich:column>
                  <rich:column rowspan="2">
                       <h:panelGroup>
                            <a4j:commandLink value="Licence Plate" styleClass="text1" render="sensorStateTable"
                                 action="#{sensorStateSortingBean.sortByLicencePlate}" />
                             
                            <h:inputText value="#{sensorStateFilteringBean.licencePlateFilter}" style="width:40;">
                                 <a4j:ajax event="blur" render="sensorStateForm:sensorStateTable" execute="@this" />
                            </h:inputText>
                       </h:panelGroup>
                  </rich:column>
      
                  <rich:column colspan="6">
                       <h:outputText value="Temperatures" styleClass="text1" />
                  </rich:column>
                  <rich:column breakBefore="true">
                       <h:outputText value="0" styleClass="text1" />
                  </rich:column>
                  <rich:column>
                       <h:outputText value="2" styleClass="text1" />
                  </rich:column>
                  <rich:column>
                       <h:outputText value="3" styleClass="text1" />
                  </rich:column>
                  <rich:column>
                       <h:outputText value="4" styleClass="text1" />
                  </rich:column>
                  <rich:column>
                       <h:outputText value="5" styleClass="text1" />
                  </rich:column>
                  <rich:column>
                       <h:outputText value="6" styleClass="text1" />
                  </rich:column>
               </rich:columnGroup>
       </f:facet>
      

       

      As you can see, there're few columns with (a kind of) complex headers (with filtering and sorting), and one big header (6 columns) with subheaders.

      It looks almost the same as it is in the example in RichFaces docs.

      Here is screenshot of my table:

      1.JPG

       

      As you can see 6 columns are displayed separately, not as sub columns of the Temperatures column.

       

      Any ideas about the problem?

      Any help will be highly appreciated.