Hmmmm.....Looks like it happens during APPLY_REQUEST_VALUES, as the isListOK 
method is invoked. The projectList will be null from that invocation onwards.

20:35:55,328 ERROR [STDERR] 27-Mar-2006 20:35:55 DebugPhaseListener beforePhase
INFO: before phase: RESTORE_VIEW 1
20:35:55,562 ERROR [STDERR] 27-Mar-2006 20:35:55 DebugPhaseListener afterPhase
INFO: after phase: RESTORE_VIEW 1
20:35:55,562 ERROR [STDERR] 27-Mar-2006 20:35:55 DebugPhaseListener beforePhase
INFO: before phase: APPLY_REQUEST_VALUES 2
20:35:55,578 ERROR [STDERR] 27-Mar-2006 20:35:55 
eurojobs.actions.ProjectFinderBean isListOK
INFO: Checking List is OK->null

<h:form>
  |     <h:dataTable value="#{projectList}" var="project">
  |             <h:column>
  |                     <h:commandButton action="#{testAction.select}" 
value="#{project.name}" />
  |             </h:column>
  |     </h:dataTable>
  |     <h:commandButton disabled="#{!projectFinder.listOK}" />
  | </h:form>
@Name("projectFinder")
  | @Stateful
  | @Scope(ScopeType.EVENT)
  | @Interceptors(SeamInterceptor.class)
  | public class ProjectFinderBean implements ProjectFinder {
  | 
  |     private int pageSize = 25;
  | 
  |     @DataModel(scope = ScopeType.PAGE)
  |     private List<Job> projectList;
  | 
  |     @DataModelSelection
  |     private Job selectedProject;
  | 
  |     @PersistenceContext
  |     private EntityManager entityManager;
  | 
  |     @Factory("projectList")
  |     public void findProjects() {
  |             executeQuery();
  |     }
  | 
  |     private void executeQuery() {
  |             projectList = (List<Project>) entityManager.createQuery("from 
Project order by name")
  |                     .getResultList();
  |     }
  | 
  |     public void refresh() {
  |             if (projectList != null)
  |                     executeQuery();
  |     }
  | 
  |     public Job getSelection() {
  |             return entityManager.merge(selectedProject);
  |     }
  | 
  |     public boolean isListOK() {
  |             Logger.global.info("Checking List is OK->" +projectList);
  |             return projectList != null && projectList.size() > 0;
  |     }
  | 
  |     @Destroy
  |     @Remove
  |     public void destroy() {
  |     }
  | 
  | }

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3932925#3932925

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3932925


-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to