Re: Tree expansion
Hi, I believe this should be pretty much the same as it was here: http://apache-tapestry-mailing-list-archives.1045711.n5.nabble.com/T5-3-1-How-to-expand-all-the-tree-nodes-td5702736.html Thanks, Steve On 29 May 2015 at 06:48, Cheng Zhang charlesdenverj...@gmail.com wrote: Thank you for your answer. What method can I use to expand a node? Thanks. On Thu, May 28, 2015 at 12:22 AM, Charlouze m...@charlouze.com wrote: Hey! I think you have to iterate through all the tree nodes to expand them one at a time. Cheers, Charles Le mer 27 mai 2015 23:19, Cheng Zhang charlesdenverj...@gmail.com a écrit : Hi, I plan to use Tree component in my next project. The Tree has a clearExpansions() to collapse all its nodes. Conversely, I was wondering how to expand a tree or a node of a tree. Thanks. Charles Zhang - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Tree Picker inside Zone
Hello, I have a tree picker component placed within a modal. I am trying to integrate a search field into my tree picker component. Within this search field, the user can enter the search text for which I would be executing a db query to find the matching nodes. For this search field I have used zone updater mixin( http://jumpstart.doublenegative.com.au/jumpstart/examples/ajax/onevent) to pickup the user entered value. Below is the component calling the the tree picker component !-- Modal popup that show the tree component -- t:SimpleModal t:id=treeModal componentClientId=treeModal-${cachedClientId} t:title=titleToPopuptree t:showAfterRender=false t:TreePicker t:id=treePicker id=treePicker-${cachedClientId} t:value=prop:value t:treeKind=prop:treeKindParameter t:allowedReferenceTypesParameter=allowedReferenceTypesParameter t:restrictedReferenceTypesParameter=restrictedReferenceTypesParameter / /t:SimpleModal (Please ignore the irrelevant parameters passed). Below is my .tml code for my tree picker component t:container xmlns:t=http://tapestry.apache.org/schema/tapestry_5_4.xsd; xmlns:p=tapestry:parameter t:zone t:id=treeZone id=treeZone t:if test=${checkIfTreeNodeIsConfiguredAndIndexed()} input t:type=textField t:id=searchText id=searchText t:mixins=zoneUpdater class=form-control criteria-filter placeholder=${message:app.search.label} ZoneUpdater.clientEvent=change ZoneUpdater.event=search ZoneUpdater.zone=treeZone ZoneUpdater.secure=${request.secure} / /t:if !-- Tree Picker -- t:tree t:id=tree t:model=treeModel t:node=treeNode t:value=node p:label img border=0 src=${getUrlImage(node.key)} alt=/img t:if test=selectable a t:type=EventLink t:event=nodeSelected t:context=node.key t:zone=^ class=prop:selectedClass href=# ${treeNode.label} /a p:else span class=prop:selectedClass${treeNode.label}/span /p:else /t:if /p:label /t:tree /t:zone /t:container on the .java side I have the following event handler public void onSearch(@RequestParameter(value = param, allowBlank = true) String searchText) { //do required processing //clear the tree expansions //update the tree model if (request.isXHR()) { ajaxResponseRenderer.addRender(treeZone); } } Unfortunately, my tree structure is not being refreshed, whereas in debug mode I can see that all the realtive methods within the treezone are called. The same zone gets perfectly updated when, I fire the other event nodeSelected. Any ideas where I could be going wrong? Thanks in advance Best Regards Akshay