Kanban ordering saved incorrectly when moving multiple tasks to a different bucket

First of all: really awesome project. Thanks for the effort you are putting in!

I have a workflow in the kanban board, where I use two buckets to sort my tasks. Sadly this doesn’t work properly anymore (pretty sure it worked in 0.24, but there were other issues).

Issue:

When moving multiple tasks from one kanban bucket to another, the ordering is saved incorrectly.

Reproduce:

on try.vikunja.io version v2.2.2-45-1c0513de

  • Create Tasks in one bucket
  • (Hit F5)
  • Move tasks to another (e.g. empty) bucket in a different order
  • Hit F5
  • Tasks do not have the same order as before

Further investigation:

Happens if a task is moved to a position adjacent to a task that was moved before to the bucket (without F5 refresh in between)

Looking at the web-requests sent it is revealed that the position calculation algorithm uses position=0 for the previously moved task.

Let me know, if you need further details or context. Thanks!