2 Replies Latest reply on Dec 7, 2012 1:11 PM by Tali Han

    Richfaces 4.3.2 M2 and jsf 2.1.14 RichTab :You can click through all tabs first time, but if you click the first tab in a second round of clicking , after that you'll not be able to switch tabs

    Tali Han Newbie

      Hello All,

       

      Is this a bug?

      I modified Richfaces4.3.2M example richfaces-showcase-tomcat6/richfaces/tabPanel/samples/dynamic-sample.xhtml to exclude 1 st static tab;

      I left only dynamic tabs. I commented out the static tab. You can click through all tabs first time, but if you click the first tab in a second round of clicking , after that you'll not be able to switch tabs. If you leave the static tab in it will work.

      The same goes for togglePanel, or accordeon.

      I am sending you this 2 files in attachment. Can somebody tell me, if I am doing something wrong, Is it a bug, and if yes, is there a work around?

       

      Sincerely,

      Tali

      <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

      <ui:composition xmlns="http://www.w3.org/1999/xhtml" xmlns:h="http://java.sun.com/jsf/html"

          xmlns:f="http://java.sun.com/jsf/core" xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:a4j="http://richfaces.org/a4j"

          xmlns:rich="http://richfaces.org/rich">

       

          <h:form>

         

              <rich:tabPanel activeItem="#{dynamicPanelBean.activeTab}">

                <ui:remove>

                  <rich:tab header="Static">

                      <p>This tab is static one.</p>

                     

                      <p>All of the following tabs are dynamically generated using <b>a4j:repeat</b>.</p>

                  </rich:tab>

                  </ui:remove>

                  <a4j:repeat value="#{skinBean.skins}" var="skinName">

                 

                      <rich:tab header="#{skinName}" name="#{skinName}">

                          <f:facet name="header">#{skinName}</f:facet>

       

                          <i> All the controls below are just standard JSF components skinned with RichFaces: </i>

                          <hr />

                

                          <h:form>

                              <h:panelGrid columns="2">

                                  <h:outputText value="Enter Name:" />

                                  <h:inputText id="input" />

                                  <h:outputText value="Enter you interests:" />

                                  <h:inputTextarea cols="17" rows="3" />

                                  <h:outputText value="Choose your favourite color" />

                                  <h:selectOneMenu>

                                      <f:selectItem itemLabel="Red" itemValue="0" />

                                      <f:selectItem itemLabel="Black" itemValue="1" />

                                      <f:selectItem itemLabel="Green" itemValue="2" />

                                      <f:selectItem itemLabel="White" itemValue="3" />

                                  </h:selectOneMenu>

                              </h:panelGrid>

                              <hr />

                              <h:commandButton value="Switch to #{skinName} skin">

                                  <f:param name="skin" value="#{skinName}" />

                              </h:commandButton>

                          </h:form>

                         

                      </rich:tab>

       

                  </a4j:repeat>

       

              </rich:tabPanel>

          </h:form>

      </ui:composition>