1 Reply Latest reply on Jan 10, 2012 4:00 AM by Ugur Dincer

    rextendedDataTable selectionchange

    Ugur Dincer Newbie

      Hi,

       

      Using richfaces 4.0.0 Final and have following issue: First time I select an item in the resellersTable the serviceProvidersTable and the other tables beside that are expanded while I select an item.

       

      If I then re-select the first item in the resellersTable the tables beside  serviceProvidersTable are cleared or deselected but item in serviceProvidersTable remains selected.

       

      I would like to know how to reset or clear previous selectections in tables the right of resellersTable.

       

      <h:form id="fm1">

                                    <rich:collapsiblePanel id="collapsiblePanel"

                                              header="#{navigationBean.crumbsHeader}" switchType="ajax">

                                              <h:panelGrid id="navigationPanelGrid" width="auto" columns="4"

                                                        rowClasses="panelGrid">

                                                        <rich:panel>

                                                                  <f:facet name="header">

                                                                            <h:outputText value="#{msg['general.resellers.title']}" />

                                                                  </f:facet>

                                                                  <rich:extendedDataTable id="resellersTable" var="reseller"

                                                                            value="#{navigationBean.resellers}" styleClass="stable2">

                                                                            <a4j:ajax execute="@fm1" event="selectionchange"

                                                                                      listener="#{navigationBean.resellerSelectionListener}"

                                                                                      render="serviceProvidersTable" />

                                                                            <rich:column>

                                                                                      <h:outputText value="#{reseller.userDetails.displayName}" />

                                                                            </rich:column>

                                                                  </rich:extendedDataTable>

                                                        </rich:panel>

                                                        <a4j:outputPanel ajaxRendered="true">

                                                                  <rich:panel>

                                                                            <f:facet name="header">

                                                                                      <h:outputText value="#{msg['general.service.providers.title']}" />

                                                                            </f:facet>

                                                                            <rich:extendedDataTable id="serviceProvidersTable" width="auto"

                                                                                      var="serviceProvider" value="#{navigationBean.serviceProviders}"

                                                                                      rendered="#{navigationBean.resellerSelected}"

                                                                                      styleClass="stable2">

                                                                                      <a4j:ajax execute="@fm1" event="selectionchange"

                                                                                                listener="#{navigationBean.serviceProviderSelectionListener}"

                                                                                                render="issuerGroupsTable" />

                                                                                      <rich:column>

                                                                                                <h:outputText

                                                                                                          value="#{serviceProvider.userDetails.displayName}" />

                                                                                      </rich:column>

                                                                            </rich:extendedDataTable>

                                                                  </rich:panel>

                                                        </a4j:outputPanel>

                                                        <a4j:outputPanel ajaxRendered="true">

                                                                  <rich:panel>

                                                                            <f:facet name="header">

                                                                                      <h:outputText value="#{msg['general.issuer.groups.title']}" />

                                                                            </f:facet>

                                                                            <rich:extendedDataTable id="issuerGroupsTable" width="auto"

                                                                                      var="issuerGroup" value="#{navigationBean.issuerGroups}"

                                                                                      rendered="#{navigationBean.serviceProviderSelected}"

                                                                                      styleClass="stable2">

                                                                                      <a4j:ajax execute="@fm1" event="selectionchange"

                                                                                                listener="#{navigationBean.issuerGroupSelectionListener}"

                                                                                                render="issuersTable" />

                                                                                      <rich:column>

                                                                                                <h:outputText value="#{issuerGroup.userDetails.displayName}" />

                                                                                      </rich:column>

                                                                            </rich:extendedDataTable>

                                                                  </rich:panel>

                                                        </a4j:outputPanel>

                                                        <a4j:outputPanel ajaxRendered="true">

                                                                  <rich:panel>

                                                                            <f:facet name="header">

                                                                                      <h:outputText value="#{msg['general.issuers.title']}" />

                                                                            </f:facet>

                                                                            <rich:extendedDataTable id="issuersTable" width="auto"

                                                                                      var="issuer" value="#{navigationBean.issuers}"

                                                                                      rendered="#{navigationBean.issuerGroupSelected}"

                                                                                      styleClass="stable2">

                                                                                      <a4j:ajax execute="@fm1" event="selectionchange"

                                                                                                listener="#{navigationBean.issuerSelectionListener}" />

                                                                                      <rich:column>

                                                                                                <h:outputText value="#{issuer.userDetails.displayName}" />

                                                                                      </rich:column>

                                                                            </rich:extendedDataTable>

                                                                  </rich:panel>

                                                        </a4j:outputPanel>

                                              </h:panelGrid>

                                    </rich:collapsiblePanel>

                          </h:form>

       

      Thanks!