mirror of
https://github.com/gosticks/react-table.git
synced 2026-12-04 03:31:49 +00:00
update fireFetchData to use current state for select value (#1231)
This commit is contained in:
committed by
Tanner Linsley
parent
221164484f
commit
168a8e3f93
+9
-1
@@ -331,7 +331,15 @@ export default Base =>
|
||||
}
|
||||
|
||||
fireFetchData () {
|
||||
this.props.onFetchData(this.getResolvedState(), this)
|
||||
// determine the current state, preferring certain state values over props
|
||||
const currentState = {
|
||||
...this.getResolvedState(),
|
||||
page: this.getStateOrProp('page'),
|
||||
pageSize: this.getStateOrProp('pageSize'),
|
||||
filter: this.getStateOrProp('filter'),
|
||||
};
|
||||
|
||||
this.props.onFetchData(currentState, this)
|
||||
}
|
||||
|
||||
getPropOrState (key) {
|
||||
|
||||
Reference in New Issue
Block a user