9 Replies Latest reply on Nov 12, 2007 1:01 PM by Pete Muir

    DataModel bug in Seam 2

    Andrei Gh Newbie

      Hello we have migrated from Seam 1.2.1 to Seam 2.0 and there is an annoing behavior of DataModel - if the DatgaModel is on a long running conversation and holds a list of database entities, the values of the entities are null after the first display of the page.

      To be more concrete:
      The bean (assume we are inside an already started long running conversation ):

      public class AttachmentsAction {
       private EntityManager entityManager;
       private List<CoreBuyer> buyerList;
       public void refreshBuyerList() {
       buyerList = new ArrayList<CoreBuyer>();
       buyerList.add(entityManager.find(CoreBuyer.class, 1));

      The xhtml:
       <h:dataTable var="item" value="#{buyerList}" >
       <h:column >
       <f:facet name="header">
       <h:outputText value="buyer" />

      The scenario is like this:

      - After conversation started we go to attachments page
      - the list of buyers (actually has 1 item in the simplified example above) displays correctly
      - we navigate to another page, but we are still in the conversation
      - we click again on attachments link in order to navigate to the page again
      - the list of buyers still has one item, but all values of the item are null!!

      What happens?