1 Reply Latest reply on Jun 18, 2013 10:13 AM by Nawa Manusitthipol

    Duplicate ID for Primfaces TreeTable's Column running on JBoss 7.1.3

    Nawa Manusitthipol Newbie

      Hi there, new on this site.


      When a TreeTable is created without any data in it but later added by an AJAX call, duplicate IDs for all its column is encountered. The exact same application run without problem in JBoss 7.1.1.


      A debug session discovered that the columns were constructed and added to the TreeTable component but were not marked as CREATED. So they are recreated at 'apply' process and the IDs are duplicated. They are marked properly in 7.1.1. I was not unable to find out why they are not marked properly.


      The code (modified from Primefaces showcase for TreeTable) is attached.


      With this code, the page will have a tree table with no data in it and a button. The tree table is made to have 4 column. When the button is clicked, an exception is thrown for <i>Error Rendering View[/TestTreeTable.xhtml]: java.lang.IllegalStateException: Component ID mainForm:treetable:j_idt9 has already been found in the view.</i> which refer to the id of the first column.


      But if I modify the code to have populate method called in the constructor of the DocumentController bean (which populate some data in the TreeTable), more data is added to the tree table without duplicated id problem when the button is clicked.


      Since this program runs on 7.1.1 without problem and fail on 7.1.3 (everything else stay the same), I am pretty sure the problem is some thing in JSF implementation of 7.1.3.


      Sorry for my English.