Opened 8 years ago

Closed 8 years ago

#12649 closed defect (fixed)

EDG - nested sorting info is not following after column moved

Reported by: evan Owned by: evan
Priority: high Milestone: 1.7
Component: DojoX Grid Version: 1.6.0
Keywords: edg, nestedsorting, column, dnd, moving Cc:
Blocked By: Blocking:

Description

Sorting info and focus are not following after column(s) moved

Attachments (1)

nested_sort.patch (1.4 KB) - added by AJ Shankar 8 years ago.
Patch to fixed NestedSorting? column reordering code

Download all attachments as: .zip

Change History (4)

comment:1 Changed 8 years ago by evan

Resolution: fixed
Status: newclosed

(In [24285]) Fixes #12649, !strict, making sure sorting info and focus follows after column(s) moved, patch from Nate(IBM, CCLA), applied both to trunk and 1.6 branch

Changed 8 years ago by AJ Shankar

Attachment: nested_sort.patch added

Patch to fixed NestedSorting? column reordering code

comment:2 Changed 8 years ago by AJ Shankar

Resolution: fixed
Status: closedreopened

This patch does not handle the case where the column that is reordered is not a nestedSort column. For instance, if a grid is sorted by column 2, and column 3 is dragged over to column 2 (thus pushing column 2 to the 3 spot), the grid still indicates that column 2 is the sorted column.

This is because its logic only checks to see whether the moved columns are sorted columns. It does not account for the fact that a column can be indirectly repositioned, in an absolute sense, when a column to its left is moved to its right, and vice versa.

I have patched the code to solve this problem. Attached is a diff of /dojox/grid/enhanced/plugins/NestedSorting.js.

comment:3 Changed 8 years ago by evan

Milestone: 1.6.11.7
Resolution: fixed
Status: reopenedclosed

Thanks ajshankar!

Actually it's caused by an issue in DnD - the column mapping is incorrect in some occasions e.g. target pos < source column index, it's fixed with [25506], with that, nested sorting is now working well with column moving.

Note: See TracTickets for help on using tickets.