diff --git a/frontend/src/components/tasks/partials/SingleTaskInProject.vue b/frontend/src/components/tasks/partials/SingleTaskInProject.vue index 5644fb23e..48eb3d7a8 100644 --- a/frontend/src/components/tasks/partials/SingleTaskInProject.vue +++ b/frontend/src/components/tasks/partials/SingleTaskInProject.vue @@ -111,7 +111,7 @@ @@ -132,7 +132,7 @@ :color="projectColor" class="mr-1" /> - + (new TaskModel()) const showDefer = ref(false) +const isRepeating = computed(() => task.value.repeatAfter.amount > 0 || (task.value.repeatAfter.amount === 0 && task.value.repeatMode === TASK_REPEAT_MODES.REPEAT_MODE_MONTH)) + watch( () => theTask, newVal => { @@ -303,11 +305,13 @@ async function markAsDone(checked: boolean) { playPopSound() } emit('taskUpdated', newTask) - success({ - message: task.value.done ? - t('task.doneSuccess') : - t('task.undoneSuccess'), - }, [{ + + let message = t('task.doneSuccess') + if (!task.value.done && !isRepeating.value) { + message = t('task.undoneSuccess') + } + + success({message}, [{ title: t('task.undo'), callback: () => undoDone(checked), }])