Browse Source

Update to 1.11.1

zhixin 8 years ago
parent
commit
20a95b378f
100 changed files with 1733 additions and 440 deletions
  1. 236 6
      dist/bootstrap-table-locale-all.js
  2. 3 3
      dist/bootstrap-table-locale-all.min.js
  3. 9 2
      dist/bootstrap-table.css
  4. 300 225
      dist/bootstrap-table.js
  5. 1 1
      dist/bootstrap-table.min.css
  6. 4 4
      dist/bootstrap-table.min.js
  7. 2 2
      dist/extensions/accent-neutralise/bootstrap-table-accent-neutralise.min.js
  8. 2 2
      dist/extensions/angular/bootstrap-table-angular.min.js
  9. 3 0
      dist/extensions/auto-refresh/bootstrap-table-auto-refresh.css
  10. 84 0
      dist/extensions/auto-refresh/bootstrap-table-auto-refresh.js
  11. 7 0
      dist/extensions/auto-refresh/bootstrap-table-auto-refresh.min.js
  12. 21 0
      dist/extensions/click-edit-row/bootstrap-table-click-edit-row.css
  13. 142 0
      dist/extensions/click-edit-row/bootstrap-table-click-edit-row.js
  14. 7 0
      dist/extensions/click-edit-row/bootstrap-table-click-edit-row.min.js
  15. 78 36
      dist/extensions/cookie/bootstrap-table-cookie.js
  16. 3 3
      dist/extensions/cookie/bootstrap-table-cookie.min.js
  17. 2 2
      dist/extensions/copy-rows/bootstrap-table-copy-rows.min.js
  18. 2 2
      dist/extensions/editable/bootstrap-table-editable.min.js
  19. 12 2
      dist/extensions/export/bootstrap-table-export.js
  20. 3 3
      dist/extensions/export/bootstrap-table-export.min.js
  21. 13 0
      dist/extensions/filter-control/bootstrap-table-filter-control.css
  22. 36 11
      dist/extensions/filter-control/bootstrap-table-filter-control.js
  23. 3 3
      dist/extensions/filter-control/bootstrap-table-filter-control.min.js
  24. 2 2
      dist/extensions/filter/bootstrap-table-filter.min.js
  25. 2 2
      dist/extensions/flat-json/bootstrap-table-flat-json.min.js
  26. 2 2
      dist/extensions/group-by-v2/bootstrap-table-group-by.min.js
  27. 2 2
      dist/extensions/group-by/bootstrap-table-group-by.min.js
  28. 2 2
      dist/extensions/i18n-enhance/bootstrap-table-i18n-enhance.min.js
  29. 2 2
      dist/extensions/key-events/bootstrap-table-key-events.min.js
  30. 2 2
      dist/extensions/mobile/bootstrap-table-mobile.min.js
  31. 2 2
      dist/extensions/multi-column-toggle/bootstrap-table-multi-toggle.min.js
  32. 2 2
      dist/extensions/multiple-search/bootstrap-table-multiple-search.min.js
  33. 17 0
      dist/extensions/multiple-selection-row/bootstrap-table-multiple-selection-row.css
  34. 127 0
      dist/extensions/multiple-selection-row/bootstrap-table-multiple-selection-row.js
  35. 7 0
      dist/extensions/multiple-selection-row/bootstrap-table-multiple-selection-row.min.js
  36. 1 1
      dist/extensions/multiple-sort/bootstrap-table-multiple-sort.js
  37. 3 3
      dist/extensions/multiple-sort/bootstrap-table-multiple-sort.min.js
  38. 2 2
      dist/extensions/natural-sorting/bootstrap-table-natural-sorting.min.js
  39. 133 0
      dist/extensions/print/bootstrap-table-print.js
  40. 7 0
      dist/extensions/print/bootstrap-table-print.min.js
  41. 4 0
      dist/extensions/reorder-columns/bootstrap-table-reorder-columns.js
  42. 3 3
      dist/extensions/reorder-columns/bootstrap-table-reorder-columns.min.js
  43. 6 4
      dist/extensions/reorder-rows/bootstrap-table-reorder-rows.js
  44. 3 3
      dist/extensions/reorder-rows/bootstrap-table-reorder-rows.min.js
  45. 2 2
      dist/extensions/resizable/bootstrap-table-resizable.min.js
  46. 2 2
      dist/extensions/select2-filter/bootstrap-table-select2-filter.min.js
  47. 2 2
      dist/extensions/sticky-header/bootstrap-table-sticky-header.min.js
  48. 2 2
      dist/extensions/toolbar/bootstrap-table-toolbar.js
  49. 3 3
      dist/extensions/toolbar/bootstrap-table-toolbar.min.js
  50. 1 0
      dist/extensions/tree-column/bootstrap-table-tree-column.css
  51. 130 0
      dist/extensions/tree-column/bootstrap-table-tree-column.js
  52. 7 0
      dist/extensions/tree-column/bootstrap-table-tree-column.min.js
  53. 2 2
      dist/locale/bootstrap-table-af-ZA.min.js
  54. 2 2
      dist/locale/bootstrap-table-ar-SA.min.js
  55. 2 2
      dist/locale/bootstrap-table-ca-ES.min.js
  56. 2 2
      dist/locale/bootstrap-table-cs-CZ.min.js
  57. 2 2
      dist/locale/bootstrap-table-da-DK.min.js
  58. 10 4
      dist/locale/bootstrap-table-de-DE.js
  59. 3 3
      dist/locale/bootstrap-table-de-DE.min.js
  60. 2 2
      dist/locale/bootstrap-table-el-GR.min.js
  61. 2 2
      dist/locale/bootstrap-table-en-US.min.js
  62. 2 2
      dist/locale/bootstrap-table-es-AR.min.js
  63. 44 0
      dist/locale/bootstrap-table-es-CL.js
  64. 7 0
      dist/locale/bootstrap-table-es-CL.min.js
  65. 2 2
      dist/locale/bootstrap-table-es-CR.min.js
  66. 2 2
      dist/locale/bootstrap-table-es-ES.min.js
  67. 2 2
      dist/locale/bootstrap-table-es-MX.min.js
  68. 2 2
      dist/locale/bootstrap-table-es-NI.min.js
  69. 2 2
      dist/locale/bootstrap-table-es-SP.min.js
  70. 2 2
      dist/locale/bootstrap-table-et-EE.min.js
  71. 2 2
      dist/locale/bootstrap-table-fa-IR.min.js
  72. 2 2
      dist/locale/bootstrap-table-fr-BE.min.js
  73. 2 2
      dist/locale/bootstrap-table-fr-FR.min.js
  74. 2 2
      dist/locale/bootstrap-table-he-IL.min.js
  75. 2 2
      dist/locale/bootstrap-table-hr-HR.min.js
  76. 2 2
      dist/locale/bootstrap-table-hu-HU.min.js
  77. 49 0
      dist/locale/bootstrap-table-id-ID.js
  78. 7 0
      dist/locale/bootstrap-table-id-ID.min.js
  79. 12 2
      dist/locale/bootstrap-table-it-IT.js
  80. 3 3
      dist/locale/bootstrap-table-it-IT.min.js
  81. 2 2
      dist/locale/bootstrap-table-ja-JP.min.js
  82. 2 2
      dist/locale/bootstrap-table-ka-GE.min.js
  83. 2 2
      dist/locale/bootstrap-table-ko-KR.min.js
  84. 2 2
      dist/locale/bootstrap-table-ms-MY.min.js
  85. 2 2
      dist/locale/bootstrap-table-nb-NO.min.js
  86. 2 2
      dist/locale/bootstrap-table-nl-NL.min.js
  87. 2 2
      dist/locale/bootstrap-table-pl-PL.min.js
  88. 2 2
      dist/locale/bootstrap-table-pt-BR.min.js
  89. 2 2
      dist/locale/bootstrap-table-pt-PT.min.js
  90. 2 2
      dist/locale/bootstrap-table-ro-RO.min.js
  91. 33 0
      dist/locale/bootstrap-table-ru-RU.js
  92. 3 3
      dist/locale/bootstrap-table-ru-RU.min.js
  93. 2 2
      dist/locale/bootstrap-table-sk-SK.min.js
  94. 2 2
      dist/locale/bootstrap-table-sv-SE.min.js
  95. 2 2
      dist/locale/bootstrap-table-th-TH.min.js
  96. 2 2
      dist/locale/bootstrap-table-tr-TR.min.js
  97. 36 0
      dist/locale/bootstrap-table-uk-UA.js
  98. 3 3
      dist/locale/bootstrap-table-uk-UA.min.js
  99. 2 2
      dist/locale/bootstrap-table-ur-PK.min.js
  100. 0 0
      dist/locale/bootstrap-table-uz-Latn-UZ.js

+ 236 - 6
dist/bootstrap-table-locale-all.js

@@ -219,16 +219,19 @@
       return 'Lade, bitte warten...';
     },
     formatRecordsPerPage: function (pageNumber) {
-      return pageNumber + ' Einträge pro Seite';
+      return pageNumber + ' Einträge pro Seite.';
     },
     formatShowingRows: function (pageFrom, pageTo, totalRows) {
-      return 'Zeige ' + pageFrom + ' bis ' + pageTo + ' von ' + totalRows + ' Zeile' + ((totalRows > 1) ? "n" : "");
+      return 'Zeige Zeile ' + pageFrom + ' bis ' + pageTo + ' von ' + totalRows + ' Zeile' + ((totalRows > 1) ? "n" : "")+".";
+    },
+    formatDetailPagination: function (totalRows) {
+      return 'Zeige ' + totalRows + ' Zeile' + ((totalRows > 1) ? "n" : "")+".";
     },
     formatSearch: function () {
-      return 'Suchen';
+      return 'Suchen ...';
     },
     formatNoMatches: function () {
-      return 'Keine passenden Ergebnisse gefunden';
+      return 'Keine passenden Ergebnisse gefunden.';
     },
     formatRefresh: function () {
       return 'Neu laden';
@@ -238,6 +241,9 @@
     },
     formatColumns: function () {
       return 'Spalten';
+    },
+    formatAllRows: function () {
+      return 'Alle';
     }
   };
 
@@ -356,6 +362,51 @@
 
 })(jQuery);
 /**
+ * Traducción de librería Bootstrap Table a Español (Chile)
+ * @author Brian Álvarez Azócar
+ * email brianalvarezazocar@gmail.com
+ */
+(function($) {
+  'use strict';
+
+  $.fn.bootstrapTable.locales['es-CL'] = {
+    formatLoadingMessage: function() {
+      return 'Cargando, espere por favor...';
+    },
+    formatRecordsPerPage: function(pageNumber) {
+      return pageNumber + ' filas por p\u00E1gina';
+    },
+    formatShowingRows: function(pageFrom, pageTo, totalRows) {
+      return 'Mostrando ' + pageFrom + ' a ' + pageTo + ' de ' + totalRows + ' filas';
+    },
+    formatSearch: function() {
+      return 'Buscar';
+    },
+    formatNoMatches: function() {
+      return 'No se encontraron registros';
+    },
+    formatPaginationSwitch: function() {
+      return 'Ocultar/Mostrar paginaci\u00F3n';
+    },
+    formatRefresh: function() {
+      return 'Refrescar';
+    },
+    formatToggle: function() {
+      return 'Cambiar';
+    },
+    formatColumns: function() {
+      return 'Columnas';
+    },
+    formatAllRows: function() {
+      return 'Todo';
+    }
+  };
+
+  $.extend($.fn.bootstrapTable.defaults, $.fn.bootstrapTable.locales['es-CL']);
+
+})(jQuery);
+
+/**
  * Bootstrap Table Spanish (Costa Rica) translation
  * Author: Dennis Hernández (http://djhvscf.github.io/Blog/)
  */
@@ -845,6 +896,56 @@
 })(jQuery);
 
 /**
+ * Bootstrap Table Indonesian translation
+ * Author: Andre Gardiner<andre@sirdre.com> 
+ */
+(function ($) {
+    'use strict';
+
+    $.fn.bootstrapTable.locales['id-ID'] = {
+        formatLoadingMessage: function () {
+            return 'Memuat, mohon tunggu...';
+        },
+        formatRecordsPerPage: function (pageNumber) {
+            return pageNumber + ' baris per halaman';
+        },
+        formatShowingRows: function (pageFrom, pageTo, totalRows) {
+            return 'Menampilkan ' + pageFrom + ' sampai ' + pageTo + ' dari ' + totalRows + ' baris';
+        }, 
+        formatSearch: function () {
+            return 'Pencarian';
+        },
+        formatNoMatches: function () {
+            return 'Tidak ditemukan data yang cocok';
+        },
+        formatPaginationSwitch: function () {
+            return 'Sembunyikan/Tampilkan halaman';
+        },
+        formatRefresh: function () {
+            return 'Muat ulang';
+        },
+        formatToggle: function () {
+            return 'Beralih';
+        },
+        formatColumns: function () {
+            return 'kolom';
+        },
+        formatAllRows: function () {
+            return 'Semua';
+        },
+        formatExport: function () {
+            return 'Ekspor data';
+        },
+        formatClearFilters: function () {
+            return 'Bersihkan filter';
+        }
+    };
+
+    $.extend($.fn.bootstrapTable.defaults, $.fn.bootstrapTable.locales['id-ID']);
+
+})(jQuery);
+
+/**
  * Bootstrap Table Italian translation
  * Author: Davide Renzi<davide.renzi@gmail.com>
  * Author: Davide Borsatto <davide.borsatto@gmail.com>
@@ -861,7 +962,7 @@
             return pageNumber + ' elementi per pagina';
         },
         formatShowingRows: function (pageFrom, pageTo, totalRows) {
-            return 'Pagina ' + pageFrom + ' di ' + pageTo + ' (' + totalRows + ' elementi)';
+            return 'Elementi mostrati da ' + pageFrom + ' a ' + pageTo + ' (Numero totali di elementi ' + totalRows + ')';
         },
         formatSearch: function () {
             return 'Cerca';
@@ -869,18 +970,28 @@
         formatNoMatches: function () {
             return 'Nessun elemento trovato';
         },
+        formatPaginationSwitch: function () {
+            return 'Nascondi/Mostra paginazione';
+        },
         formatRefresh: function () {
             return 'Aggiorna';
         },
         formatToggle: function () {
-            return 'Alterna';
+            return 'Attiva/Disattiva';
         },
         formatColumns: function () {
             return 'Colonne';
         },
         formatAllRows: function () {
             return 'Tutto';
+        },
+        formatExport: function () {
+            return 'Esporta dati';
+        },
+        formatClearFilters: function () {
+            return 'Pulisci filtri';
         }
+        
     };
 
     $.extend($.fn.bootstrapTable.defaults, $.fn.bootstrapTable.locales['it-IT']);
@@ -1342,6 +1453,39 @@
         },
         formatClearFilters: function () {
             return 'Очистить фильтры';
+        },
+        formatMultipleSort: function () {
+            return 'Множественная сортировка';
+        },
+        formatAddLevel: function () {
+            return 'Добавить уровень';
+        },
+        formatDeleteLevel: function () {
+            return 'Удалить уровень';
+        },
+        formatColumn: function () {
+            return 'Колонка';
+        },
+        formatOrder: function () {
+            return 'Порядок';
+        },
+        formatSortBy: function () {
+            return 'Сортировать по';
+        },
+        formatThenBy: function () {
+            return 'затем по';
+        },
+        formatSort: function () {
+            return 'Сортировать';
+        },
+        formatCancel: function () {
+            return 'Отмена';
+        },
+        formatDuplicateAlertTitle: function () {
+            return 'Дублирование колонок!';
+        },
+        formatDuplicateAlertDescription: function () {
+            return 'Удалите, пожалуйста, дублирующую колонку, или замените ее на другую.';
         }
     };
 
@@ -1536,6 +1680,42 @@
         },
         formatColumns: function () {
             return 'Стовпці';
+        },
+        formatClearFilters: function () {
+            return 'Очистити фільтри';
+        },
+        formatMultipleSort: function () {
+            return 'Сортування за кількома стовпцями';
+        },
+        formatAddLevel: function () {
+            return 'Додати рівень';
+        },
+        formatDeleteLevel: function () {
+            return 'Видалити рівень';
+        },
+        formatColumn: function () {
+            return 'Стовпець';
+        },
+        formatOrder: function () {
+            return 'Порядок';
+        },
+        formatSortBy: function () {
+            return 'Сортувати за';
+        },
+        formatThenBy: function () {
+            return 'потім за';
+        },
+        formatSort: function () {
+            return 'Сортувати';
+        },
+        formatCancel: function () {
+            return 'Скасувати';
+        },
+        formatDuplicateAlertTitle: function () {
+            return 'Дублювання стовпців!';
+        },
+        formatDuplicateAlertDescription: function () {
+            return 'Видаліть, будь ласка, дублюючий стовпець, або замініть його на інший.';
         }
     };
 
@@ -1582,6 +1762,56 @@
 })(jQuery);
 
 /**
+ * Bootstrap Table Uzbek translation
+ * Author: Nabijon Masharipov <mnabijonz@gmail.com>
+ */
+(function ($) {
+    'use strict';
+
+    $.fn.bootstrapTable.locales['uz-Latn-UZ'] = {
+        formatLoadingMessage: function () {
+            return 'Yuklanyapti, iltimos kuting...';
+        },
+        formatRecordsPerPage: function (pageNumber) {
+            return pageNumber + ' qator har sahifada';
+        },
+        formatShowingRows: function (pageFrom, pageTo, totalRows) {
+            return 'Ko\'rsatypati ' + pageFrom + ' dan ' + pageTo + ' gacha ' + totalRows + ' qatorlarni';
+        },
+        formatSearch: function () {
+            return 'Qidirish';
+        },
+        formatNoMatches: function () {
+            return 'Hech narsa topilmadi';
+        },
+        formatPaginationSwitch: function () {
+            return 'Sahifalashni yashirish/ko\'rsatish';
+        },
+        formatRefresh: function () {
+            return 'Yangilash';
+        },
+        formatToggle: function () {
+            return 'Ko\'rinish';
+        },
+        formatColumns: function () {
+            return 'Ustunlar';
+        },
+        formatAllRows: function () {
+            return 'Hammasi';
+        },
+        formatExport: function () {
+            return 'Eksport';
+        },
+        formatClearFilters: function () {
+            return 'Filtrlarni tozalash';
+        }
+    };
+
+    $.extend($.fn.bootstrapTable.defaults, $.fn.bootstrapTable.locales['uz-Latn-UZ']);
+
+})(jQuery);
+
+/**
  * Bootstrap Table Vietnamese translation
  * Author: Duc N. PHAM <pngduc@gmail.com>
  */

File diff suppressed because it is too large
+ 3 - 3
dist/bootstrap-table-locale-all.min.js


+ 9 - 2
dist/bootstrap-table.css

@@ -1,6 +1,6 @@
 /**
  * @author zhixin wen <wenzhixin2010@gmail.com>
- * version: 1.11.0
+ * version: 1.11.1
  * https://github.com/wenzhixin/bootstrap-table/
  */
 
@@ -285,7 +285,7 @@
     padding: 0 !important;
 }
 
-.pull-right .dropdown-menu {
+.bootstrap-table .pull-right .dropdown-menu {
     right: 0;
     left: auto;
 }
@@ -304,3 +304,10 @@ div.fixed-table-scroll-outer {
     height: 150px;
     overflow: hidden;
 }
+
+/* for get correct heights  */
+.fixed-table-toolbar:after, .fixed-table-pagination:after {
+    content: "";
+    display: block;
+    clear: both;
+}

+ 300 - 225
dist/bootstrap-table.js

@@ -1,6 +1,6 @@
 /**
  * @author zhixin wen <wenzhixin2010@gmail.com>
- * version: 1.11.0
+ * version: 1.11.1
  * https://github.com/wenzhixin/bootstrap-table/
  */
 
@@ -140,7 +140,7 @@
             return func;
         }
         if (typeof func === 'function') {
-            return func.apply(self, args);
+            return func.apply(self, args || []);
         }
         if (!func && typeof name === 'string' && sprintf.apply(this, [name].concat(args))) {
             return sprintf.apply(this, [name].concat(args));
@@ -190,16 +190,6 @@
         return text;
     };
 
-    var getRealHeight = function ($el) {
-        var height = 0;
-        $el.children().each(function () {
-            if (height < $(this).outerHeight(true)) {
-                height = $(this).outerHeight(true);
-            }
-        });
-        return height;
-    };
-
     var getRealDataAttr = function (dataAttr) {
         for (var attr in dataAttr) {
             var auxAttr = attr.split(/(?=[A-Z])/).join('-').toLowerCase();
@@ -220,7 +210,9 @@
         }
         var props = field.split('.');
         for (var p in props) {
-            value = value && value[props[p]];
+            if (props.hasOwnProperty(p)) {
+                value = value && value[props[p]];
+            }
         }
         return escape ? escapeHTML(value) : value;
     };
@@ -287,6 +279,7 @@
 
     BootstrapTable.DEFAULTS = {
         classes: 'table table-hover',
+        sortClass: undefined,
         locale: undefined,
         height: undefined,
         undefinedText: '-',
@@ -296,6 +289,7 @@
         striped: false,
         columns: [[]],
         data: [],
+        totalField: 'total',
         dataField: 'rows',
         method: 'get',
         url: undefined,
@@ -313,6 +307,7 @@
         },
         pagination: false,
         onlyInfoPagination: false,
+        paginationLoop: true,
         sidePagination: 'client', // client or server
         totalRows: 0, // server side need to set
         pageNumber: 1,
@@ -531,7 +526,8 @@
         cellStyle: undefined,
         searchable: true,
         searchFormatter: true,
-        cardVisible: true
+        cardVisible: true,
+        escape : false
     };
 
     BootstrapTable.EVENTS = {
@@ -569,6 +565,7 @@
         this.initTable();
         this.initHeader();
         this.initData();
+        this.initHiddenRows();
         this.initFooter();
         this.initToolbar();
         this.initPagination();
@@ -814,13 +811,12 @@
                     sprintf(' rowspan="%s"', column.rowspan),
                     sprintf(' colspan="%s"', column.colspan),
                     sprintf(' data-field="%s"', column.field),
-                    "tabindex='0'",
                     '>');
 
                 html.push(sprintf('<div class="th-inner %s">', that.options.sortable && column.sortable ?
                     'sortable both' : ''));
 
-                text = column.title;
+                text = that.options.escape ? escapeHTML(column.title) : column.title;
 
                 if (column.checkbox) {
                     if (!that.options.singleSelect && that.options.checkboxHeader) {
@@ -931,7 +927,8 @@
         var that = this,
             name = this.options.sortName,
             order = this.options.sortOrder === 'desc' ? -1 : 1,
-            index = $.inArray(this.options.sortName, this.header.fields);
+            index = $.inArray(this.options.sortName, this.header.fields),
+            timeoutId = 0;
 
         if (this.options.customSort !== $.noop) {
             this.options.customSort.apply(this, [this.options.sortName, this.options.sortOrder]);
@@ -996,6 +993,17 @@
 
                 return order;
             });
+
+            if (this.options.sortClass !== undefined) {
+                clearTimeout(timeoutId);
+                timeoutId = setTimeout(function () {
+                    that.$el.removeClass(that.options.sortClass);
+                    var index = that.$header.find(sprintf('[data-field="%s"]',
+                        that.options.sortName).index() + 1);
+                    that.$el.find(sprintf('tr td:nth-child(%s)', index))
+                        .addClass(that.options.sortClass);
+                }, 250);
+            }
         }
     };
 
@@ -1058,7 +1066,7 @@
             html.push(sprintf('<button class="btn' +
                     sprintf(' btn-%s', this.options.buttonsClass) +
                     sprintf(' btn-%s', this.options.iconSize) +
-                    '" type="button" name="paginationSwitch" title="%s">',
+                    '" type="button" name="paginationSwitch" aria-label="pagination Switch" title="%s">',
                     this.options.formatPaginationSwitch()),
                 sprintf('<i class="%s %s"></i>', this.options.iconsPrefix, this.options.icons.paginationSwitchDown),
                 '</button>');
@@ -1068,7 +1076,7 @@
             html.push(sprintf('<button class="btn' +
                     sprintf(' btn-%s', this.options.buttonsClass) +
                     sprintf(' btn-%s', this.options.iconSize) +
-                    '" type="button" name="refresh" title="%s">',
+                    '" type="button" name="refresh" aria-label="refresh" title="%s">',
                     this.options.formatRefresh()),
                 sprintf('<i class="%s %s"></i>', this.options.iconsPrefix, this.options.icons.refresh),
                 '</button>');
@@ -1078,7 +1086,7 @@
             html.push(sprintf('<button class="btn' +
                     sprintf(' btn-%s', this.options.buttonsClass) +
                     sprintf(' btn-%s', this.options.iconSize) +
-                    '" type="button" name="toggle" title="%s">',
+                    '" type="button" name="toggle" aria-label="toggle" title="%s">',
                     this.options.formatToggle()),
                 sprintf('<i class="%s %s"></i>', this.options.iconsPrefix, this.options.icons.toggle),
                 '</button>');
@@ -1087,7 +1095,7 @@
         if (this.options.showColumns) {
             html.push(sprintf('<div class="keep-open btn-group" title="%s">',
                     this.options.formatColumns()),
-                '<button type="button" class="btn' +
+                '<button type="button" aria-label="columns" class="btn' +
                 sprintf(' btn-%s', this.options.buttonsClass) +
                 sprintf(' btn-%s', this.options.iconSize) +
                 ' dropdown-toggle" data-toggle="dropdown">',
@@ -1108,7 +1116,7 @@
                 var checked = column.visible ? ' checked="checked"' : '';
 
                 if (column.switchable) {
-                    html.push(sprintf('<li>' +
+                    html.push(sprintf('<li role="menuitem">' +
                         '<label><input type="checkbox" data-field="%s" value="%s"%s> %s</label>' +
                         '</li>', column.field, i, checked, column.title));
                     switchableCount++;
@@ -1172,7 +1180,7 @@
 
             this.$toolbar.append(html.join(''));
             $search = this.$toolbar.find('.search input');
-            $search.off('keyup drop').on('keyup drop', function (event) {
+            $search.off('keyup drop blur').on('keyup drop blur', function (event) {
                 if (that.options.searchOnEnterKey && event.keyCode !== 13) {
                     return;
                 }
@@ -1235,7 +1243,7 @@
             this.data = f ? $.grep(this.options.data, function (item, i) {
                 for (var key in f) {
                     if ($.isArray(f[key]) && $.inArray(item[key], f[key]) === -1 ||
-                            item[key] !== f[key]) {
+                            !$.isArray(f[key]) && item[key] !== f[key]) {
                         return false;
                     }
                 }
@@ -1377,14 +1385,14 @@
             }
 
             $.each(pageList, function (i, page) {
-                if (!that.options.smartDisplay || i === 0 || pageList[i - 1] <= that.options.totalRows) {
+                if (!that.options.smartDisplay || i === 0 || pageList[i - 1] < that.options.totalRows) {
                     var active;
                     if ($allSelected) {
                         active = page === that.options.formatAllRows() ? ' class="active"' : '';
                     } else {
                         active = page === that.options.pageSize ? ' class="active"' : '';
                     }
-                    pageNumber.push(sprintf('<li%s><a href="javascript:void(0)">%s</a></li>', active, page));
+                    pageNumber.push(sprintf('<li role="menuitem"%s><a href="#">%s</a></li>', active, page));
                 }
             });
             pageNumber.push('</ul></span>');
@@ -1395,7 +1403,7 @@
             html.push('</div>',
                 '<div class="pull-' + this.options.paginationHAlign + ' pagination">',
                 '<ul class="pagination' + sprintf(' pagination-%s', this.options.iconSize) + '">',
-                '<li class="page-pre"><a href="javascript:void(0)">' + this.options.paginationPreText + '</a></li>');
+                '<li class="page-pre"><a href="#">' + this.options.paginationPreText + '</a></li>');
 
             if (this.totalPages < 5) {
                 from = 1;
@@ -1416,7 +1424,7 @@
             if (this.totalPages >= 6) {
                 if (this.options.pageNumber >= 3) {
                     html.push('<li class="page-first' + (1 === this.options.pageNumber ? ' active' : '') + '">',
-                        '<a href="javascript:void(0)">', 1, '</a>',
+                        '<a href="#">', 1, '</a>',
                         '</li>');
 
                     from++;
@@ -1427,7 +1435,7 @@
                         from--;
                     } else {
                         html.push('<li class="page-first-separator disabled">',
-                            '<a href="javascript:void(0)">...</a>',
+                            '<a href="#">...</a>',
                             '</li>');
                     }
 
@@ -1453,14 +1461,14 @@
 
             for (i = from; i <= to; i++) {
                 html.push('<li class="page-number' + (i === this.options.pageNumber ? ' active' : '') + '">',
-                    '<a href="javascript:void(0)">', i, '</a>',
+                    '<a href="#">', i, '</a>',
                     '</li>');
             }
 
             if (this.totalPages >= 8) {
                 if (this.options.pageNumber <= (this.totalPages - 4)) {
                     html.push('<li class="page-last-separator disabled">',
-                        '<a href="javascript:void(0)">...</a>',
+                        '<a href="#">...</a>',
                         '</li>');
                 }
             }
@@ -1468,13 +1476,13 @@
             if (this.totalPages >= 6) {
                 if (this.options.pageNumber <= (this.totalPages - 3)) {
                     html.push('<li class="page-last' + (this.totalPages === this.options.pageNumber ? ' active' : '') + '">',
-                        '<a href="javascript:void(0)">', this.totalPages, '</a>',
+                        '<a href="#">', this.totalPages, '</a>',
                         '</li>');
                 }
             }
 
             html.push(
-                '<li class="page-next"><a href="javascript:void(0)">' + this.options.paginationNextText + '</a></li>',
+                '<li class="page-next"><a href="#">' + this.options.paginationNextText + '</a></li>',
                 '</ul>',
                 '</div>');
         }
@@ -1499,6 +1507,16 @@
                 // when data is empty, hide the pagination
                 this.$pagination[this.getData().length ? 'show' : 'hide']();
             }
+
+            if (!this.options.paginationLoop) {
+                if (this.options.pageNumber === 1) {
+                    $pre.addClass('disabled');
+                }
+                if (this.options.pageNumber === this.totalPages) {
+                    $next.addClass('disabled');
+                }
+            }
+
             if ($allSelected) {
                 this.options.pageSize = this.options.formatAllRows();
             }
@@ -1540,11 +1558,13 @@
         this.$toolbar.find('.page-size').text(this.options.pageSize);
 
         this.updatePagination(event);
+        return false;
     };
 
     BootstrapTable.prototype.onPageFirst = function (event) {
         this.options.pageNumber = 1;
         this.updatePagination(event);
+        return false;
     };
 
     BootstrapTable.prototype.onPagePre = function (event) {
@@ -1554,6 +1574,7 @@
             this.options.pageNumber--;
         }
         this.updatePagination(event);
+        return false;
     };
 
     BootstrapTable.prototype.onPageNext = function (event) {
@@ -1563,11 +1584,13 @@
             this.options.pageNumber++;
         }
         this.updatePagination(event);
+        return false;
     };
 
     BootstrapTable.prototype.onPageLast = function (event) {
         this.options.pageNumber = this.totalPages;
         this.updatePagination(event);
+        return false;
     };
 
     BootstrapTable.prototype.onPageNumber = function (event) {
@@ -1576,55 +1599,138 @@
         }
         this.options.pageNumber = +$(event.currentTarget).text();
         this.updatePagination(event);
+        return false;
     };
 
-    BootstrapTable.prototype.initBody = function (fixedScroll) {
-        var that = this,
+    BootstrapTable.prototype.initRow = function(item, i, data, parentDom) {
+        var that=this,
+            key,
             html = [],
-            data = this.getData();
+            style = {},
+            csses = [],
+            data_ = '',
+            attributes = {},
+            htmlAttributes = [];
 
-        this.trigger('pre-body', data);
+        if ($.inArray(item, this.hiddenRows) > -1) {
+            return;
+        }
 
-        this.$body = this.$el.find('>tbody');
-        if (!this.$body.length) {
-            this.$body = $('<tbody></tbody>').appendTo(this.$el);
+        style = calculateObjectValue(this.options, this.options.rowStyle, [item, i], style);
+
+        if (style && style.css) {
+            for (key in style.css) {
+                csses.push(key + ': ' + style.css[key]);
+            }
         }
 
-        //Fix #389 Bootstrap-table-flatJSON is not working
+        attributes = calculateObjectValue(this.options,
+            this.options.rowAttributes, [item, i], attributes);
 
-        if (!this.options.pagination || this.options.sidePagination === 'server') {
-            this.pageFrom = 1;
-            this.pageTo = data.length;
+        if (attributes) {
+            for (key in attributes) {
+                htmlAttributes.push(sprintf('%s="%s"', key, escapeHTML(attributes[key])));
+            }
         }
 
-        for (var i = this.pageFrom - 1; i < this.pageTo; i++) {
-            var key,
-                item = data[i],
-                style = {},
-                csses = [],
+        if (item._data && !$.isEmptyObject(item._data)) {
+            $.each(item._data, function(k, v) {
+                // ignore data-index
+                if (k === 'index') {
+                    return;
+                }
+                data_ += sprintf(' data-%s="%s"', k, v);
+            });
+        }
+
+        html.push('<tr',
+            sprintf(' %s', htmlAttributes.join(' ')),
+            sprintf(' id="%s"', $.isArray(item) ? undefined : item._id),
+            sprintf(' class="%s"', style.classes || ($.isArray(item) ? undefined : item._class)),
+            sprintf(' data-index="%s"', i),
+            sprintf(' data-uniqueid="%s"', item[this.options.uniqueId]),
+            sprintf('%s', data_),
+            '>'
+        );
+
+        if (this.options.cardView) {
+            html.push(sprintf('<td colspan="%s"><div class="card-views">', this.header.fields.length));
+        }
+
+        if (!this.options.cardView && this.options.detailView) {
+            html.push('<td>',
+                '<a class="detail-icon" href="#">',
+                sprintf('<i class="%s %s"></i>', this.options.iconsPrefix, this.options.icons.detailOpen),
+                '</a>',
+                '</td>');
+        }
+
+        $.each(this.header.fields, function(j, field) {
+            var text = '',
+                value_ = getItemField(item, field, that.options.escape),
+                value = '',
+                type = '',
+                cellStyle = {},
+                id_ = '',
+                class_ = that.header.classes[j],
                 data_ = '',
-                attributes = {},
-                htmlAttributes = [];
+                rowspan_ = '',
+                colspan_ = '',
+                title_ = '',
+                column = that.columns[j];
 
-            style = calculateObjectValue(this.options, this.options.rowStyle, [item, i], style);
+            if (that.fromHtml && typeof value_ === 'undefined') {
+                return;
+            }
 
-            if (style && style.css) {
-                for (key in style.css) {
-                    csses.push(key + ': ' + style.css[key]);
-                }
+            if (!column.visible) {
+                return;
             }
 
-            attributes = calculateObjectValue(this.options,
-                this.options.rowAttributes, [item, i], attributes);
+            if (that.options.cardView && (!column.cardVisible)) {
+                return;
+            }
 
-            if (attributes) {
-                for (key in attributes) {
-                    htmlAttributes.push(sprintf('%s="%s"', key, escapeHTML(attributes[key])));
+            if (column.escape) {
+                value_ = escapeHTML(value_);
+            }
+
+            style = sprintf('style="%s"', csses.concat(that.header.styles[j]).join('; '));
+
+            // handle td's id and class
+            if (item['_' + field + '_id']) {
+                id_ = sprintf(' id="%s"', item['_' + field + '_id']);
+            }
+            if (item['_' + field + '_class']) {
+                class_ = sprintf(' class="%s"', item['_' + field + '_class']);
+            }
+            if (item['_' + field + '_rowspan']) {
+                rowspan_ = sprintf(' rowspan="%s"', item['_' + field + '_rowspan']);
+            }
+            if (item['_' + field + '_colspan']) {
+                colspan_ = sprintf(' colspan="%s"', item['_' + field + '_colspan']);
+            }
+            if (item['_' + field + '_title']) {
+                title_ = sprintf(' title="%s"', item['_' + field + '_title']);
+            }
+            cellStyle = calculateObjectValue(that.header,
+                that.header.cellStyles[j], [value_, item, i, field], cellStyle);
+            if (cellStyle.classes) {
+                class_ = sprintf(' class="%s"', cellStyle.classes);
+            }
+            if (cellStyle.css) {
+                var csses_ = [];
+                for (var key in cellStyle.css) {
+                    csses_.push(key + ': ' + cellStyle.css[key]);
                 }
+                style = sprintf('style="%s"', csses_.concat(that.header.styles[j]).join('; '));
             }
 
-            if (item._data && !$.isEmptyObject(item._data)) {
-                $.each(item._data, function (k, v) {
+            value = calculateObjectValue(column,
+                that.header.formatters[j], [value_, item, i], value_);
+
+            if (item['_' + field + '_data'] && !$.isEmptyObject(item['_' + field + '_data'])) {
+                $.each(item['_' + field + '_data'], function(k, v) {
                     // ignore data-index
                     if (k === 'index') {
                         return;
@@ -1633,159 +1739,101 @@
                 });
             }
 
-            html.push('<tr',
-                sprintf(' %s', htmlAttributes.join(' ')),
-                sprintf(' id="%s"', $.isArray(item) ? undefined : item._id),
-                sprintf(' class="%s"', style.classes || ($.isArray(item) ? undefined : item._class)),
-                sprintf(' data-index="%s"', i),
-                sprintf(' data-uniqueid="%s"', item[this.options.uniqueId]),
-                sprintf('%s', data_),
-                '>'
-            );
+            if (column.checkbox || column.radio) {
+                type = column.checkbox ? 'checkbox' : type;
+                type = column.radio ? 'radio' : type;
 
-            if (this.options.cardView) {
-                html.push(sprintf('<td colspan="%s"><div class="card-views">', this.header.fields.length));
-            }
+                text = [sprintf(that.options.cardView ?
+                        '<div class="card-view %s">' : '<td class="bs-checkbox %s">', column['class'] || ''),
+                    '<input' +
+                    sprintf(' data-index="%s"', i) +
+                    sprintf(' name="%s"', that.options.selectItemName) +
+                    sprintf(' type="%s"', type) +
+                    sprintf(' value="%s"', item[that.options.idField]) +
+                    sprintf(' checked="%s"', value === true ||
+                        (value_ || value && value.checked) ? 'checked' : undefined) +
+                    sprintf(' disabled="%s"', !column.checkboxEnabled ||
+                        (value && value.disabled) ? 'disabled' : undefined) +
+                    ' />',
+                    that.header.formatters[j] && typeof value === 'string' ? value : '',
+                    that.options.cardView ? '</div>' : '</td>'
+                ].join('');
 
-            if (!this.options.cardView && this.options.detailView) {
-                html.push('<td>',
-                    '<a class="detail-icon" href="javascript:">',
-                    sprintf('<i class="%s %s"></i>', this.options.iconsPrefix, this.options.icons.detailOpen),
-                    '</a>',
-                    '</td>');
-            }
+                item[that.header.stateField] = value === true || (value && value.checked);
+            } else {
+                value = typeof value === 'undefined' || value === null ?
+                    that.options.undefinedText : value;
+
+                text = that.options.cardView ? ['<div class="card-view">',
+                    that.options.showHeader ? sprintf('<span class="title" %s>%s</span>', style,
+                        getPropertyFromOther(that.columns, 'field', 'title', field)) : '',
+                    sprintf('<span class="value">%s</span>', value),
+                    '</div>'
+                ].join('') : [sprintf('<td%s %s %s %s %s %s %s>',
+                        id_, class_, style, data_, rowspan_, colspan_, title_),
+                    value,
+                    '</td>'
+                ].join('');
 
-            $.each(this.header.fields, function (j, field) {
-                var text = '',
-                    value = getItemField(item, field, that.options.escape),
-                    type = '',
-                    cellStyle = {},
-                    id_ = '',
-                    class_ = that.header.classes[j],
-                    data_ = '',
-                    rowspan_ = '',
-                    colspan_ = '',
-                    title_ = '',
-                    column = that.columns[j];
-
-                if (that.fromHtml && typeof value === 'undefined') {
-                    return;
+                // Hide empty data on Card view when smartDisplay is set to true.
+                if (that.options.cardView && that.options.smartDisplay && value === '') {
+                    // Should set a placeholder for event binding correct fieldIndex
+                    text = '<div class="card-view"></div>';
                 }
+            }
 
-                if (!column.visible) {
-                    return;
-                }
+            html.push(text);
+        });
 
-                if (that.options.cardView && !column.cardVisible) {
-                    return;
-                }
+        if (this.options.cardView) {
+            html.push('</div></td>');
+        }
+        html.push('</tr>');
 
-                style = sprintf('style="%s"', csses.concat(that.header.styles[j]).join('; '));
+        return html.join(' ');
+    };
 
-                // handle td's id and class
-                if (item['_' + field + '_id']) {
-                    id_ = sprintf(' id="%s"', item['_' + field + '_id']);
-                }
-                if (item['_' + field + '_class']) {
-                    class_ = sprintf(' class="%s"', item['_' + field + '_class']);
-                }
-                if (item['_' + field + '_rowspan']) {
-                    rowspan_ = sprintf(' rowspan="%s"', item['_' + field + '_rowspan']);
-                }
-                if (item['_' + field + '_colspan']) {
-                    colspan_ = sprintf(' colspan="%s"', item['_' + field + '_colspan']);
-                }
-                if (item['_' + field + '_title']) {
-                    title_ = sprintf(' title="%s"', item['_' + field + '_title']);
-                }
-                cellStyle = calculateObjectValue(that.header,
-                    that.header.cellStyles[j], [value, item, i, field], cellStyle);
-                if (cellStyle.classes) {
-                    class_ = sprintf(' class="%s"', cellStyle.classes);
-                }
-                if (cellStyle.css) {
-                    var csses_ = [];
-                    for (var key in cellStyle.css) {
-                        csses_.push(key + ': ' + cellStyle.css[key]);
-                    }
-                    style = sprintf('style="%s"', csses_.concat(that.header.styles[j]).join('; '));
-                }
+    BootstrapTable.prototype.initBody = function (fixedScroll) {
+        var that = this,
+            html = [],
+            data = this.getData();
 
-                value = calculateObjectValue(column,
-                    that.header.formatters[j], [value, item, i], value);
+        this.trigger('pre-body', data);
 
-                if (item['_' + field + '_data'] && !$.isEmptyObject(item['_' + field + '_data'])) {
-                    $.each(item['_' + field + '_data'], function (k, v) {
-                        // ignore data-index
-                        if (k === 'index') {
-                            return;
-                        }
-                        data_ += sprintf(' data-%s="%s"', k, v);
-                    });
-                }
+        this.$body = this.$el.find('>tbody');
+        if (!this.$body.length) {
+            this.$body = $('<tbody></tbody>').appendTo(this.$el);
+        }
 
-                if (column.checkbox || column.radio) {
-                    type = column.checkbox ? 'checkbox' : type;
-                    type = column.radio ? 'radio' : type;
+        //Fix #389 Bootstrap-table-flatJSON is not working
 
-                    text = [sprintf(that.options.cardView ?
-                        '<div class="card-view %s">' : '<td class="bs-checkbox %s">', column['class'] || ''),
-                        '<input' +
-                        sprintf(' data-index="%s"', i) +
-                        sprintf(' name="%s"', that.options.selectItemName) +
-                        sprintf(' type="%s"', type) +
-                        sprintf(' value="%s"', item[that.options.idField]) +
-                        sprintf(' checked="%s"', value === true ||
-                        (value && value.checked) ? 'checked' : undefined) +
-                        sprintf(' disabled="%s"', !column.checkboxEnabled ||
-                        (value && value.disabled) ? 'disabled' : undefined) +
-                        ' />',
-                        that.header.formatters[j] && typeof value === 'string' ? value : '',
-                        that.options.cardView ? '</div>' : '</td>'
-                    ].join('');
-
-                    item[that.header.stateField] = value === true || (value && value.checked);
-                } else {
-                    value = typeof value === 'undefined' || value === null ?
-                        that.options.undefinedText : value;
-
-                    text = that.options.cardView ? ['<div class="card-view">',
-                        that.options.showHeader ? sprintf('<span class="title" %s>%s</span>', style,
-                            getPropertyFromOther(that.columns, 'field', 'title', field)) : '',
-                        sprintf('<span class="value">%s</span>', value),
-                        '</div>'
-                    ].join('') : [sprintf('<td%s %s %s %s %s %s %s>',
-                        id_, class_, style, data_, rowspan_, colspan_, title_),
-                        value,
-                        '</td>'
-                    ].join('');
-
-                    // Hide empty data on Card view when smartDisplay is set to true.
-                    if (that.options.cardView && that.options.smartDisplay && value === '') {
-                        // Should set a placeholder for event binding correct fieldIndex
-                        text = '<div class="card-view"></div>';
-                    }
-                }
+        if (!this.options.pagination || this.options.sidePagination === 'server') {
+            this.pageFrom = 1;
+            this.pageTo = data.length;
+        }
 
-                html.push(text);
-            });
+        var trFragments = $(document.createDocumentFragment());
+        var hasTr;
 
-            if (this.options.cardView) {
-                html.push('</div></td>');
+        for (var i = this.pageFrom - 1; i < this.pageTo; i++) {
+            var item = data[i];
+            var tr = this.initRow(item, i, data, trFragments);
+            hasTr = hasTr || !!tr;
+            if (tr&&tr!==true) {
+                trFragments.append(tr);
             }
-
-            html.push('</tr>');
         }
 
         // show no records
-        if (!html.length) {
-            html.push('<tr class="no-records-found">',
+        if (!hasTr) {
+            trFragments.append('<tr class="no-records-found">' +
                 sprintf('<td colspan="%s">%s</td>',
-                    this.$header.find('th').length, this.options.formatNoMatches()),
+                this.$header.find('th').length,
+                this.options.formatNoMatches()) +
                 '</tr>');
         }
 
-        this.$body.html(html.join(''));
+        this.$body.html(trFragments);
 
         if (!fixedScroll) {
             this.scrollTo(0);
@@ -1827,8 +1875,8 @@
             // remove and update
             if ($tr.next().is('tr.detail-view')) {
                 $this.find('i').attr('class', sprintf('%s %s', that.options.iconsPrefix, that.options.icons.detailOpen));
-                $tr.next().remove();
                 that.trigger('collapse-row', index, row);
+                $tr.next().remove();
             } else {
                 $this.find('i').attr('class', sprintf('%s %s', that.options.iconsPrefix, that.options.icons.detailClose));
                 $tr.after(sprintf('<tr class="detail-view"><td colspan="%s"></td></tr>', $tr.find('td').length));
@@ -1840,6 +1888,7 @@
                 that.trigger('expand-row', index, row, $element);
             }
             that.resetView();
+            return false;
         });
 
         this.$selectItem = this.$body.find(sprintf('[name="%s"]', this.options.selectItemName));
@@ -2041,6 +2090,7 @@
                 row[that.header.stateField] = false;
             }
         });
+        this.initHiddenRows();
     };
 
     BootstrapTable.prototype.trigger = function (name) {
@@ -2257,17 +2307,6 @@
         }
     };
 
-    BootstrapTable.prototype.toggleRow = function (index, uniqueId, visible) {
-        if (index === -1) {
-            return;
-        }
-
-        this.$body.find(typeof index !== 'undefined' ?
-            sprintf('tr[data-index="%s"]', index) :
-            sprintf('tr[data-uniqueid="%s"]', uniqueId))
-            [visible ? 'show' : 'hide']();
-    };
-
     BootstrapTable.prototype.getVisibleFields = function () {
         var that = this,
             visibleFields = [];
@@ -2297,8 +2336,8 @@
             this.$selectItem.length === this.$selectItem.filter(':checked').length);
 
         if (this.options.height) {
-            var toolbarHeight = getRealHeight(this.$toolbar),
-                paginationHeight = getRealHeight(this.$pagination),
+            var toolbarHeight = this.$toolbar.outerHeight(true),
+                paginationHeight = this.$pagination.outerHeight(true),
                 height = this.options.height - toolbarHeight - paginationHeight;
 
             this.$tableContainer.css('height', height + 'px');
@@ -2345,7 +2384,7 @@
 
         // #431: support pagination
         if (this.options.sidePagination === 'server') {
-            this.options.totalRows = data.total;
+            this.options.totalRows = data[this.options.totalField];
             fixedScroll = data.fixedScroll;
             data = data[this.options.dataField];
         } else if (!$.isArray(data)) { // support fixedScroll
@@ -2391,6 +2430,9 @@
             }
             if ($.inArray(row[params.field], params.values) !== -1) {
                 this.options.data.splice(i, 1);
+                if (this.options.sidePagination === 'server') {
+                    this.options.totalRows -= 1;
+                }
             }
         }
 
@@ -2486,6 +2528,7 @@
         });
 
         this.initSearch();
+        this.initPagination();
         this.initSort();
         this.initBody(true);
     };
@@ -2513,32 +2556,57 @@
         });
 
         this.initSearch();
+        this.initPagination();
         this.initSort();
         this.initBody(true);
     };
 
+    BootstrapTable.prototype.initHiddenRows = function () {
+        this.hiddenRows = [];
+    };
+
     BootstrapTable.prototype.showRow = function (params) {
-        if (!params.hasOwnProperty('index') && !params.hasOwnProperty('uniqueId')) {
-            return;
-        }
-        this.toggleRow(params.index, params.uniqueId, true);
+        this.toggleRow(params, true);
     };
 
     BootstrapTable.prototype.hideRow = function (params) {
-        if (!params.hasOwnProperty('index') && !params.hasOwnProperty('uniqueId')) {
+        this.toggleRow(params, false);
+    };
+
+    BootstrapTable.prototype.toggleRow = function (params, visible) {
+        var row, index;
+
+        if (params.hasOwnProperty('index')) {
+            row = this.getData()[params.index];
+        } else if (params.hasOwnProperty('uniqueId')) {
+            row = this.getRowByUniqueId(params.uniqueId);
+        }
+
+        if (!row) {
             return;
         }
-        this.toggleRow(params.index, params.uniqueId, false);
+
+        index = $.inArray(row, this.hiddenRows);
+
+        if (!visible && index === -1) {
+            this.hiddenRows.push(row);
+        } else if (visible && index > -1) {
+            this.hiddenRows.splice(index, 1);
+        }
+        this.initBody(true);
     };
 
-    BootstrapTable.prototype.getRowsHidden = function (show) {
-        var rows = $(this.$body[0]).children().filter(':hidden'),
-            i = 0;
-        if (show) {
-            for (; i < rows.length; i++) {
-                $(rows[i]).show();
+    BootstrapTable.prototype.getHiddenRows = function (show) {
+        var that = this,
+            data = this.getData(),
+            rows = [];
+
+        $.each(data, function (i, row) {
+            if ($.inArray(row, that.hiddenRows) > -1) {
+                rows.push(row);
             }
-        }
+        });
+        this.hiddenRows = rows;
         return rows;
     };
 
@@ -2593,7 +2661,8 @@
         var that = this;
 
         return $.grep(this.options.data, function (row) {
-            return row[that.header.stateField];
+            // fix #2424: from html with checkbox
+            return row[that.header.stateField] === true;
         });
     };
 
@@ -2718,7 +2787,13 @@
 
     BootstrapTable.prototype.refresh = function (params) {
         if (params && params.url) {
-            this.options.pageNumber = 1;
+            this.options.url = params.url;
+        }
+        if (params && params.pageNumber) {
+            this.options.pageNumber = params.pageNumber;
+        }
+        if (params && params.pageSize) {
+            this.options.pageSize = params.pageSize;
         }
         this.initServer(params && params.silent,
             params && params.query, params && params.url);
@@ -2937,7 +3012,7 @@
         'getSelections', 'getAllSelections', 'getData',
         'load', 'append', 'prepend', 'remove', 'removeAll',
         'insertRow', 'updateRow', 'updateCell', 'updateByUniqueId', 'removeByUniqueId',
-        'getRowByUniqueId', 'showRow', 'hideRow', 'getRowsHidden',
+        'getRowByUniqueId', 'showRow', 'hideRow', 'getHiddenRows',
         'mergeCells',
         'checkAll', 'uncheckAll', 'checkInvert',
         'check', 'uncheck',

File diff suppressed because it is too large
+ 1 - 1
dist/bootstrap-table.min.css


File diff suppressed because it is too large
+ 4 - 4
dist/bootstrap-table.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/extensions/accent-neutralise/bootstrap-table-accent-neutralise.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/extensions/angular/bootstrap-table-angular.min.js


+ 3 - 0
dist/extensions/auto-refresh/bootstrap-table-auto-refresh.css

@@ -0,0 +1,3 @@
+.btn.enabled {
+  background-color: #5bc0de;
+}

+ 84 - 0
dist/extensions/auto-refresh/bootstrap-table-auto-refresh.js

@@ -0,0 +1,84 @@
+/**
+ * @author: Alec Fenichel
+ * @webSite: https://fenichelar.com
+ * @version: v1.0.0
+ */
+
+(function ($) {
+
+  'use strict';
+
+  $.extend($.fn.bootstrapTable.defaults, {
+    autoRefresh: false,
+    autoRefreshInterval: 60,
+    autoRefreshSilent: true,
+    autoRefreshStatus: true,
+    autoRefreshFunction: null
+  });
+
+  $.extend($.fn.bootstrapTable.defaults.icons, {
+    autoRefresh: 'glyphicon-time icon-time'
+  });
+
+  $.extend($.fn.bootstrapTable.locales, {
+    formatAutoRefresh: function() {
+      return 'Auto Refresh';
+    }
+  });
+
+  $.extend($.fn.bootstrapTable.defaults, $.fn.bootstrapTable.locales);
+
+  var BootstrapTable = $.fn.bootstrapTable.Constructor;
+  var _init = BootstrapTable.prototype.init;
+  var _initToolbar = BootstrapTable.prototype.initToolbar;
+  var sprintf = $.fn.bootstrapTable.utils.sprintf;
+
+  BootstrapTable.prototype.init = function () {
+    _init.apply(this, Array.prototype.slice.apply(arguments));
+
+    if (this.options.autoRefresh && this.options.autoRefreshStatus) {
+      var that = this;
+      this.options.autoRefreshFunction = setInterval(function () {
+        that.refresh({silent: that.options.autoRefreshSilent});
+      }, this.options.autoRefreshInterval*1000);
+    }
+  };
+
+  BootstrapTable.prototype.initToolbar = function() {
+    _initToolbar.apply(this, Array.prototype.slice.apply(arguments));
+
+    if (this.options.autoRefresh) {
+      var $btnGroup = this.$toolbar.find('>.btn-group');
+      var $btnAutoRefresh = $btnGroup.find('.auto-refresh');
+
+      if (!$btnAutoRefresh.length) {
+        $btnAutoRefresh = $([
+          sprintf('<button class="btn btn-default auto-refresh %s" ', this.options.autoRefreshStatus ? 'enabled' : ''),
+          'type="button" ',
+          sprintf('title="%s">', this.options.formatAutoRefresh()),
+          sprintf('<i class="%s %s"></i>', this.options.iconsPrefix, this.options.icons.autoRefresh),
+          '</button>'
+        ].join('')).appendTo($btnGroup);
+
+        $btnAutoRefresh.on('click', $.proxy(this.toggleAutoRefresh, this));
+      }
+    }
+  };
+
+  BootstrapTable.prototype.toggleAutoRefresh = function() {
+    if (this.options.autoRefresh) {
+      if (this.options.autoRefreshStatus) {
+        clearInterval(this.options.autoRefreshFunction);
+        this.$toolbar.find('>.btn-group').find('.auto-refresh').removeClass('enabled');
+      } else {
+        var that = this;
+        this.options.autoRefreshFunction = setInterval(function () {
+          that.refresh({silent: that.options.autoRefreshSilent});
+        }, this.options.autoRefreshInterval*1000);
+        this.$toolbar.find('>.btn-group').find('.auto-refresh').addClass('enabled');
+      }
+      this.options.autoRefreshStatus = !this.options.autoRefreshStatus;
+    }
+  };
+
+})(jQuery);

File diff suppressed because it is too large
+ 7 - 0
dist/extensions/auto-refresh/bootstrap-table-auto-refresh.min.js


+ 21 - 0
dist/extensions/click-edit-row/bootstrap-table-click-edit-row.css

@@ -0,0 +1,21 @@
+#tooling{
+  float: right;
+}
+.clear{
+  display: block;
+  width: 13px;
+  height: 13px;
+  position: absolute;
+  opacity: 0.6;
+  z-index: 100;
+  top: 50%;
+  right: 26px;
+  margin-top: -10px;
+  cursor: pointer;
+}
+.clear > i{
+  font-size: 1.5em;
+}
+.clear > i:hover{
+  color: hsl(0, 0%, 75%);
+}

+ 142 - 0
dist/extensions/click-edit-row/bootstrap-table-click-edit-row.js

@@ -0,0 +1,142 @@
+/**
+ * @author horken wong <horken.wong@gmail.com>
+ * @version: v1.0.0
+ * https://github.com/horkenw/bootstrap-table
+ * Click to edit row for bootstrap-table
+ */
+
+(function ($) {
+    'use strict';
+
+    $.extend($.fn.bootstrapTable.defaults, {
+        clickEdit: false
+    });
+
+    function setDivision(node, options){
+        var $option = $('<option />');
+        if(options){
+            $(options).each(function(i, v){
+                $option.clone().text(v.idxNum + ' ' +v.name).val(v.idxNum).appendTo(node);
+            })
+        }
+        else{
+            console.log('Please setup options first!!')
+        }
+    }
+
+    function clikcToEdit(evt, tarNode){
+        var txt = [], table = evt,
+            submit = '<button type="button" class="btn btn-primary btn-sm editable-submit"><i class="glyphicon glyphicon-ok"></i></button>',
+            cancel = '<button type="button" class="btn btn-default btn-sm editable-cancel"><i class="glyphicon glyphicon-remove"></i></button>';
+
+        var replaceData = function(){
+            txt = [];
+            tarNode.find('td').find('input[type="text"]').each(function(i, td){
+                txt.push($(td).eq(0).val());
+            });
+            tarNode.find('select').each(function(i, td){
+                txt.push($('#'+td.id+' option:selected').val());
+            });
+            $('#table').bootstrapTable('updateRow', {
+                index: table.$data.thId,
+                row: {
+                    noOld: txt[0],
+                    area: tarNode.find('select').eq(0).children(':selected').text(),
+                    town: tarNode.find('select').eq(1).children(':selected').text(),
+                    address: txt[1]
+                }
+            });
+            $('#tooling').remove();
+            table.editing = true;
+            // updateToServerSide(table.$data.itemid, txt);
+            return false;
+        };
+
+        var recoveryData = function(){
+          $('#table').bootstrapTable('updateRow', {
+                index: table.$data.thId,
+                row: {},
+            });
+          $('#tooling').remove();
+          table.editing = true;
+          return false;
+        };
+
+        if(table.editing){
+            var  rootid = 0;
+            table.editing = false;
+            table.columns.forEach(function(column, i){
+                if (!column.editable) return;
+
+                switch(column.editable){
+                    case 'input':
+                        var div=$('<div class="editable-input col-md-12 col-sm-12 col-xs-12" style="position: relative;"/>');
+                        txt.push(tarNode.find('td').eq(column.fieldIndex).text());
+                        div.append($('<input type="text" class="form-control input-sm"/>'));
+                        div.append($('<span class="clear"><i class="fa fa-times-circle-o" aria-hidden="true"></i></span>'));
+                        tarNode.find('td').eq(column.fieldIndex).text('').append(div);
+                        break;
+                    case 'select':
+                        var select=$('<select id="'+column.field+'">'), options = $.selectArray[column.field];
+                        tarNode.find('td').eq(column.fieldIndex).text('').append(select);
+                        setDivision($('#'+column.field), options);
+                        break;
+                    case 'textarea':
+                        break;
+                    default:
+                        console.log(column.fieldIndex+' '+column.editable);
+                }
+
+            }, evt);
+            for(var i=0, l=txt.length; i<l; i++){
+                tarNode.find('input[type="text"]').eq(i).val(txt[i]);
+            }
+            tarNode.find('td').last().append('<div id="tooling" class="editable-buttons"/>');
+            $('.clear').on('click', function(){ $(this).parent().find('input').val('');});
+            $(submit).on('click', replaceData).appendTo('#tooling');
+            $(cancel).on('click', recoveryData).appendTo('#tooling');
+        }
+    }
+
+    function updateToServerSide(item, data){
+        var itemid = $(item).find('a').attr('href').match(/\d+/g)[0];
+        var datas = {'treeId': itemid, 'oldTreeSerialNo': data[0], 'adminDivision': data[2], 'adminUnit': data[3], 'treeAddr': data[1]}; //傳送至伺服器端的Data產生處,需手動修改對應表格
+        store( 'data/update', datas)
+    }
+
+    var BootstrapTable = $.fn.bootstrapTable.Constructor,
+        _initTable = BootstrapTable.prototype.initTable,
+        _initBody = BootstrapTable.prototype.initBody;
+
+    BootstrapTable.prototype.initTable = function(){
+        var that = this;
+        this.$data = {};
+        _initTable.apply(this, Array.prototype.slice.apply(arguments));
+
+        if (!this.options.clickEdit) {
+            return;
+        }
+
+    };
+
+    BootstrapTable.prototype.initBody = function () {
+        var that = this;
+        _initBody.apply(this, Array.prototype.slice.apply(arguments));
+
+        if (!this.options.clickEdit) {
+            return;
+        }
+
+        var table = this.$tableBody.find('table');
+        that.editing=true;
+
+        table.on('click-row.bs.table', function (e, row, $element, field) {
+            if(field ==='no') return; //|| field ==='noOld'
+            this.$data.thId = $element.data().index;
+            this.$data.itemid = $element.data().uniqueid;
+            this.$data.divi = parseInt(row.area);
+            this.$data.town=parseInt(row.town);
+            clikcToEdit(this, $element);
+        }.bind(this));
+    };
+})(jQuery);

File diff suppressed because it is too large
+ 7 - 0
dist/extensions/click-edit-row/bootstrap-table-click-edit-row.min.js


+ 78 - 36
dist/extensions/cookie/bootstrap-table-cookie.js

@@ -1,7 +1,7 @@
 /**
  * @author: Dennis Hernández
  * @webSite: http://djhvscf.github.io/Blog
- * @version: v1.2.1
+ * @version: v1.2.2
  *
  * @update zhixin wen <wenzhixin2010@gmail.com>
  */
@@ -64,11 +64,27 @@
         }
 
         cookieName = that.options.cookieIdTable + '.' + cookieName;
-        if (!cookieName || /^(?:expires|max\-age|path|domain|secure)$/i.test(cookieName)) {
-            return false;
+
+        switch(that.options.cookieStorage) {
+            case 'cookieStorage':
+                document.cookie = [
+                        cookieName, '=', cookieValue,
+                        '; expires=' + that.options.cookieExpire,
+                        that.options.cookiePath ? '; path=' + that.options.cookiePath : '',
+                        that.options.cookieDomain ? '; domain=' + that.options.cookieDomain : '',
+                        that.options.cookieSecure ? '; secure' : ''
+                    ].join('');
+            break;
+            case 'localStorage':
+                localStorage.setItem(cookieName, cookieValue);
+            break;
+            case 'sessionStorage':
+                sessionStorage.setItem(cookieName, cookieValue);
+            break;
+            default:
+                return false;
         }
 
-        document.cookie = encodeURIComponent(cookieName) + '=' + encodeURIComponent(cookieValue) + calculateExpiration(that.options.cookieExpire) + (that.options.cookieDomain ? '; domain=' + that.options.cookieDomain : '') + (that.options.cookiePath ? '; path=' + that.options.cookiePath : '') + (that.cookieSecure ? '; secure' : '');
         return true;
     };
 
@@ -83,28 +99,44 @@
 
         cookieName = tableName + '.' + cookieName;
 
-        return decodeURIComponent(document.cookie.replace(new RegExp('(?:(?:^|.*;)\\s*' + encodeURIComponent(cookieName).replace(/[\-\.\+\*]/g, '\\$&') + '\\s*\\=\\s*([^;]*).*$)|^.*$'), '$1')) || null;
-    };
-
-    var hasCookie = function (cookieName) {
-        if (!cookieName) {
-            return false;
+        switch(that.options.cookieStorage) {
+            case 'cookieStorage':
+                return decodeURIComponent(document.cookie.replace(new RegExp('(?:(?:^|.*;)\\s*' + encodeURIComponent(cookieName).replace(/[\-\.\+\*]/g, '\\$&') + '\\s*\\=\\s*([^;]*).*$)|^.*$'), '$1')) || null;
+            case 'localStorage':
+                return localStorage.getItem(cookieName);
+            case 'sessionStorage':
+                return sessionStorage.getItem(cookieName);
+            default:
+                return null;
         }
-        return (new RegExp('(?:^|;\\s*)' + encodeURIComponent(cookieName).replace(/[\-\.\+\*]/g, '\\$&') + '\\s*\\=')).test(document.cookie);
     };
 
-    var deleteCookie = function (tableName, cookieName, sPath, sDomain) {
+    var deleteCookie = function (that, tableName, cookieName) {
         cookieName = tableName + '.' + cookieName;
-        if (!hasCookie(cookieName)) {
-            return false;
+        
+        switch(that.options.cookieStorage) {
+            case 'cookieStorage':
+                document.cookie = [
+                        encodeURIComponent(cookieName), '=',
+                        '; expires=Thu, 01 Jan 1970 00:00:00 GMT',
+                        that.options.cookiePath ? '; path=' + that.options.cookiePath : '',
+                        that.options.cookieDomain ? '; domain=' + that.options.cookieDomain : '',
+                    ].join('');
+                break;
+            case 'localStorage':
+                localStorage.removeItem(cookieName);
+            break;
+            case 'sessionStorage':
+                sessionStorage.removeItem(cookieName);
+            break;
+
         }
-        document.cookie = encodeURIComponent(cookieName) + '=; expires=Thu, 01 Jan 1970 00:00:00 GMT' + (sDomain ? '; domain=' + sDomain : '') + (sPath ? '; path=' + sPath : '');
         return true;
     };
 
     var calculateExpiration = function(cookieExpire) {
         var time = cookieExpire.replace(/[0-9]*/, ''); //s,mi,h,d,m,y
-        cookieExpire = cookieExpire.replace(/[A-Za-z]/, ''); //number
+        cookieExpire = cookieExpire.replace(/[A-Za-z]{1,2}}/, ''); //number
 
         switch (time.toLowerCase()) {
             case 's':
@@ -163,7 +195,7 @@
                 bootstrapTable.initColumnSearch(cachedFilters);
             }
         }, 250);
-    }
+    };
 
     $.extend($.fn.bootstrapTable.defaults, {
         cookie: false,
@@ -172,14 +204,26 @@
         cookieDomain: null,
         cookieSecure: null,
         cookieIdTable: '',
-        cookiesEnabled: ['bs.table.sortOrder', 'bs.table.sortName', 'bs.table.pageNumber', 'bs.table.pageList', 'bs.table.columns', 'bs.table.searchText', 'bs.table.filterControl'],
+        cookiesEnabled: [
+            'bs.table.sortOrder', 'bs.table.sortName',
+            'bs.table.pageNumber', 'bs.table.pageList',
+            'bs.table.columns', 'bs.table.searchText',
+            'bs.table.filterControl'
+        ],
+        cookieStorage: 'cookieStorage', //localStorage, sessionStorage
         //internal variable
         filterControls: [],
         filterControlValuesLoaded: false
     });
 
+    $.fn.bootstrapTable.methods.push('getCookies');
     $.fn.bootstrapTable.methods.push('deleteCookie');
 
+    $.extend($.fn.bootstrapTable.utils, {
+        setCookie: setCookie,
+        getCookie: getCookie
+    });
+
     var BootstrapTable = $.fn.bootstrapTable.Constructor,
         _init = BootstrapTable.prototype.init,
         _initTable = BootstrapTable.prototype.initTable,
@@ -200,9 +244,10 @@
         this.options.filterControls = [];
         this.options.filterControlValuesLoaded = false;
 
-
         this.options.cookiesEnabled = typeof this.options.cookiesEnabled === 'string' ?
-            this.options.cookiesEnabled.replace('[', '').replace(']', '').replace(/ /g, '').toLowerCase().split(',') : this.options.cookiesEnabled;
+            this.options.cookiesEnabled.replace('[', '').replace(']', '')
+                .replace(/ /g, '').toLowerCase().split(',') :
+                this.options.cookiesEnabled;
 
         if (this.options.filterControl) {
             var that = this;
@@ -227,11 +272,6 @@
             }).on('post-body.bs.table', initCookieFilters(that));
         }
         _init.apply(this, Array.prototype.slice.apply(arguments));
-
-        $.extend($.fn.bootstrapTable.utils, {
-            setCookie: setCookie,
-            getCookie: getCookie
-        });
     };
 
     BootstrapTable.prototype.initServer = function () {
@@ -247,7 +287,8 @@
             },
 
             cookiesPresent = function() {
-                return bootstrapTable.options.cookie && bootstrapTable.getCookies(bootstrapTable);
+                var cookie = JSON.parse(getCookie(bootstrapTable, bootstrapTable.options.cookieIdTable, cookieIds.filterControl));
+                return bootstrapTable.options.cookie && cookie;
             };
 
         selectsWithoutDefaults = $.grep(bootstrapTable.columns, function(column) {
@@ -259,13 +300,13 @@
         BootstrapTable.prototype.initServer = _initServer;
 
         // early return if we don't need to populate any select values with cookie values
-        if (cookiesPresent() && selectsWithoutDefaults.length === 0) {
+        if (this.options.filterControl && cookiesPresent() && selectsWithoutDefaults.length === 0) {
             return;
         }
 
         // call BootstrapTable.prototype.initServer
         _initServer.apply(this, Array.prototype.slice.apply(arguments));
-    }
+    };
 
 
     BootstrapTable.prototype.initTable = function () {
@@ -280,7 +321,6 @@
 
         if ((this.options.cookieIdTable === '') || (this.options.cookieExpire === '') || (!cookieEnabled())) {
             throw new Error("Configuration error. Please review the cookieIdTable, cookieExpire properties, if those properties are ok, then this browser does not support the cookies");
-            return;
         }
 
         var sortOrderCookie = getCookie(this, this.options.cookieIdTable, cookieIds.sortOrder),
@@ -372,13 +412,15 @@
         }
     };
 
-    BootstrapTable.prototype.getCookies = function(bootstrapTable) {
-        var cookies = [];
-        $.each( cookieIds, function( key, value ) {
-            var cookie = JSON.parse(getCookie(bootstrapTable, bootstrapTable.options.cookieIdTable, cookieIds.filterControl));
-            cookies.concat(cookie);
+    BootstrapTable.prototype.getCookies = function () {
+        var bootstrapTable = this;
+        var cookies = {};
+        $.each(cookieIds, function(key, value) {
+            cookies[key] = getCookie(bootstrapTable, bootstrapTable.options.cookieIdTable, value);
+            if (key === 'columns') {
+                cookies[key] = JSON.parse(cookies[key]);
+            }
         });
-
         return cookies;
     };
 
@@ -387,6 +429,6 @@
             return;
         }
 
-        deleteCookie(this.options.cookieIdTable, cookieIds[cookieName], this.options.cookiePath, this.options.cookieDomain);
+        deleteCookie(this, this.options.cookieIdTable, cookieIds[cookieName]);
     };
 })(jQuery);

File diff suppressed because it is too large
+ 3 - 3
dist/extensions/cookie/bootstrap-table-cookie.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/extensions/copy-rows/bootstrap-table-copy-rows.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/extensions/editable/bootstrap-table-editable.min.js


+ 12 - 2
dist/extensions/export/bootstrap-table-export.js

@@ -16,6 +16,7 @@
         sql: 'SQL',
         doc: 'MS-Word',
         excel: 'MS-Excel',
+        xlsx: 'MS-Excel (OpenXML)',
         powerpoint: 'MS-Powerpoint',
         pdf: 'PDF'
     };
@@ -58,7 +59,7 @@
                         '<button class="btn' +
                             sprintf(' btn-%s', this.options.buttonsClass) +
                             sprintf(' btn-%s', this.options.iconSize) +
-                            ' dropdown-toggle" ' +
+                            ' dropdown-toggle" aria-label="export type" ' +
                             'title="' + this.options.formatExport() + '" ' +
                             'data-toggle="dropdown" type="button">',
                             sprintf('<i class="%s %s"></i> ', this.options.iconsPrefix, this.options.icons.export),
@@ -81,7 +82,7 @@
                 }
                 $.each(exportTypes, function (i, type) {
                     if (TYPE_NAME.hasOwnProperty(type)) {
-                        $menu.append(['<li data-type="' + type + '">',
+                        $menu.append(['<li role="menuitem" data-type="' + type + '">',
                                 '<a href="javascript:void(0)">',
                                     TYPE_NAME[type],
                                 '</a>',
@@ -108,6 +109,15 @@
                         var data = that.getData(),
                             selectedData = that.getAllSelections();
 
+                        // Quick fix #2220
+                        if (that.options.sidePagination === 'server') {
+                            data = {total: that.options.totalRows};
+                            data[that.options.dataField] = that.getData();
+
+                            selectedData = {total: that.options.totalRows};
+                            selectedData[that.options.dataField] = that.getAllSelections();
+                        }
+
                         that.load(selectedData);
                         doExport();
                         that.load(data);

File diff suppressed because it is too large
+ 3 - 3
dist/extensions/export/bootstrap-table-export.min.js


+ 13 - 0
dist/extensions/filter-control/bootstrap-table-filter-control.css

@@ -0,0 +1,13 @@
+/**
+ * @author: Dennis Hernández
+ * @webSite: http://djhvscf.github.io/Blog
+ * @version: v2.1.1
+ */
+
+.no-filter-control {
+    height: 34px;
+}
+
+.filter-control {
+    margin: 0 2px 2px 2px;
+}

+ 36 - 11
dist/extensions/filter-control/bootstrap-table-filter-control.js

@@ -1,7 +1,7 @@
 /**
  * @author: Dennis Hernández
  * @webSite: http://djhvscf.github.io/Blog
- * @version: v2.1.0
+ * @version: v2.1.1
  */
 
 (function ($) {
@@ -11,6 +11,24 @@
     var sprintf = $.fn.bootstrapTable.utils.sprintf,
         objectKeys = $.fn.bootstrapTable.utils.objectKeys;
 
+    var getOptionsFromSelectControl = function (selectControl) {
+        return selectControl.get(selectControl.length - 1).options;
+    };
+
+    var hideUnusedSelectOptions = function (selectControl, uniqueValues) {
+        var options = getOptionsFromSelectControl(selectControl);
+
+        for (var i = 0; i < options.length; i++) {
+            if (options[i].value !== "") {
+                if (!uniqueValues.hasOwnProperty(options[i].value)) {
+                    selectControl.find(sprintf("option[value='%s']", options[i].value)).hide();
+                } else {
+                    selectControl.find(sprintf("option[value='%s']", options[i].value)).show();
+                }
+            }
+        }
+    };
+
     var addOptionToSelectControl = function (selectControl, value, text) {
         value = $.trim(value);
         selectControl = $(selectControl.get(selectControl.length - 1));
@@ -39,7 +57,7 @@
     };
 
     var existOptionInSelectControl = function (selectControl, value) {
-        var options = selectControl.get(selectControl.length - 1).options;
+        var options = getOptionsFromSelectControl(selectControl);
         for (var i = 0; i < options.length; i++) {
             if (options[i].value === value.toString()) {
                 //The value is not valid to add
@@ -161,7 +179,7 @@
     };
 
     var initFilterSelectControls = function (that) {
-        var data = that.options.data,
+        var data = that.data,
             itemsPerPage = that.pageTo < that.options.data.length ? that.options.data.length : that.pageTo,
 
             isColumnSearchableViaSelect = function (column) {
@@ -198,18 +216,23 @@
 
                     uniqueValues[formattedValue] = fieldValue;
                 }
+
                 for (var key in uniqueValues) {
                     addOptionToSelectControl(selectControl, uniqueValues[key], key);
                 }
 
                 sortSelectControl(selectControl);
+
+                if (that.options.hideUnusedSelectOptions) {
+                    hideUnusedSelectOptions(selectControl, uniqueValues);
+                }
             }
         });
     };
 
-    var escapeID = function( id ) {
+    var escapeID = function(id) {
        return String(id).replace( /(:|\.|\[|\]|,)/g, "\\$1" );
-   };
+    };
 
     var createControls = function (that, header) {
         var addedFilterControl = false,
@@ -226,15 +249,15 @@
             }
 
             if (!column.filterControl) {
-                html.push('<div style="height: 34px;"></div>');
+                html.push('<div class="no-filter-control"></div>');
             } else {
-                html.push('<div style="margin: 0 2px 2px 2px;" class="filterControl">');
+                html.push('<div class="filter-control">');
 
                 var nameControl = column.filterControl.toLowerCase();
                 if (column.searchable && that.options.filterTemplate[nameControl]) {
                     addedFilterControl = true;
                     isVisible = 'visible';
-                    html.push(that.options.filterTemplate[nameControl](that, column.field, isVisible));
+                    html.push(that.options.filterTemplate[nameControl](that, column.field, isVisible, column.filterControlPlaceholder));
                 }
             }
 
@@ -332,6 +355,7 @@
                     if (column.filterControl !== undefined && column.filterControl.toLowerCase() === 'datepicker') {
                         header.find('.date-filter-control.bootstrap-table-filter-control-' + column.field).datepicker(column.filterDatepickerOptions)
                             .on('changeDate', function (e) {
+                                $(sprintf(".%s", e.currentTarget.classList.toString().split(" ").join("."))).val(e.currentTarget.value);
                                 //Fired the keyup event
                                 $(e.currentTarget).keyup();
                             });
@@ -406,8 +430,8 @@
         filterShowClear: false,
         alignmentSelectControlOptions: undefined,
         filterTemplate: {
-            input: function (that, field, isVisible) {
-                return sprintf('<input type="text" class="form-control bootstrap-table-filter-control-%s" style="width: 100%; visibility: %s">', field, isVisible);
+            input: function (that, field, isVisible, placeholder) {
+                return sprintf('<input type="text" class="form-control bootstrap-table-filter-control-%s" style="width: 100%; visibility: %s" placeholder="%s">', field, isVisible, placeholder);
             },
             select: function (that, field, isVisible) {
                 return sprintf('<select class="form-control bootstrap-table-filter-control-%s" style="width: 100%; visibility: %s" dir="%s"></select>',
@@ -426,7 +450,8 @@
         filterData: undefined,
         filterDatepickerOptions: undefined,
         filterStrictSearch: false,
-        filterStartsWithSearch: false
+        filterStartsWithSearch: false,
+        filterControlPlaceholder: ""
     });
 
     $.extend($.fn.bootstrapTable.Constructor.EVENTS, {

File diff suppressed because it is too large
+ 3 - 3
dist/extensions/filter-control/bootstrap-table-filter-control.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/extensions/filter/bootstrap-table-filter.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/extensions/flat-json/bootstrap-table-flat-json.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/extensions/group-by-v2/bootstrap-table-group-by.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/extensions/group-by/bootstrap-table-group-by.min.js


+ 2 - 2
dist/extensions/i18n-enhance/bootstrap-table-i18n-enhance.min.js

@@ -1,7 +1,7 @@
 /*
-* bootstrap-table - v1.11.0 - 2016-07-02
+* bootstrap-table - v1.11.1 - 2017-02-22
 * https://github.com/wenzhixin/bootstrap-table
-* Copyright (c) 2016 zhixin wen
+* Copyright (c) 2017 zhixin wen
 * Licensed MIT License
 */
 !function(a){"use strict";var b=a.fn.bootstrapTable.Constructor;b.prototype.changeTitle=function(b){a.each(this.options.columns,function(c,d){a.each(d,function(a,c){c.field&&(c.title=b[c.field])})}),this.initHeader(),this.initBody(),this.initToolbar()},b.prototype.changeLocale=function(a){this.options.locale=a,this.initLocale(),this.initPagination()},a.fn.bootstrapTable.methods.push("changeTitle"),a.fn.bootstrapTable.methods.push("changeLocale")}(jQuery);

File diff suppressed because it is too large
+ 2 - 2
dist/extensions/key-events/bootstrap-table-key-events.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/extensions/mobile/bootstrap-table-mobile.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/extensions/multi-column-toggle/bootstrap-table-multi-toggle.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/extensions/multiple-search/bootstrap-table-multiple-search.min.js


+ 17 - 0
dist/extensions/multiple-selection-row/bootstrap-table-multiple-selection-row.css

@@ -0,0 +1,17 @@
+.multiple-select-row-selected {
+    background: lightBlue
+}
+
+.table tbody tr:hover td,
+.table tbody tr:hover th {
+  background-color: transparent;
+}
+
+
+.table-striped tbody tr:nth-child(odd):hover td {
+   background-color: #F9F9F9;
+}
+
+.fixed-table-container tbody .selected td {
+    background: lightBlue;
+}

+ 127 - 0
dist/extensions/multiple-selection-row/bootstrap-table-multiple-selection-row.js

@@ -0,0 +1,127 @@
+/**
+ * @author: Dennis Hernández
+ * @webSite: http://djhvscf.github.io/Blog
+ * @version: v1.0.0
+ */
+
+!function ($) {
+
+    'use strict';
+
+    document.onselectstart = function() {
+        return false;
+    };
+
+    var getTableObjectFromCurrentTarget = function (currentTarget) {
+        currentTarget = $(currentTarget);
+        return currentTarget.is("table") ? currentTarget : currentTarget.parents().find(".table");
+    };
+
+    var getRow = function (target) {
+        target = $(target);
+        return target.parent().parent();
+    };
+
+    var onRowClick = function (e) {
+        var that = getTableObjectFromCurrentTarget(e.currentTarget);
+
+        if (window.event.ctrlKey) {
+            toggleRow(e.currentTarget, that, false, false);
+        }
+
+        if (window.event.button === 0) {
+            if (!window.event.ctrlKey && !window.event.shiftKey) {
+                clearAll(that);
+                toggleRow(e.currentTarget, that, false, false);
+            }
+
+            if (window.event.shiftKey) {
+                selectRowsBetweenIndexes([that.bootstrapTable("getOptions").multipleSelectRowLastSelectedRow.rowIndex, e.currentTarget.rowIndex], that)
+            }
+        }
+    };
+
+    var onCheckboxChange = function (e) {
+        var that = getTableObjectFromCurrentTarget(e.currentTarget);
+        clearAll(that);
+        toggleRow(getRow(e.currentTarget), that, false, false);
+    };
+
+    var toggleRow = function (row, that, clearAll, useShift) {
+        if (clearAll) {
+            row = $(row);
+            that.bootstrapTable("getOptions").multipleSelectRowLastSelectedRow = undefined;
+            row.removeClass(that.bootstrapTable("getOptions").multipleSelectRowCssClass);
+            that.bootstrapTable("uncheck", row.data("index"));    
+        } else {
+            that.bootstrapTable("getOptions").multipleSelectRowLastSelectedRow = row;
+            row = $(row);
+            if (useShift) {
+                row.addClass(that.bootstrapTable("getOptions").multipleSelectRowCssClass);
+                that.bootstrapTable("check", row.data("index"));  
+            } else {
+                if(row.hasClass(that.bootstrapTable("getOptions").multipleSelectRowCssClass)) {
+                    row.removeClass(that.bootstrapTable("getOptions").multipleSelectRowCssClass)
+                    that.bootstrapTable("uncheck", row.data("index"));  
+                } else {
+                    row.addClass(that.bootstrapTable("getOptions").multipleSelectRowCssClass);
+                    that.bootstrapTable("check", row.data("index"));  
+                }
+            }
+        }
+    };
+
+    var selectRowsBetweenIndexes = function (indexes, that) {
+        indexes.sort(function(a, b) {
+            return a - b;
+        });
+
+        for (var i = indexes[0]; i <= indexes[1]; i++) {
+            toggleRow(that.bootstrapTable("getOptions").multipleSelectRowRows[i-1], that, false, true);
+        }
+    };
+
+    var clearAll = function (that) {
+        for (var i = 0; i < that.bootstrapTable("getOptions").multipleSelectRowRows.length; i++) {
+            toggleRow(that.bootstrapTable("getOptions").multipleSelectRowRows[i], that, true, false);
+        }
+    };
+    
+    $.extend($.fn.bootstrapTable.defaults, {
+        multipleSelectRow: false,
+        multipleSelectRowCssClass: 'multiple-select-row-selected',
+        //internal variables used by the extension
+        multipleSelectRowLastSelectedRow: undefined,
+        multipleSelectRowRows: []
+    });
+
+    var BootstrapTable = $.fn.bootstrapTable.Constructor,
+        _init = BootstrapTable.prototype.init,
+        _initBody = BootstrapTable.prototype.initBody;
+
+    BootstrapTable.prototype.init = function () {
+        if (this.options.multipleSelectRow) {
+            var that = this;
+
+            //Make sure that the internal variables have the correct value
+            this.options.multipleSelectRowLastSelectedRow = undefined;
+            this.options.multipleSelectRowRows = [];
+            
+            this.$el.on("post-body.bs.table", function (e) {
+                setTimeout(function () {
+                    that.options.multipleSelectRowRows = that.$body.children();
+                    that.options.multipleSelectRowRows.click(onRowClick);
+                    that.options.multipleSelectRowRows.find("input[type=checkbox]").change(onCheckboxChange);
+                }, 1);
+            });
+        }
+
+        _init.apply(this, Array.prototype.slice.apply(arguments));
+    };
+
+    BootstrapTable.prototype.clearAllMultipleSelectionRow = function () {
+        clearAll(this);
+    };
+
+    $.fn.bootstrapTable.methods.push('clearAllMultipleSelectionRow');
+}(jQuery);

File diff suppressed because it is too large
+ 7 - 0
dist/extensions/multiple-selection-row/bootstrap-table-multiple-selection-row.min.js


+ 1 - 1
dist/extensions/multiple-sort/bootstrap-table-multiple-sort.js

@@ -257,7 +257,7 @@
             });
 
             this.$el.on('load-success.bs.table', function() {
-                if (!isSingleSort && that.options.sortPriority !== null && typeof that.options.sortPriority === 'object') {
+                if (!isSingleSort && that.options.sortPriority !== null && typeof that.options.sortPriority === 'object' && that.options.sidePagination !== 'server') {
                     that.onMultipleSort();
                 }
             });

File diff suppressed because it is too large
+ 3 - 3
dist/extensions/multiple-sort/bootstrap-table-multiple-sort.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/extensions/natural-sorting/bootstrap-table-natural-sorting.min.js


+ 133 - 0
dist/extensions/print/bootstrap-table-print.js

@@ -0,0 +1,133 @@
+(function ($) {
+    'use strict';
+
+    var sprintf = $.fn.bootstrapTable.utils.sprintf;
+
+    function printPageBuilderDefault(table) {
+        return '<html><head>' +
+            '<style type="text/css" media="print">' +
+            '  @page { size: auto;   margin: 25px 0 25px 0; }' +
+            '</style>' +
+            '<style type="text/css" media="all">' +
+            'table{border-collapse: collapse; font-size: 12px; }\n' +
+            'table, th, td {border: 1px solid grey}\n' +
+            'th, td {text-align: center; vertical-align: middle;}\n' +
+            'p {font-weight: bold; margin-left:20px }\n' +
+            'table { width:94%; margin-left:3%; margin-right:3%}\n' +
+            'div.bs-table-print { text-align:center;}\n' +
+            '</style></head><title>Print Table</title><body>' +
+            '<p>Printed on: ' + new Date + ' </p>' +
+            '<div class="bs-table-print">' + table + "</div></body></html>";
+    }
+    $.extend($.fn.bootstrapTable.defaults, {
+        showPrint: false,
+        printAsFilteredAndSortedOnUI: true, //boolean, when true - print table as sorted and filtered on UI.
+                                            //Please note that if true is set, along with explicit predefined print options for filtering and sorting (printFilter, printSortOrder, printSortColumn)- then they will be applied on data already filtered and sorted by UI controls.
+                                            //For printing data as filtered and sorted on UI - do not set these 3 options:printFilter, printSortOrder, printSortColumn
+        printSortColumn: undefined  , //String, set column field name to be sorted by
+        printSortOrder: 'asc', //String: 'asc' , 'desc'  - relevant only if printSortColumn is set
+        printPageBuilder: function(table){return printPageBuilderDefault(table)} // function, receive html <table> element as string, returns html string for printing. by default delegates to function printPageBuilderDefault(table). used for styling and adding header or footer
+    });
+    $.extend($.fn.bootstrapTable.COLUMN_DEFAULTS, {
+        printFilter: undefined, //set value to filter by in print page
+        printIgnore: false, //boolean, set true to ignore this column in the print page
+        printFormatter:undefined //function(value, row, index), formats the cell value for this column in the printed table. Function behaviour is similar to the 'formatter' column option
+    });
+    $.extend($.fn.bootstrapTable.defaults.icons, {
+        print: 'glyphicon-print icon-share'
+    });
+
+    var BootstrapTable = $.fn.bootstrapTable.Constructor,
+        _initToolbar = BootstrapTable.prototype.initToolbar;
+
+    BootstrapTable.prototype.initToolbar = function () {
+        this.showToolbar = this.options.showPrint;
+
+        _initToolbar.apply(this, Array.prototype.slice.apply(arguments));
+
+        if (this.options.showPrint) {
+            var that = this,
+                $btnGroup = this.$toolbar.find('>.btn-group'),
+                $print = $btnGroup.find('button.bs-print');
+
+            if (!$print.length) {
+                $print = $([
+                    '<button class="bs-print btn btn-default' + sprintf(' btn-%s"', this.options.iconSize) + ' name="print" title="print" type="button">',
+                    sprintf('<i class="%s %s"></i> ', this.options.iconsPrefix, this.options.icons.print),
+                    '</button>'].join('')).appendTo($btnGroup);
+
+                $print.click(function () {
+                    function formatValue(row, i, column ) {
+                        var value = row[column.field];
+                        if (typeof column.printFormatter === 'function') {
+                            return  column.printFormatter.apply(column, [value, row, i]);
+                        }
+                        else {
+                            return  value || "-";
+                        }
+                    }
+                    function buildTable(data,columns) {
+                        var out = "<table><thead><tr>";
+                        for(var h = 0; h < columns.length; h++) {
+                            if(!columns[h].printIgnore) {
+                                out += ("<th>"+columns[h].title+"</th>");
+                            }
+                        }
+                        out += "</tr></thead><tbody>";
+                        for(var i = 0; i < data.length; i++) {
+                            out += "<tr>";
+                            for(var j = 0; j < columns.length; j++) {
+                                if(!columns[j].printIgnore) {
+                                    out += ("<td>"+ formatValue(data[i], i, columns[j])+"</td>");
+                                }
+                            }
+                            out += "</tr>";
+                        }
+                        out += "</tbody></table>";
+                        return out;
+                    }
+                    function sortRows(data,colName,sortOrder) {
+                        if(!colName){
+                            return data;
+                        }
+                        var reverse = sortOrder != 'asc';
+                        reverse = -((+reverse) || -1);
+                        return  data.sort(function (a, b) {
+                            return reverse * (a[colName].localeCompare(b[colName]));
+                        });
+                    }
+                    function filterRow(row,filters) {
+                        for (var index = 0; index < filters.length; ++index) {
+                            if(row[filters[index].colName]!=filters[index].value) {
+                                return false;
+                            }
+                        }
+                        return true;
+                    }
+                    function filterRows(data,filters) {
+                        return data.filter(function (row) {
+                            return filterRow(row,filters)
+                        });
+                    }
+                    function getColumnFilters(columns) {
+                        return !columns || !columns[0] ? [] : columns[0].filter(function (col) {
+                            return col.printFilter;
+                        }).map(function (col) {
+                            return {colName:col.field, value:col.printFilter};
+                        });
+                    }
+                    var doPrint = function (data) {
+                        data=filterRows(data,getColumnFilters(that.options.columns));
+                        data=sortRows(data,that.options.printSortColumn,that.options.printSortOrder);
+                        var table=buildTable(data,that.options.columns[0]);
+                        var newWin = window.open("");
+                        newWin.document.write(that.options.printPageBuilder.call(this, table));
+                        newWin.print();
+                        newWin.close();
+                    };
+                    doPrint(that.options.printAsFilteredAndSortedOnUI? that.getData() : that.options.data.slice(0));
+                });
+            }
+        }
+    };
+})(jQuery);

File diff suppressed because it is too large
+ 7 - 0
dist/extensions/print/bootstrap-table-print.min.js


+ 4 - 0
dist/extensions/reorder-columns/bootstrap-table-reorder-columns.js

@@ -144,6 +144,7 @@
                 for (var i = 0; i < ths.length; i++ ) {
                     columnIndex = $.fn.bootstrapTable.utils.getFieldIndex(that.columns, ths[i]);
                     if (columnIndex !== -1) {
+                        that.columns[columnIndex].fieldIndex = i;
                         columns.push(that.columns[columnIndex]);
                         that.columns.splice(columnIndex, 1);
                     }
@@ -169,6 +170,9 @@
 
                 that.header.fields = ths;
                 that.header.formatters = formatters;
+                that.initHeader();
+                that.initToolbar();
+                that.initBody();
                 that.resetView();
                 that.trigger('reorder-column', ths);
             }

File diff suppressed because it is too large
+ 3 - 3
dist/extensions/reorder-columns/bootstrap-table-reorder-columns.min.js


+ 6 - 4
dist/extensions/reorder-rows/bootstrap-table-reorder-rows.js

@@ -1,10 +1,10 @@
 /**
  * @author: Dennis Hernández
  * @webSite: http://djhvscf.github.io/Blog
- * @version: v1.0.0
+ * @version: v1.0.1
  */
 
-!function ($) {
+(function ($) {
 
     'use strict';
 
@@ -105,7 +105,9 @@
             row.data('index', i).attr('data-index', i);
         }
 
-        tableBsOptions.data = newData;
+        tableBsOptions.data = tableBsOptions.data.slice(0, tableBsData.pageFrom - 1)
+            .concat(newData)
+            .concat(tableBsOptions.data.slice(tableBsData.pageTo));
 
         //Call the user defined function
         tableBsOptions.onReorderRowsDrop.apply(table, [table, droppedRow]);
@@ -113,4 +115,4 @@
         //Call the event reorder-row
         tableBsData.trigger('reorder-row', newData);
     };
-}(jQuery);
+})(jQuery);

File diff suppressed because it is too large
+ 3 - 3
dist/extensions/reorder-rows/bootstrap-table-reorder-rows.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/extensions/resizable/bootstrap-table-resizable.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/extensions/select2-filter/bootstrap-table-select2-filter.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/extensions/sticky-header/bootstrap-table-sticky-header.min.js


+ 2 - 2
dist/extensions/toolbar/bootstrap-table-toolbar.js

@@ -108,7 +108,7 @@
     $.extend($.fn.bootstrapTable.defaults, $.fn.bootstrapTable.locales);
 
     var BootstrapTable = $.fn.bootstrapTable.Constructor,
-        _initToolbar = BootstrapTable.prototype.initToolbar,        
+        _initToolbar = BootstrapTable.prototype.initToolbar,
         _load = BootstrapTable.prototype.load,
         _initSearch = BootstrapTable.prototype.initSearch;
 
@@ -131,7 +131,7 @@
             html = [];
 
         html.push(sprintf('<div class="columns columns-%s btn-group pull-%s" role="group">', this.options.buttonsAlign, this.options.buttonsAlign));
-        html.push(sprintf('<button class="btn btn-default%s' + '" type="button" name="advancedSearch" title="%s">', that.options.iconSize === undefined ? '' : ' btn-' + that.options.iconSize, that.options.formatAdvancedSearch()));
+        html.push(sprintf('<button class="btn btn-default%s' + '" type="button" name="advancedSearch" aria-label="advanced search" title="%s">', that.options.iconSize === undefined ? '' : ' btn-' + that.options.iconSize, that.options.formatAdvancedSearch()));
         html.push(sprintf('<i class="%s %s"></i>', that.options.iconsPrefix, that.options.icons.advancedSearchIcon))
         html.push('</button></div>');
 

File diff suppressed because it is too large
+ 3 - 3
dist/extensions/toolbar/bootstrap-table-toolbar.min.js


File diff suppressed because it is too large
+ 1 - 0
dist/extensions/tree-column/bootstrap-table-tree-column.css


+ 130 - 0
dist/extensions/tree-column/bootstrap-table-tree-column.js

@@ -0,0 +1,130 @@
+/**
+ * @author: KingYang
+ * @webSite: https://github.com/kingyang
+ * @version: v1.0.0
+ */
+
+! function ($) {
+
+    'use strict';
+
+    $.extend($.fn.bootstrapTable.defaults, {
+        treeShowField: null,
+        idField: 'id',
+        parentIdField: 'pid',
+        treeVerticalcls: 'vertical',
+        treeVerticalLastcls: 'vertical last',
+        treeSpacecls: 'space',
+        treeNodecls: 'node',
+        treeCellcls: 'treenode',
+        treeTextcls: 'text',
+        onTreeFormatter: function (row) {
+            var that = this,
+                options = that.options,
+                level = row._level || 0,
+                plevel = row._parent && row._parent._level || 0,
+                paddings = [];
+            for (var i = 0; i < plevel; i++) {
+                paddings.push('<i class="' + options.treeVerticalcls + '"></i>');
+                paddings.push('<i class="' + options.treeSpacecls + '"></i>');
+            }
+
+            for (var i = plevel; i < level; i++) {
+                if (row._last && i === (level - 1)) {
+                    paddings.push('<i class="' + options.treeVerticalLastcls + '"></i>');
+                } else {
+                    paddings.push('<i class="' + options.treeVerticalcls + '"></i>');
+                }
+                paddings.push('<i class="' + options.treeNodecls + '"></i>');
+            }
+            return paddings.join('');
+        }, onGetNodes: function (row, data) {
+            var that = this;
+            var nodes = [];
+            $.each(data, function (i, item) {
+                if (row[that.options.idField] === item[that.options.parentIdField]) {
+                    nodes.push(item);
+                }
+            });
+            return nodes;
+        },
+        onCheckLeaf: function (row, data) {
+            if (row.isLeaf !== undefined) {
+                return row.isLeaf;
+            }
+            return !row._nodes || !row._nodes.length;
+        }, onCheckRoot: function (row, data) {
+            var that = this;
+            return !row[that.options.parentIdField];
+        }
+    });
+
+    var BootstrapTable = $.fn.bootstrapTable.Constructor,
+        _initRow = BootstrapTable.prototype.initRow,
+        _initHeader = BootstrapTable.prototype.initHeader;
+
+    BootstrapTable.prototype.initHeader = function () {
+        var that = this;
+        _initHeader.apply(that, Array.prototype.slice.apply(arguments));
+        var treeShowField = that.options.treeShowField;
+        if (treeShowField) {
+            $.each(this.header.fields, function (i, field) {
+                if (treeShowField === field) {
+                    that.treeEnable = true;
+                    var _formatter = that.header.formatters[i];
+                    var _class = [that.options.treeCellcls];
+                    if (that.header.classes[i]) {
+                        _class.push(that.header.classes[i].split('"')[1] || '');
+                    }
+                    that.header.classes[i] = 'class="' + _class.join(' ') + '"';
+                    that.header.formatters[i] = function (value, row, index) {
+                        var colTree = [that.options.onTreeFormatter.apply(that, [row])];
+                        colTree.push('<span class="' + that.options.treeTextcls + '">');
+                        if (_formatter) {
+                            colTree.push(_formatter.apply(this, Array.prototype.slice.apply(arguments)));
+                        } else {
+                            colTree.push(value);
+                        }
+                        colTree.push('</span>');
+                        return colTree.join('');
+                    };
+                    return false;
+                }
+            });
+        }
+    };
+
+    var initNode = function (item, idx, data, parentDom) {
+        var that = this;
+        var nodes = that.options.onGetNodes.apply(that, [item, data]);
+        item._nodes = nodes;
+        parentDom.append(_initRow.apply(that, [item, idx, data, parentDom]));
+        var len = nodes.length - 1;
+        for (var i = 0; i <= len; i++) {
+            var node = nodes[i];
+            node._level = item._level + 1;
+            node._parent = item;
+            if (i === len)
+                node._last = 1;
+            initNode.apply(that, [node, $.inArray(node, data), data, parentDom]);
+        }
+    };
+
+
+    BootstrapTable.prototype.initRow = function (item, idx, data, parentDom) {
+        var that = this;
+        if (that.treeEnable) {
+            if (that.options.onCheckRoot.apply(that, [item, data])) {
+                if (item._level === undefined) {
+                    item._level = 0;
+                }
+                initNode.apply(that, [item, idx, data, parentDom]);
+                return true;
+            }
+            return false;
+
+        }
+        return _initRow.apply(that, Array.prototype.slice.apply(arguments));
+    };
+
+} (jQuery);

File diff suppressed because it is too large
+ 7 - 0
dist/extensions/tree-column/bootstrap-table-tree-column.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-af-ZA.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-ar-SA.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-ca-ES.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-cs-CZ.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-da-DK.min.js


+ 10 - 4
dist/locale/bootstrap-table-de-DE.js

@@ -10,16 +10,19 @@
       return 'Lade, bitte warten...';
     },
     formatRecordsPerPage: function (pageNumber) {
-      return pageNumber + ' Einträge pro Seite';
+      return pageNumber + ' Einträge pro Seite.';
     },
     formatShowingRows: function (pageFrom, pageTo, totalRows) {
-      return 'Zeige ' + pageFrom + ' bis ' + pageTo + ' von ' + totalRows + ' Zeile' + ((totalRows > 1) ? "n" : "");
+      return 'Zeige Zeile ' + pageFrom + ' bis ' + pageTo + ' von ' + totalRows + ' Zeile' + ((totalRows > 1) ? "n" : "")+".";
+    },
+    formatDetailPagination: function (totalRows) {
+      return 'Zeige ' + totalRows + ' Zeile' + ((totalRows > 1) ? "n" : "")+".";
     },
     formatSearch: function () {
-      return 'Suchen';
+      return 'Suchen ...';
     },
     formatNoMatches: function () {
-      return 'Keine passenden Ergebnisse gefunden';
+      return 'Keine passenden Ergebnisse gefunden.';
     },
     formatRefresh: function () {
       return 'Neu laden';
@@ -29,6 +32,9 @@
     },
     formatColumns: function () {
       return 'Spalten';
+    },
+    formatAllRows: function () {
+      return 'Alle';
     }
   };
 

File diff suppressed because it is too large
+ 3 - 3
dist/locale/bootstrap-table-de-DE.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-el-GR.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-en-US.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-es-AR.min.js


+ 44 - 0
dist/locale/bootstrap-table-es-CL.js

@@ -0,0 +1,44 @@
+/**
+ * Traducción de librería Bootstrap Table a Español (Chile)
+ * @author Brian Álvarez Azócar
+ * email brianalvarezazocar@gmail.com
+ */
+(function($) {
+  'use strict';
+
+  $.fn.bootstrapTable.locales['es-CL'] = {
+    formatLoadingMessage: function() {
+      return 'Cargando, espere por favor...';
+    },
+    formatRecordsPerPage: function(pageNumber) {
+      return pageNumber + ' filas por p\u00E1gina';
+    },
+    formatShowingRows: function(pageFrom, pageTo, totalRows) {
+      return 'Mostrando ' + pageFrom + ' a ' + pageTo + ' de ' + totalRows + ' filas';
+    },
+    formatSearch: function() {
+      return 'Buscar';
+    },
+    formatNoMatches: function() {
+      return 'No se encontraron registros';
+    },
+    formatPaginationSwitch: function() {
+      return 'Ocultar/Mostrar paginaci\u00F3n';
+    },
+    formatRefresh: function() {
+      return 'Refrescar';
+    },
+    formatToggle: function() {
+      return 'Cambiar';
+    },
+    formatColumns: function() {
+      return 'Columnas';
+    },
+    formatAllRows: function() {
+      return 'Todo';
+    }
+  };
+
+  $.extend($.fn.bootstrapTable.defaults, $.fn.bootstrapTable.locales['es-CL']);
+
+})(jQuery);

File diff suppressed because it is too large
+ 7 - 0
dist/locale/bootstrap-table-es-CL.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-es-CR.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-es-ES.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-es-MX.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-es-NI.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-es-SP.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-et-EE.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-fa-IR.min.js


+ 2 - 2
dist/locale/bootstrap-table-fr-BE.min.js

@@ -1,7 +1,7 @@
 /*
-* bootstrap-table - v1.11.0 - 2016-07-02
+* bootstrap-table - v1.11.1 - 2017-02-22
 * https://github.com/wenzhixin/bootstrap-table
-* Copyright (c) 2016 zhixin wen
+* Copyright (c) 2017 zhixin wen
 * Licensed MIT License
 */
 !function(a){"use strict";a.fn.bootstrapTable.locales["fr-BE"]={formatLoadingMessage:function(){return"Chargement en cours..."},formatRecordsPerPage:function(a){return a+" entrées par page"},formatShowingRows:function(a,b,c){return"Affiche de"+a+" à "+b+" sur "+c+" lignes"},formatSearch:function(){return"Recherche"},formatNoMatches:function(){return"Pas de fichiers trouvés"}},a.extend(a.fn.bootstrapTable.defaults,a.fn.bootstrapTable.locales["fr-BE"])}(jQuery);

File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-fr-FR.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-he-IL.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-hr-HR.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-hu-HU.min.js


+ 49 - 0
dist/locale/bootstrap-table-id-ID.js

@@ -0,0 +1,49 @@
+/**
+ * Bootstrap Table Indonesian translation
+ * Author: Andre Gardiner<andre@sirdre.com> 
+ */
+(function ($) {
+    'use strict';
+
+    $.fn.bootstrapTable.locales['id-ID'] = {
+        formatLoadingMessage: function () {
+            return 'Memuat, mohon tunggu...';
+        },
+        formatRecordsPerPage: function (pageNumber) {
+            return pageNumber + ' baris per halaman';
+        },
+        formatShowingRows: function (pageFrom, pageTo, totalRows) {
+            return 'Menampilkan ' + pageFrom + ' sampai ' + pageTo + ' dari ' + totalRows + ' baris';
+        }, 
+        formatSearch: function () {
+            return 'Pencarian';
+        },
+        formatNoMatches: function () {
+            return 'Tidak ditemukan data yang cocok';
+        },
+        formatPaginationSwitch: function () {
+            return 'Sembunyikan/Tampilkan halaman';
+        },
+        formatRefresh: function () {
+            return 'Muat ulang';
+        },
+        formatToggle: function () {
+            return 'Beralih';
+        },
+        formatColumns: function () {
+            return 'kolom';
+        },
+        formatAllRows: function () {
+            return 'Semua';
+        },
+        formatExport: function () {
+            return 'Ekspor data';
+        },
+        formatClearFilters: function () {
+            return 'Bersihkan filter';
+        }
+    };
+
+    $.extend($.fn.bootstrapTable.defaults, $.fn.bootstrapTable.locales['id-ID']);
+
+})(jQuery);

File diff suppressed because it is too large
+ 7 - 0
dist/locale/bootstrap-table-id-ID.min.js


+ 12 - 2
dist/locale/bootstrap-table-it-IT.js

@@ -15,7 +15,7 @@
             return pageNumber + ' elementi per pagina';
         },
         formatShowingRows: function (pageFrom, pageTo, totalRows) {
-            return 'Pagina ' + pageFrom + ' di ' + pageTo + ' (' + totalRows + ' elementi)';
+            return 'Elementi mostrati da ' + pageFrom + ' a ' + pageTo + ' (Numero totali di elementi ' + totalRows + ')';
         },
         formatSearch: function () {
             return 'Cerca';
@@ -23,18 +23,28 @@
         formatNoMatches: function () {
             return 'Nessun elemento trovato';
         },
+        formatPaginationSwitch: function () {
+            return 'Nascondi/Mostra paginazione';
+        },
         formatRefresh: function () {
             return 'Aggiorna';
         },
         formatToggle: function () {
-            return 'Alterna';
+            return 'Attiva/Disattiva';
         },
         formatColumns: function () {
             return 'Colonne';
         },
         formatAllRows: function () {
             return 'Tutto';
+        },
+        formatExport: function () {
+            return 'Esporta dati';
+        },
+        formatClearFilters: function () {
+            return 'Pulisci filtri';
         }
+        
     };
 
     $.extend($.fn.bootstrapTable.defaults, $.fn.bootstrapTable.locales['it-IT']);

File diff suppressed because it is too large
+ 3 - 3
dist/locale/bootstrap-table-it-IT.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-ja-JP.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-ka-GE.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-ko-KR.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-ms-MY.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-nb-NO.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-nl-NL.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-pl-PL.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-pt-BR.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-pt-PT.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-ro-RO.min.js


+ 33 - 0
dist/locale/bootstrap-table-ru-RU.js

@@ -31,6 +31,39 @@
         },
         formatClearFilters: function () {
             return 'Очистить фильтры';
+        },
+        formatMultipleSort: function () {
+            return 'Множественная сортировка';
+        },
+        formatAddLevel: function () {
+            return 'Добавить уровень';
+        },
+        formatDeleteLevel: function () {
+            return 'Удалить уровень';
+        },
+        formatColumn: function () {
+            return 'Колонка';
+        },
+        formatOrder: function () {
+            return 'Порядок';
+        },
+        formatSortBy: function () {
+            return 'Сортировать по';
+        },
+        formatThenBy: function () {
+            return 'затем по';
+        },
+        formatSort: function () {
+            return 'Сортировать';
+        },
+        formatCancel: function () {
+            return 'Отмена';
+        },
+        formatDuplicateAlertTitle: function () {
+            return 'Дублирование колонок!';
+        },
+        formatDuplicateAlertDescription: function () {
+            return 'Удалите, пожалуйста, дублирующую колонку, или замените ее на другую.';
         }
     };
 

File diff suppressed because it is too large
+ 3 - 3
dist/locale/bootstrap-table-ru-RU.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-sk-SK.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-sv-SE.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-th-TH.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-tr-TR.min.js


+ 36 - 0
dist/locale/bootstrap-table-uk-UA.js

@@ -29,6 +29,42 @@
         },
         formatColumns: function () {
             return 'Стовпці';
+        },
+        formatClearFilters: function () {
+            return 'Очистити фільтри';
+        },
+        formatMultipleSort: function () {
+            return 'Сортування за кількома стовпцями';
+        },
+        formatAddLevel: function () {
+            return 'Додати рівень';
+        },
+        formatDeleteLevel: function () {
+            return 'Видалити рівень';
+        },
+        formatColumn: function () {
+            return 'Стовпець';
+        },
+        formatOrder: function () {
+            return 'Порядок';
+        },
+        formatSortBy: function () {
+            return 'Сортувати за';
+        },
+        formatThenBy: function () {
+            return 'потім за';
+        },
+        formatSort: function () {
+            return 'Сортувати';
+        },
+        formatCancel: function () {
+            return 'Скасувати';
+        },
+        formatDuplicateAlertTitle: function () {
+            return 'Дублювання стовпців!';
+        },
+        formatDuplicateAlertDescription: function () {
+            return 'Видаліть, будь ласка, дублюючий стовпець, або замініть його на інший.';
         }
     };
 

File diff suppressed because it is too large
+ 3 - 3
dist/locale/bootstrap-table-uk-UA.min.js


File diff suppressed because it is too large
+ 2 - 2
dist/locale/bootstrap-table-ur-PK.min.js


+ 0 - 0
dist/locale/bootstrap-table-uz-Latn-UZ.js


Some files were not shown because too many files changed in this diff