feat: add cancelled status for archiving discarded entries

Entries in On Docket or In Progress can be moved to Cancelled via the
right-click context menu. Cancelled entries are preserved on disk but
hidden from the board.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Cal Corum 2026-02-11 14:50:14 -06:00
parent 0900329020
commit d388002fec
2 changed files with 7 additions and 0 deletions

View File

@ -146,6 +146,11 @@ class EntryCard(QFrame):
for status in EntryStatus:
if status == self._entry.status:
continue
# Only Docket and In Progress cards can be cancelled
if status == EntryStatus.CANCELLED and self._entry.status not in (
EntryStatus.DOCKET, EntryStatus.IN_PROGRESS,
):
continue
action = menu.addAction(f"Move to {_label_for(status)}")
action.triggered.connect(lambda _checked, s=status: self._move_to(s))
menu.exec(self.mapToGlobal(pos))
@ -157,6 +162,7 @@ def _label_for(status: EntryStatus) -> str:
EntryStatus.DOCKET: "On Docket",
EntryStatus.IN_PROGRESS: "In Progress",
EntryStatus.COMPLETE: "Complete",
EntryStatus.CANCELLED: "Cancelled",
}[status]

View File

@ -18,6 +18,7 @@ class EntryStatus(str, Enum):
DOCKET = "docket"
IN_PROGRESS = "in_progress"
COMPLETE = "complete"
CANCELLED = "cancelled"
class Entry(BaseModel):