Browse Source

Fix #912 Bug when switching to card view

Dennis Hernández 10 years ago
parent
commit
f95da48a5b
1 changed files with 3 additions and 4 deletions
  1. 3 4
      src/bootstrap-table.js

+ 3 - 4
src/bootstrap-table.js

@@ -1781,8 +1781,7 @@
     // =======================
 
     BootstrapTable.prototype.resetView = function (params) {
-        var that = this,
-            padding = 0;
+        var padding = 0;
 
         if (params && params.height) {
             this.options.height = params.height;
@@ -1801,8 +1800,8 @@
 
         if (this.options.cardView) {
             // remove the element css
-            that.$el.css('margin-top', '0');
-            $tableContainer.css('padding-bottom', '0');
+            this.$el.css('margin-top', '0');
+            this.$tableContainer.css('padding-bottom', '0');
             return;
         }