From 0604f8d81ae4b7fecf977c1ed829acad35ee9270 Mon Sep 17 00:00:00 2001 From: Lars de Ridder Date: Thu, 12 Mar 2026 15:57:21 +0100 Subject: [PATCH] fix(task): only pick up done state from bucket change response Spreading the full response task from the bucket change endpoint overwrote fields like maxPermission with null, causing the action buttons and edit icon to disappear after changing buckets. --- frontend/src/components/tasks/partials/BucketSelect.vue | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/frontend/src/components/tasks/partials/BucketSelect.vue b/frontend/src/components/tasks/partials/BucketSelect.vue index ca673ab8b..72e33c58a 100644 --- a/frontend/src/components/tasks/partials/BucketSelect.vue +++ b/frontend/src/components/tasks/partials/BucketSelect.vue @@ -158,11 +158,13 @@ async function changeBucket(bucket: IBucket) { kanbanStore.moveTaskToBucket(props.task, bucket.id) - // Use the task from the API response to pick up done state changes - // (moving to/from the done bucket toggles the done status) + // Only pick up done state from the response since moving to/from the + // done bucket can toggle it. Spreading the full response task would + // overwrite fields like maxPermission that are not part of this endpoint. const updatedTask = { ...props.task, - ...updatedTaskBucket.task, + done: updatedTaskBucket.task?.done ?? props.task.done, + doneAt: updatedTaskBucket.task?.doneAt ?? props.task.doneAt, buckets: updatedBuckets, bucketId: bucket.id, }