fix improper prop 'dataSource' change in Table; close #2501 (#2503)

This commit is contained in:
Vincent Zhang 2016-07-26 14:17:41 +08:00 committed by 偏右
parent f4b10a9e7c
commit abecc44d38

View File

@ -717,7 +717,7 @@ export default class Table extends React.Component {
//
data = data.slice(0);
for (let i = 0; i < data.length; i++) {
data[i].indexForSort = i;
data[i] = { ...data[i], indexForSort: i };
}
const sorterFn = this.getSorterFn();
if (sorterFn) {