mirror of
https://github.com/ant-design/ant-design.git
synced 2025-08-06 07:56:28 +08:00
💄 code style optimizaiton
This commit is contained in:
parent
bc2d24646e
commit
22179f3511
@ -132,7 +132,7 @@ class App extends React.Component {
|
||||
...this.getColumnSearchProps('address'),
|
||||
},
|
||||
];
|
||||
return <Table columns={columns} dataSource={data} />;
|
||||
return <Table columns={columns} dataSource={data} onChange={this.onChange} />;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -138,12 +138,13 @@ class FilterMenu<T> extends React.Component<FilterMenuProps<T>, FilterMenuState<
|
||||
};
|
||||
|
||||
confirmFilter() {
|
||||
const { column, selectedKeys: propSelectedKeys, confirmFilter } = this.props;
|
||||
const { selectedKeys, valueKeys } = this.state;
|
||||
const { filterDropdown } = this.props.column;
|
||||
const { filterDropdown } = column;
|
||||
|
||||
if (!shallowequal(selectedKeys, this.props.selectedKeys)) {
|
||||
this.props.confirmFilter(
|
||||
this.props.column,
|
||||
if (!shallowequal(selectedKeys, propSelectedKeys)) {
|
||||
confirmFilter(
|
||||
column,
|
||||
filterDropdown
|
||||
? selectedKeys
|
||||
: selectedKeys.map(key => valueKeys[key]).filter(key => key !== undefined),
|
||||
|
Loading…
Reference in New Issue
Block a user