Add a Recurring status to TaskChampion

This commit is contained in:
Dustin J. Mitchell 2022-12-15 02:52:35 +00:00 committed by Tomas Babej
parent 6e5d8b1dde
commit 9add31104b
5 changed files with 13 additions and 4 deletions

View file

@ -8,6 +8,7 @@ pub enum TCStatus {
Pending,
Completed,
Deleted,
Recurring,
/// Unknown signifies a status in the task DB that was not
/// recognized.
Unknown,
@ -19,6 +20,7 @@ impl From<TCStatus> for Status {
TCStatus::Pending => Status::Pending,
TCStatus::Completed => Status::Completed,
TCStatus::Deleted => Status::Deleted,
TCStatus::Recurring => Status::Recurring,
TCStatus::Unknown => Status::Unknown("unknown".to_string()),
}
}
@ -30,6 +32,7 @@ impl From<Status> for TCStatus {
Status::Pending => TCStatus::Pending,
Status::Completed => TCStatus::Completed,
Status::Deleted => TCStatus::Deleted,
Status::Recurring => TCStatus::Recurring,
Status::Unknown(_) => TCStatus::Unknown,
}
}

View file

@ -111,6 +111,7 @@ typedef enum TCStatus {
TC_STATUS_PENDING,
TC_STATUS_COMPLETED,
TC_STATUS_DELETED,
TC_STATUS_RECURRING,
/**
* Unknown signifies a status in the task DB that was not
* recognized.