Browse Source

无数据的行不需要绑定事件

geeyan 10 years ago
parent
commit
c23e73d8c4
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/bootstrap-table.js

+ 1 - 1
src/bootstrap-table.js

@@ -1642,7 +1642,7 @@
             }
 
             for (var key in events) {
-                that.$body.find('>tr').each(function () {
+                that.$body.find('>tr:not(.no-records-found)').each(function () {
                     var $tr = $(this),
                         $td = $tr.find(that.options.cardView ? '.card-view' : 'td').eq(fieldIndex),
                         index = key.indexOf(' '),