mirror of
https://github.com/zuiidea/antd-admin
synced 2026-10-25 01:40:20 +00:00
fix dataTable other fetch params
This commit is contained in:
@@ -51,7 +51,7 @@ class DataTable extends React.Component {
|
||||
}
|
||||
|
||||
fetch = () => {
|
||||
const { fetch: { url, data, dataKey } } = this.props
|
||||
const { fetch: { url, data, dataKey, ...otherFetch } } = this.props
|
||||
const { fetchData } = this.state
|
||||
this.setState({ loading: true })
|
||||
request(url, {
|
||||
@@ -60,6 +60,7 @@ class DataTable extends React.Component {
|
||||
...data,
|
||||
...fetchData,
|
||||
},
|
||||
...otherFetch,
|
||||
}).then((result) => {
|
||||
const { pagination } = this.state
|
||||
pagination.total = result.total || pagination.total
|
||||
|
||||
Reference in New Issue
Block a user