6

I have a table that is sortable via clicking on the column headers. The table rows are also editable (by clicking directly into a cell).

A really frustrating side effect is that when you modify a cell (for example checking/unchecking a boolean value), the whole associated row suddenly jumps and disappears, because it is being dynamically sorted.

What is the normal way of doing things in this situation? Should the sort be deactivated whenever modifying a row?

5

A possible solution would be to show where the row landed by scrolling the entire table up or down after the edit is complete, then showing a highlight around the position of the new location. Nothing that would last very long, just enough time that the user can locate where it went. This would require some animation and scroll hijacking, but I like the use of scroll hijack in this case - gives the user the feedback they need and still allows the view to feel dynamic and alive.

  • 1
    yes good point. but if a user wants to tick off a whole lot of rows at one time, they will lose their position and would have to scroll back to the position there were at. – Oliver Watkins May 6 '14 at 9:17
0

This is a tricky problem when you are implementing this stuff yourself.

All the searchable grid controls I have come across (both inhouse developed and third party) have some concept of "submitting" the changes in the row before it is considered to be the data contained in that row, i.e. before the changes can be accessed by sort / group functionality. For inline editing there is normally an event of some kind that "submits" the data, such as clicking off of the row or cell being edited. You need to sort / filter on the unedited data for the row until you have some signal from the user that they are finished with the edit.

  • Editing and sorting both possible at the same time? Wow. So what would you do when the new sort order would take the row being edited off view (out of the view port)? Discard the changes or save them? If you pop-up an alert that you can't sort because a row is currently being edited, then there is no need to sort/filter on unedited data. – Marjan Venema May 5 '14 at 15:33
  • @MarjanVenema I see what you mean, but that's not what I meant. Sorting is always enabled, but until the user gives the signal that they are "finished" with the row edit, the sorting is carried out on the original (unedited) row data. If the user clicks off the row in inline editing mode to change the filter then this is the "finished" signal that the changes can be submitted. The only time that they would receive a pop up alert like this is if validation on the edited row failed. – Franchesca May 5 '14 at 16:13
  • Sorry, not getting it. We might be talking at tangents. If clicking to change the sort order or filter criteria ends the edit, then there is no need to sort/filter on "unedited" data as the edits are either saved or discarded before the new sort order or filter criteria are effectuated. – Marjan Venema May 5 '14 at 20:04
  • @MarjanVenema The original question states that "A really frustrating side effect is that when you modify a cell (for example checking/unchecking a boolean value), the whole associated row suddenly jumps and disappears, because it is being dynamically sorted". I am suggesting that, in the example of the boolean value cell, the row should not be resorted on the "check value changed" event. The user needs time to review the changes. Instead we could detect when the user leaves the row / cell, and then decide that the edit is finished. Resorting on the new value would then take place. – Franchesca May 5 '14 at 20:45
  • Ah, missed that bit. Yes, of course, sorting/filtering should never be done while in editing mode. – Marjan Venema May 5 '14 at 20:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.