Browse Source

fix(js): fix #1983, cookie with pageNumber and searchText bug

zhixin 7 years ago
parent
commit
75d008c2aa
1 changed files with 3 additions and 1 deletions
  1. 3 1
      src/bootstrap-table.js

+ 3 - 1
src/bootstrap-table.js

@@ -1237,7 +1237,9 @@
       this.searchText = text
       this.options.searchText = text
 
-      this.options.pageNumber = 1
+      if (!firedByInitSearchText) {
+        this.options.pageNumber = 1
+      }
       this.initSearch()
       if (firedByInitSearchText) {
         if (this.options.sidePagination === 'client') {