Initial ajax update

I have finisters, datatable,

<p:panel id="resultpanel">
  <p:dataTable id="tbl" var="job" value="#{report.jobModel}"
               paginator="true" rows="#{report.jobModel.pageSize}"
               paginatorPosition="bottom" lazy="true" scrollable="true"
               resizableColumns="true" rendered="#{!empty report.jobModel}"
               emptyMessage="#{messages['common.datatable.emptymessage']}">

    <p:ajax event="filter" listener="#{report.jobModel.onFilter}"
            update="@form" />

    <p:column sortBy="#{job.detail4}" filterBy="#{job.detail4}">
      <f:facet name="header">
        <h:outputText value="#{messages['content.donejobs.ftdi.datatable.fixedfeecolumn.header']}" />
      </f:facet>
      <h:outputText value="#{job.detail4}">
        <f:converter converterId="KurusLiraConverter"></f:converter>
      </h:outputText>
    </p:column>

    <f:facet name="footer">
      <h:outputFormat value="#{messages['content.donejobs.ftdi.datatable.footer']}">
        <f:param value="#{report.jobModel.rowCount}" />
      </h:outputFormat>

      <p:panel layout="block" style="border: 0px; text-align: center;">
        <p:commandLink ajax="false" title="Download Report">
          <p:graphicImage value="/images/excel.png" />
          <p:fileDownload value="#{report.excelFileOfReportTable}" />
        </p:commandLink>
      </p:panel>
    </f:facet>
  </p:dataTable>
</p:panel>

I want to update part of the footer while filtering a table. I tried updating the footer by putting all the things in the footer on the same panel, specifying an identifier, checking this identifier through firebug and assigning it as a value to the attribute update component of ajax elements. I also followed this approach using html outputformat and param. But unsuccessfully, finally, I tried to update the form, this time the whole table was processed as a text file. Is there a way to update the table size after filtering? By the way, I am using primaries 3.0.RC1-SNAPSHOT and testing in firefox 7.0.1. Thank you so much for your interest and comment.

+5
2

, dataTable. ( ) , . , , rowEdit.

<p:remoteCommand name="updateFilters" update="table:totalid"></p:remoteCommand>
<p:dataTable id="tabelaMunicipio" value="#{bean.model}" ...>
<p:ajax event="page" oncomplete="updateFilters()"/>
<p:ajax event="filter" oncomplete="updateFilters()"/>   
<p:ajax event="sort" oncomplete="updateFilters()"/>
<p:column headerText="#{msg['id']}" sortBy="#{id}"> 
   <h:outputText value="#{item.id}"></h:outputText>  
   <f:facet name="footer"> 
      <h:outputText value="#{bean.model.totals['id']}" id="totalid"/> 
   </f:facet> 
</p:column> 
...
</p:dataTable>

, p: remoteCommand ( p: ajax) . , .

+6

3.0.RC1-SNAPSHOT , , M4 M3 M4. ( ?) , M3 M4, , .

update = "@this", , , @form.

0

All Articles