修复本地模式排序头状态失效

This commit is contained in:
afc163 2015-07-31 12:41:29 +08:00
parent 988bdf09bc
commit 7d0413fbb6

View File

@ -235,7 +235,6 @@ export default React.createClass({
renderColumnsDropdown(columns) { renderColumnsDropdown(columns) {
return columns.map((column) => { return columns.map((column) => {
column = objectAssign({}, column);
let key = this.getColumnKey(column); let key = this.getColumnKey(column);
let filterDropdown, menus, sortButton; let filterDropdown, menus, sortButton;
if (column.filters && column.filters.length > 0) { if (column.filters && column.filters.length > 0) {
@ -270,9 +269,11 @@ export default React.createClass({
</span> </span>
</div>; </div>;
} }
let originalTitle = column.title; if (!column.originalTitle) {
column.originalTitle = column.title;
}
column.title = [ column.title = [
originalTitle, column.originalTitle,
sortButton, sortButton,
filterDropdown filterDropdown
]; ];