summaryrefslogtreecommitdiff
path: root/internal/task
diff options
context:
space:
mode:
Diffstat (limited to 'internal/task')
-rw-r--r--internal/task/task.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/internal/task/task.go b/internal/task/task.go
index 86c93f4..2c7f8e8 100644
--- a/internal/task/task.go
+++ b/internal/task/task.go
@@ -26,6 +26,7 @@ type Task struct {
ID int `json:"id"`
UUID string `json:"uuid"`
Description string `json:"description"`
+ Project string `json:"project"`
Tags []string `json:"tags"`
Status string `json:"status"`
Start string `json:"start"`
@@ -298,6 +299,11 @@ func SetDescription(id int, desc string) error {
return modifyTask(id, "description:"+desc)
}
+// SetProject changes the project of the task with the given id.
+func SetProject(id int, project string) error {
+ return modifyTask(id, "project:"+project)
+}
+
// Annotate adds an annotation to the task with the given id.
func Annotate(id int, text string) error {
if id <= 0 {