I would prefer the second option or using a custom widget for sorting.
Another way would be using the Tables API