浏览代码

fix weired bug with export plugin (#5294)

Co-authored-by: Dennis Hernández <dennishernandezvargas@gmail.com>
Dustin Utecht 5 年之前
父节点
当前提交
e24d5c2b4e
共有 1 个文件被更改,包括 6 次插入4 次删除
  1. 6 4
      src/extensions/export/bootstrap-table-export.js

+ 6 - 4
src/extensions/export/bootstrap-table-export.js

@@ -260,10 +260,12 @@ $.BootstrapTable = class extends $.BootstrapTable {
       const virtualScroll = this.options.virtualScroll
 
       this.$el.one(eventName, () => {
-        doExport(() => {
-          this.options.virtualScroll = virtualScroll
-          this.togglePagination()
-        })
+        setTimeout(() => {
+          doExport(() => {
+            this.options.virtualScroll = virtualScroll
+            this.togglePagination()
+          })
+        }, 0)
       })
       this.options.virtualScroll = false
       this.togglePagination()