diff options
Diffstat (limited to 'makima/src/db/models.rs')
| -rw-r--r-- | makima/src/db/models.rs | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/makima/src/db/models.rs b/makima/src/db/models.rs index bf95a3a..6ede268 100644 --- a/makima/src/db/models.rs +++ b/makima/src/db/models.rs @@ -525,6 +525,12 @@ pub struct Task { /// Used to track the origin of "what if" explorations. #[serde(skip_serializing_if = "Option::is_none")] pub branched_from_task_id: Option<Uuid>, + + // UI visibility + /// Whether this task is hidden from the UI (user dismissed it). + /// Standalone completed tasks can be dismissed by the user. + #[serde(default)] + pub hidden: bool, } impl Task { @@ -564,6 +570,9 @@ pub struct TaskSummary { /// True for contract supervisor tasks #[serde(default)] pub is_supervisor: bool, + /// Whether this task is hidden from the UI (user dismissed it) + #[serde(default)] + pub hidden: bool, pub created_at: DateTime<Utc>, pub updated_at: DateTime<Utc>, } @@ -586,6 +595,7 @@ impl From<Task> for TaskSummary { subtask_count: 0, // Would need separate query version: task.version, is_supervisor: task.is_supervisor, + hidden: task.hidden, created_at: task.created_at, updated_at: task.updated_at, } @@ -670,6 +680,8 @@ pub struct UpdateTaskRequest { /// Explicitly clear daemon_id (set to NULL) #[serde(default)] pub clear_daemon_id: bool, + /// Whether this task is hidden from the UI (user dismissed it) + pub hidden: Option<bool>, /// Version for optimistic locking pub version: Option<i32>, } |
