Browse Source

Merge pull request #4398 from wenzhixin/fix/4351

Fixed bug with the footer extensions while sorting
文翼 6 years ago
parent
commit
0f4897f992
1 changed files with 1 additions and 3 deletions
  1. 1 3
      src/extensions/export/bootstrap-table-export.js

+ 1 - 3
src/extensions/export/bootstrap-table-export.js

@@ -176,10 +176,8 @@ $.BootstrapTable = class extends $.BootstrapTable {
           footerHtml.push(footerCellHtml)
           footerHtml.push(footerCellHtml)
         })
         })
 
 
-        this.append(footerData)
-
+        this.$body.append(this.$body.children().last()[0].outerHTML)
         const $lastTableRow = this.$body.children().last()
         const $lastTableRow = this.$body.children().last()
-
         $.each($lastTableRow.children(), (index, lastTableRowCell) => {
         $.each($lastTableRow.children(), (index, lastTableRowCell) => {
           $(lastTableRowCell).html(footerHtml[index])
           $(lastTableRowCell).html(footerHtml[index])
         })
         })