Uploaded image for project: 'MyFaces Tomahawk'
  1. MyFaces Tomahawk
  2. TOMAHAWK-439

Tree2 facets and duplicate IDs

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Invalid
    • 1.1.3-SNAPSHOT
    • None
    • Tree2
    • None
    • java 1.5
      myfaces 1.1.3
      tomahawk 1.1.2

    Description

      When I create a tree using the following code:

      <tree2 var='node'.....>
      <facet name="facet1">
      <h:inputText value="${node.item.quantity}" id="QTY"/>
      </facet>
      <facet name="facet2">
      <h:inputText value="${node.item.quantity}" id="QTY"/>
      </facet>
      </tree2>

      Where node is a subclass of TreeModel that adds a property:
      public Item getItem();

      Because the input values both have an id = "QTY", when I update the quantity value, it is not updated in the model. What I see happening is the screen re-displayed without any of the changes applied.

      When I change on of the id's to something else so they are unique, everything works as expected.

      If the ID's need to be unique across facets, is it possible for the component to issue a warning or error letting the developer know what the issue is? I finally figured it out......

      Chris....

      Attachments

        Activity

          People

            lu4242 Leonardo Uribe
            chane Chris Hane
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: