You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description of the problem:
There are several problems when using the PrimeReact DataTable in edit mode in combination with a sort function:
Cell editing and sorting:
When I edit values in the “Quantity” column, I also sort the values in the table afterwards. The values are then also displayed correctly in the table. However, when I click on the same table field, the old values are displayed instead of the updated values.
Tab behavior: When I press the tab button to move to the next cell, the input field of the current cell is not closed and the focus remains partially in the old cell, resulting in unpredictable behavior.
If there is a problem with the reproduction of the problem, please let me know.
click on a cell in the Quantity column (for example, on the cell with the value “24”) and change the value to “1”.
exit edit mode by clicking on another field.
the table should refresh and the value in the Quantity column should now show “1”. Since the table is sorted by the Quantity column, the changed value should now be at the bottom of the table (since “1” is smaller than the other values).
now search for and click on the cell that originally contained “24” and now shows “73”, for example, due to the sorting.
exit edit mode by clicking on another field again.
Expected behavior
After editing cells, the new values in the edited cells should be saved and sorted correctly. The sorted values should be displayed correctly when the same field is clicked again.
When the Tab key is pressed, the input field of the current cell should be closed and editing of the next cell should be opened.
The text was updated successfully, but these errors were encountered:
Oko-Tester
changed the title
DataTable: Sorting updates cell values incorrectly after editing in edit mode
DataTable: Edited cell values are not updated correctly after sorting and tab behavior is inconsistent
Oct 11, 2024
melloware
added
Type: Bug
Issue contains a defect related to a specific component.
and removed
Status: Needs Triage
Issue will be reviewed by Core Team and a relevant label will be added as soon as possible
labels
Oct 11, 2024
Describe the bug
Description:
Description of the problem:
There are several problems when using the PrimeReact DataTable in edit mode in combination with a sort function:
Cell editing and sorting:
If there is a problem with the reproduction of the problem, please let me know.
Reproducer
https://stackblitz.com/edit/pn5gam?file=src%2FApp.jsx
System Information
Steps to reproduce the behavior
Expected behavior
After editing cells, the new values in the edited cells should be saved and sorted correctly. The sorted values should be displayed correctly when the same field is clicked again.
When the Tab key is pressed, the input field of the current cell should be closed and editing of the next cell should be opened.
The text was updated successfully, but these errors were encountered: