2 Replies Latest reply on Aug 28, 2008 10:10 AM by sebgerpb

    rich:tree and a4j:support not working

    sebgerpb

      Hi everybody,

      can somebody tell me why this combination does not work?

      <rich:tree id="tree"
      eventsQueue="myQueue"
      nodeSelectListener="#{sessionBean.processSelection}"
      ajaxSubmitSelection="false"
      switchType="ajax"
      value="#{sessionBean.rootNode}"
      toggleOnClick="true"
      showConnectingLines="false"
      componentState="#{sessionBean.treeState}"
      styleClass="tree"
      binding="#{sessionBean.navigationTree}"
      style="border: 0px solid black;">
       <a4j:support event="oncomplete" action="#{sessionBean.returnToMain}" eventsQueue="myQueue"/>
      </rich:tree>
      


      After clicking on link in the tree, I would expect that the method "returnToMain" is called. But this is not the case. If I change ajaxSubmitSelection to true, then my method is called as I expected. But why isn't it called with ajaxSubmitSelection = false?

        • 1. Re: rich:tree and a4j:support not working
          ilya_shaikovsky

          because oncomplete event fired after ajax request complete. no request - no event ;) And b.t.w. why you use so strange construction.. Try maybe ajaxSubmitSelection true and specify selection listener on the node.

          • 2. Re: rich:tree and a4j:support not working
            sebgerpb

            I tried ajaxSubmitSelection true, but in combination with toggleOnClick=true there is some strange behavior too........ I use this combination, because I'd like to rerender my whole portlet after clicking on a link in the tree...this can't be done via a node selection listener, as far as I know.