This content has been marked as final.
Show 3 replies
-
1. Re: client side API for <rich:tree>
anders.norgaard Oct 6, 2008 7:20 AM (in response to igor_d)Does it have to be client side?
For me the combination of AJAX tree and server side stateAdvisor works great<rich:tree value="#{cpemanager.propertiesTree()}" var="item" nodeFace="#{item.type()}" id="conftree" stateAdvisor="#{treestateadvisor}" changeExpandListener="#{treestateadvisor.processExpansion()}">
Best,
Anders -
2. Re: client side API for <rich:tree>
ilya_shaikovsky Oct 6, 2008 7:40 AM (in response to igor_d)public JS API requests present in jira but not availble for now. vote in jira on at wiki requests page.
-
3. Re: client side API for <rich:tree>
igor_d Oct 6, 2008 7:06 PM (in response to igor_d)Hi biehl,
yes, I know you can use AJAX re-rendering of a tree, but we have a massive form and a menu tree, so it takes 4-5 seconds to re-render the tree (even with ajaxsingle="true", limitToList="true" and immediate="true").
We have navigation links outside of the menu tree, if a user clicks on that link it should expand and select the appropriate menu item in the menu.
The most effective way to do this is via JS IMHO.
Currently I use jsFunction for that (tried to make it asynchronous):<a:jsFunction name="setSelectedMenuItem" eventsQueue="myAjaxQueue" ignoreDupResponses="true" ajaxSingle="true" limitToList="true" immediate="true" reRender="treeMenu"> <a:actionparam name="panelId" assignTo="#{treeStateAdvisor.selectedPanelId}" /> </a:jsFunction>
And in the outside link:<a:commandLink value="#{node.label}" onclick="javascript:setSelectedMenuItem('#{node.panelId}');return false;"/>
Thanks, Ilya, I will vote for that.
Thanks, guys,
Igor