1 Reply Latest reply: Nov 1, 2011 7:56 PM by Robert Gary RSS

    Pass params in rich:menuItem of rich:treeNode

    Robert Gary Newbie

      It appears that the types of components you can pass attributes are limited in rich:menuItem. I would like for a user to be able to rich click on a tree node and select the "delete" menu item. That requires that the delete() method on the backing bean know which node was used. I'm having trouble with that...


          <rich:menuItem action="#{backingBean.deleteGroup}" actionListener="#{backingBean.assignCurID}" >
              <f:setPropertyActionListener value="{currentid}" target="#{backingBean.currentGroupID}"/> <-- does not work
              <f:param name="currentid" value="{currentid}"/> <--- does not work
              <h:outputText value="Delete Group...{currentid}"/> <-- This evaluates correctly!!!!!
              <h:commandButton value="foobar {currentid}"/>  <--- This evaluates correctly too!!!!



      Both the text label and the commandButton will correctly have {currentid} resolved. However, the f:setPropertyActionListener sets the value to "{currentid}".


      1 ) So is the ability for rich:componentControl to evaulate its parameters limited to certain components?

      2) is there any way to pass the current tree node data  to the rich:menuItem action?