diff --git a/cypress/e2e/task/task.spec.ts b/cypress/e2e/task/task.spec.ts
index af95b56c..0c2794ab 100644
--- a/cypress/e2e/task/task.spec.ts
+++ b/cypress/e2e/task/task.spec.ts
@@ -440,5 +440,30 @@ describe('Task', () => {
.get('.select select')
.should('have.value', '4')
})
+
+ it.only('Can set the progress for a task', () => {
+ const tasks = TaskFactory.create(1, {
+ id: 1,
+ })
+ cy.visit(`/tasks/${tasks[0].id}`)
+
+ cy.get('.task-view .action-buttons .button')
+ .contains('Set Progress')
+ .click()
+ cy.get('.task-view .columns.details .column')
+ .contains('Progress')
+ .get('.select select')
+ .select('50%')
+ cy.get('.global-notification')
+ .should('contain', 'Success')
+
+ cy.wait(200)
+
+ cy.get('.task-view .columns.details .column')
+ .contains('Progress')
+ .get('.select select')
+ .should('be.visible')
+ .should('have.value', '0.5')
+ })
})
})
diff --git a/src/views/tasks/TaskDetailView.vue b/src/views/tasks/TaskDetailView.vue
index 8c7606c9..f994696f 100644
--- a/src/views/tasks/TaskDetailView.vue
+++ b/src/views/tasks/TaskDetailView.vue
@@ -79,7 +79,7 @@
@@ -765,6 +765,17 @@ async function setPriority(priority: Priority) {
task: newTask,
})
}
+
+async function setPercentDone(percentDone: number) {
+ const newTask: ITask = {
+ ...task,
+ percentDone,
+ }
+
+ return saveTask({
+ task: newTask,
+ })
+}