3 Replies Latest reply on Aug 4, 2012 3:07 AM by Vikas V

    rich:collapsiblePanel + rowClasses attribute

    Vikas V Newbie

      Hi,

       

      Am using JSF 2.0, Rich Faces 4.0, Jboss As 6.0 (Tomcat 7).

       

      Am trying to display rich collapsible panel with alternative colours. Just like how it can be done using rowClasses attribute provided with h:dataTable.

       

      But, since that attribute doesnt come with rich:collapsiblePanel, how it can be achieved?

       

      I tried putting rich:collapsiblePanel inside h:dataTable with rowClasses but it didnt work.

       

      This is how I did,

       

       

       

      <h:dataTable  rowClasses="box1,box2" var="myVar" value="#{myBean.myList}">
      <h:column>

       

      <rich:collapsiblePanel header="#{myVar.myHeader}" expanded="#{myVar.expandedList}"
      switchType="server" leftCollapsedIcon="none"
      leftExpandedIcon="none" rightCollapsedIcon="none"
      rightExpandedIcon="none"
      onbeforeswitch="return setSelectedGenre(#{myVar.prg_gen_id});">

      </rich:collapsiblePanel>


      </h:column>
      </h:dataTable>


      .box1{
      background-color:#f4f4f4;
      padding:25px;
      }

      .box2 {
      background-color:#fdfdfd;
      padding:25px;
      }

       

       

      Regards,