3 Replies Latest reply on May 23, 2007 5:11 AM by ilya_shaikovsky

    <a4j:commandLink actionListner is not getting called

    icai

      Hi,

      I am trying to implement sorting in one of datatables. But the commanadlink's action listner doesn't get called, though on clicking the links the control reaches to the managed bean.
      Following is my code snippet :

      <rich:dataTable
       cellpadding="0" cellspacing="0"
       width="100%" border="0"
       id="transtable"
       binding = "#{backing_CustSearchBean.transtable}"
       onRowMouseOver="saveref(this);onOver('#{backing_CustSearchBean.transtable.rowIndex+1}');"
       rendered="#{backing_CustSearchBean.strrendered == 'true'}"
       onRowMouseOut="onOut('#{backing_CustSearchBean.transtable.rowIndex+1}');"
       headerClass="bluebar"
       var="oppList" value="#{backing_CustSearchBean.prod_sesn_lst}"
       style="margin-top: 5px; cursor: pointer;overflow: auto;"
       styleClass = "dt_normal"
       rowClasses="searchcusttoprow,searchcustrows"
       ajaxKeys="#{backing_CustSearchBean.ajaxSet}"
       onRowClick="showOppSelected('#{oppList.opp_id}','#{backing_CustSearchBean.transtable.rowIndex+1}');showAllWheel('rtform:form2:transwheel');"
       columnClasses="searchcustcols,searchcustmidcols,searchcustcols,searchcustmidcols,searchcustcols,searchcustmidcols"
       >
       <f:facet name="header">
       <rich:columnGroup
       columnClasses ="searchcustcols,searchcustmidcols,searchcustcols,searchcustmidcols,searchcustcols,searchcustmidcols"
       rowClasses = "searchcusttoprow"
       style="backgroundColor: '#ECF2FE';"
       >
      
       <rich:column>
       <a4j:commandLink ajaxSingle="true" actionListener="#{backing_CustSearchBean.sortHistoricalOpp}" styleClass="dt_small" oncomplete="alert('completed the event')" reRender = "transtable">
       <f:attribute name="sortField" value="getHistOppWO" />
       <h:outputText value="WO#" />
       </a4j:commandLink>
       </rich:column>
       <rich:column>
       <a4j:commandLink ajaxSingle="true" actionListener="#{backing_CustSearchBean.sortHistoricalOpp}" styleClass="dt_small" oncomplete="alert('completed the event')" reRender = "transtable">
       <f:attribute name="sortField" value="getHistOppStatus" />
       <h:outputText value="Opp Status"/>
       </a4j:commandLink>
      
       </rich:column>
      ......
      </rich:dataTable>


      As written in the code, alert in Oncomplete handler is gets invoked. Only the method bound to actionListner is not get called.
      Please suggest where I can be wrong.

      Thanks in advance!