ranked-model
ranked-model copied to clipboard
Fix/place new elements in front
fixes #99 when placing new elements in front (or with the same rank as an already existing)
Is there any issue with this PR or any reason not to apply it?
Hi @emrox, I'm happy to look at this for you. Can you give me a bit more of a detailed rundown of the problem? I've looked at your code and the issue but it's not clear to me if this is a bug.
Are you saying that when you grab an existing items position and set your moving item's position to the existing items position (i.e. push the existing item down the list and insert this moving item there) that it doesn't work as expected?
It's my understanding that you shouldn't use the rank column directly but rather the position pseudo-value. So grab the existing items swimming_rank_position
then use that to move the other item.
Let me know your thoughts on that.