0 Replies Latest reply on Apr 26, 2010 5:41 AM by Jeff Reif

    commandbutton in rich:datable, setPropertyActionListener

    Jeff Reif Novice

      I have following code:

       

       

      <?xml version="1.0" encoding="ISO-8859-1" ?>
      
      <ui:composition template="/pages/templates/MesurageTemplate.xhtml"
          xmlns="http://www.w3.org/1999/xhtml"
          xmlns:ui="http://java.sun.com/jsf/facelets"
          xmlns:h="http://java.sun.com/jsf/html"
          xmlns:f="http://java.sun.com/jsf/core"
          xmlns:rich="http://richfaces.org/rich"
          xmlns:a4j="http://richfaces.org/a4j">
      
          <ui:define name="content">
      
              <h:form id="form">
      
                  <rich:panel id="richPanel">
                          <h:panelGrid id="panelGrid" columns="3">
                               <h:outputLabel value="Query" for="queryInput" id="queryLabel"/>
                               <h:inputText binding="#{listMesurageBean.queryInput}" id="queryInput" readOnly="false"/>
                               <a4j:commandButton value="Search" id="searchButton"
                                  action="#{listMesurageBean.processQuery}" reRender="panelList"/>
          
                          </h:panelGrid>
      
                  </rich:panel>
                  
                  <a4j:outputPanel id="panelList">
                    
                      <rich:dataTable
                      id="mesTbl" var="mesurage" rowKeyVar="row"
                      binding="#{listMesurageBean.contentTable}"
                      value="#{listMesurageBean.tableModel}">
                      
                      <rich:column id="actionColumn">
                              <a4j:commandButton value="Détails du Mesurage" id="detailMesurag"
                              action="#{listMesurageBean.goToMesurageDetails}" ajaxSingle="true">
                                       
                                 <f:setPropertyActionListener value="#{mesurage}"
                                         target="#{detailMesurageBean.selectedMesurage}" />
           
                                  
                          </a4j:commandButton>
                          
          
                      </rich:column>
      
                  </rich:dataTable>                 
                  
                  </a4j:outputPanel>      
      
              </h:form>
          </ui:define>
      </ui:composition
      

       

       

      Problem: action :"gotToMesurageDetails" is only executed if I set "ajaxSingle=true"

       

       

      setPropertyListener always returns NULL.