Browse Source

Improve the getDataAttr

Dennis Hernández 10 years ago
parent
commit
6e423ef3ad
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/bootstrap-table.js

+ 2 - 2
src/bootstrap-table.js

@@ -439,7 +439,7 @@
             var column = $.extend({}, {
             var column = $.extend({}, {
                 title: $(this).html(),
                 title: $(this).html(),
                 'class': $(this).attr('class')
                 'class': $(this).attr('class')
-            }, $(this).data());
+            }, getRealDataAttr($(this).data()));
 
 
             columns.push(column);
             columns.push(column);
         });
         });
@@ -460,7 +460,7 @@
             // save tr's id, class and data-* attributes
             // save tr's id, class and data-* attributes
             row._id = $(this).attr('id');
             row._id = $(this).attr('id');
             row._class = $(this).attr('class');
             row._class = $(this).attr('class');
-            row._data = $(this).data();
+            row._data = getRealDataAttr($(this).data());
 
 
             $(this).find('td').each(function (i) {
             $(this).find('td').each(function (i) {
                 var field = that.options.columns[i].field;
                 var field = that.options.columns[i].field;