4 Replies Latest reply: May 29, 2012 10:43 AM by John 'Jb' Brock-Oracle RSS

    formatting multiple values in ADF tree node

    John 'Jb' Brock-Oracle
      JDeveloper -- WinXP

      I have an ADF tree component that is bound to a table with two values per node level.

      The results look like:
      Fruit 1234
          -- VineGrown 5678
             -- Grapes 4567
                 -- Red 1234
                 -- Green 56
      Veggie 4567
         -- Root 45
            -- Carrot 34
            -- Potato 987
      What I want to be able to do is format the outputText so that it will end up looking more like "Fruit :: Total 1234"

      The issue is that the EL of #{node} displays both the node level value and the number as one item. This is in the facet nodeStamp.

      If I try and get more specific with the EL, I can separate out the Uses number by doing #{node.Uses} but I can't get the node name to still be dynamic for each level.

      My binding options for node are shown as:


      Of course setting the first #{node} to any of these more specific values doesn't display at all for the node levels that don't correspond to just that one level.

      Ideally the EL line would look something like:
      <af:outputText value="#{node.name} ::  Total: #{node.Uses}" id="ot3"/>
      where node.name could be any one of the levels: Type, GrownLocation, Group, etc.

      Is this something that pathStamp would be used for? I couldn't really figure out how pathStamp worked from the docs.

      Thanks for any help. Hopefully this makes some sense.