1 Reply Latest reply on Jul 30, 2010 2:06 AM by shanika Dias

    DataTable row won't disappear from view after deletion

    shanika Dias Newbie

      hi,

       

      I'm having a rich:dataTable on an ajax outputPanel. The first column of the table is a ajax command button to delete each row.

      My issue is, with every click on the delete button on each row, the corresponding row gets deleted correctly and removed from the table as expected until the very last row.  When clicked on the delete button on the very last row, though the log says the record is deletd and prints the size of the list as 0, the row does not get disappeard from the client view.

       

      I've been trying to fix this and tried using a:commandLink instead of button but it's the same.  I feel that something is not correct at rerendering.

       

       

      <a:outputPanel id="eList" ajaxRendered="true" rendered="#{ABC.exemptions.size > 0}">        
            <rich:dataTable id="exemptionstbl" value="#{ABC.exemptions}" var="rExemp" headerClass="thfmt" rowClasses="row1,row2"

               style="width: 535px">
             <rich:column id="column6" rendered="#{(rver.status == 'Dev') or (rver.status == 'Rev'')}">
                    <f:facet id="NameFacet" name="header"> </f:facet>
                    <a:commandButton id="removeExempBtn" reRender="eList" ajaxSingle="true" image="/img/delete.png" action="# 

                          {ABC.remExemp(rExemp)}" alt="remove from list" style="height : 18px; width : 18px;"/>
             </rich:column>
            
             <h:column id="column1">
                    <f:facet id="NameFacet" name="header">Sec/f:facet>
                     #{rExemp.sec}      
             </h:column>

             -

             -

             -

       

       

       

       

      Any idea is greatly appreciated.

       

      Best Regards

      Shanika