Fix calculating kanban position for tasks

This commit is contained in:
kolaente 2021-07-28 20:36:27 +02:00
parent b130424498
commit 110873c780
Signed by: konrad
GPG Key ID: F40E70337AB24C9B

View File

@ -374,7 +374,7 @@ export default {
const taskBefore = newBucket.tasks[e.newIndex - 1] ?? null
const taskAfter = newBucket.tasks[e.newIndex + 1] ?? null
task.kanban_position = calculateItemPosition(taskBefore !== null ? taskBefore.position : null, taskAfter !== null ? taskAfter.position : null)
task.kanbanPosition = calculateItemPosition(taskBefore !== null ? taskBefore.kanbanPosition : null, taskAfter !== null ? taskAfter.kanbanPosition : null)
task.bucketId = newBucket.id
this.$store.dispatch('tasks/update', task)