gregnb / gregnb/mui-datatables
onFilterChange displays data with no chip while making a server side filtering
- Dominant language
- JavaScript
- Stars
- 2.7k
- Forks
- 906
- PR merge metrics
- No merged PRs in 30d
Description
When using onFilterChange to make a request to the server side the chip don't got displayed as well as the filter dropdown box loses the filter option.
## Expected Behavior
If you want to reproduce the issue just try to create a server side filtration.
the expected behavior is that the chip as well as the value inside the dropdown box to remain the same as with no server side request.
## Current Behavior
The app is working with redux so the table data comes from redux store, Pagination and filtering should take place in the server side so I'm dispatching an action in the onFilterChange function that replaces the data with the filtered data and it works but the chip that represents the filtered data as well as the place holders don't show anything.
## Steps to Reproduce (for bugs)
1.set onFilterChange to make a request
2. whether you're working with redux or not just update the state with the new data
3. execute filter
4. check for the placeholder and the filter chip
## Your Environment
| Tech | Version |
|--------------|---------|
| Material-UI | 3.9.2 |
| MUI-datatables | 2.5.1 |
| React | 16.8.2 |
| browser | Chrome |
| etc | |
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reproducing the issue with onFilterChange while replacing table data from state, then compare the filter chip and dropdown value before and after the server-side update. Done means the filtered data is updated while the chip and selected filter value remain visible; review the existing issue discussion for context because no source file or test is identified.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, react
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100