Skip to content

Commit

Permalink
Table
Browse files Browse the repository at this point in the history
  • Loading branch information
rickyleung committed Oct 30, 2015
1 parent 1ef8ab4 commit ecc844d
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions dist/jquery.bizui.js
Original file line number Diff line number Diff line change
Expand Up @@ -13210,12 +13210,12 @@ define('ui/Table',['require','ui/util','dep/jquery.resizableColumns','dep/jquery
this.$main = $(this.main);

var defaultOption = {
data: [],
selectable: false,
resizable: false,
topOffset: 0
};
this.options = $.extend(defaultOption, options || {});
this.options.data = this.options.data ? this.options.data : [];
this.options = $.extend(true, defaultOption, options || {});
this.init(this.options);
}

Expand Down Expand Up @@ -13677,7 +13677,7 @@ define('ui/Table',['require','ui/util','dep/jquery.resizableColumns','dep/jquery
* @param {Object} data 行数据
*/
updateRow: function(rowIndex, data) {
this.options.data[rowIndex - 1] = $.extend({}, data);
this.options.data[rowIndex - 1] = $.extend(true, {}, data);
this.refresh();
},

Expand Down
2 changes: 1 addition & 1 deletion dist/jquery.bizui.min.js

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions src/ui/Table.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,12 @@ define(function(require) {
this.$main = $(this.main);

var defaultOption = {
data: [],
selectable: false,
resizable: false,
topOffset: 0
};
this.options = $.extend(defaultOption, options || {});
this.options.data = this.options.data ? this.options.data : [];
this.options = $.extend(true, defaultOption, options || {});
this.init(this.options);
}

Expand Down Expand Up @@ -528,7 +528,7 @@ define(function(require) {
* @param {Object} data 行数据
*/
updateRow: function(rowIndex, data) {
this.options.data[rowIndex - 1] = $.extend({}, data);
this.options.data[rowIndex - 1] = $.extend(true, {}, data);
this.refresh();
},

Expand Down

0 comments on commit ecc844d

Please sign in to comment.