Thanks a lot Nitin,

It's working like a charm.


Nitin Deshmukh wrote:
> 
> since you are using the same property as value for all the
> collapsiblePanels, it expands/collapses all. add a boolean property
> "collapsed" to your "vars" object and have the value as vars.collapsed. It
> will then collapse/expand that particular panel only.
> 
> 
> --- On Wed, 8/13/08, 2melo <[EMAIL PROTECTED]> wrote:
> 
>> From: 2melo <[EMAIL PROTECTED]>
>> Subject: Re: Dynamic collapsiblePanel
>> To: users@myfaces.apache.org
>> Date: Wednesday, August 13, 2008, 12:00 PM
>> Hi,
>> 
>> I have binded the collapsiblePanel to the bean by adding
>> value="bean.collapsed" to the t:collapsiblePanel
>> tag, now it can expand and
>> collapse but the problem is that it does it for all
>> collapsible items in the
>> list, click 1 and all collapses/expands.
>> 
>> any ideas/suggestions will be greatly appreciated, i'm
>> using tomahawk 1.1.6
>> 
>> 
>> 2melo wrote:
>> > 
>> > Hi,
>> > 
>> > I need to create a dynamic collapsiblePanel for a list
>> returned, I got the
>> > collapsible to display on my page but the problem is
>> that it doesn't
>> > expand.
>> > 
>> > This is the code I used, I used the tomahawk dataList
>> and
>> > collapsiblePanel:
>> > 
>> > <t:dataList id="dtLst"
>> var="vars" value="#{bean.xxLst}"
>> > rowIndexVar="lstCnt">
>> >    <t:collapsiblePanel id="collapsId"
>> var="collapse" title="Collapsible
>> > #{lstCnt + 1}">
>> >            <f:facet name="header">
>> >                    <t:div>
>> >                            <t:headerLink immediate="true">
>> >                                    <h:graphicImage alt="minusImage"
>> url="../../img/minus.jpg"
>> > rendered="#{!collapse}" />
>> >                                    <h:graphicImage alt="plusImage"
>> url="../../img/plus.jpg"
>> > rendered="#{collapse}" />
>> >                                    <h:outputText value="Collapsible 
>> > #{lstCnt
>> + 1}" />
>> >                            </t:headerLink>                                 
>> >                 
>> >                    </t:div>
>> >            </f:facet>
>> >            <h:panelGrid width="100%"
>> frame="border" border="0"
>> columns="4" 
>> >                             cellpadding="2"
>> cellspacing="2" align="left">                
>> >                            <h:outputText value="Some Data 1:"
>> >                                                 style="font-weight:
>> bold"></h:outputText>
>> >                                    <h:outputText
>> value="#{vars.poperty1}"/>                                                   
>>                 
>> >                                    <h:outputText value="Some Data 2:"
>> style="font-weight:
>> > bold"></h:outputText>
>> >                                    <h:outputText
>> value="#{vars.property2}"/>
>> >            </h:panelGrid>
>> >    </t:collapsiblePanel>
>> >    <t:htmlTag value="br" />
>> > </t:dataList>
>> > 
>> > How can I get the collapsiblePanel to expand/collapse?
>> > 
>> > Thanks
>> > 
>> 
>> -- 
>> View this message in context:
>> http://www.nabble.com/Dynamic-collapsiblePanel-tp18941379p18966089.html
>> Sent from the MyFaces - Users mailing list archive at
>> Nabble.com.
> 
> 
>       
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Dynamic-collapsiblePanel-tp18941379p18996382.html
Sent from the MyFaces - Users mailing list archive at Nabble.com.

Reply via email to