List of items, each has: Order, Category.
List can be sorted: by order, by category (actually two sort descriptors here: first by category, second by order). And grouped: none, by category.
When sorting is "by order" user can do drag-n-drop in list.
After close form, Order field overwrited with new item posistion.
Unclear exepected behavior when list sorted by order and grouped by category. Simple example:
1 a - cat1 2 x - cat2 3 b - cat1 4 y - cat2 5 c - cat1
Allow to drag only between groups to change only group. Different drag action depending on current grouping.
Allow to drag only inside one group, change order only for items in that group. Thats may be strange - after ungrouping (3) wisely ordered items became not close to each other.
1 2 3 x x c y y x a c a b a y c b b
Mixed. Dragging to other group makes in two passes: first change group, second reorder items in that group.
Any reason against mixed approach? It there better solution?
Some thoughts in addition. If add option to grouping by readonly field (creation date), reordering beween groups is impossible at all.