diff options
| author | Peter Stone <thepeterstone@gmail.com> | 2026-07-14 20:11:31 +0000 |
|---|---|---|
| committer | Peter Stone <thepeterstone@gmail.com> | 2026-07-16 02:44:02 +0000 |
| commit | 0baf1134ea2d415aa55079ff98476afd0acf5811 (patch) | |
| tree | 715f830a792d63af1a83998a166638cdb1bc696a /migrations | |
| parent | 7605e59f6d4524f4a0bf5d573916c8728ad0bfdb (diff) | |
feat(tasks): add recurrence columns and model fields for native tasks
recurrence_series_id != "" is the real recurring indicator (IsRecurring
predates this feature and is never set). Adds parseWeekdays/formatWeekdays
for the comma-separated weekday-list column, and threads the five new
columns through scanNativeTasks and all four existing SELECT queries.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VTUSAEKfsPc6WGDq45yPHD
Diffstat (limited to 'migrations')
| -rw-r--r-- | migrations/023_native_task_recurrence.sql | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/migrations/023_native_task_recurrence.sql b/migrations/023_native_task_recurrence.sql new file mode 100644 index 0000000..cc11324 --- /dev/null +++ b/migrations/023_native_task_recurrence.sql @@ -0,0 +1,10 @@ +-- Recurrence support for doot-native tasks: a recurring task generates a +-- brand-new row per iteration (see Store.CreateNextIteration), linked by +-- recurrence_series_id. recurrence_freq empty means "not recurring." +ALTER TABLE native_tasks ADD COLUMN recurrence_freq TEXT DEFAULT ''; +ALTER TABLE native_tasks ADD COLUMN recurrence_interval INTEGER DEFAULT 1; +ALTER TABLE native_tasks ADD COLUMN recurrence_weekdays TEXT DEFAULT ''; +ALTER TABLE native_tasks ADD COLUMN recurrence_series_id TEXT DEFAULT ''; +ALTER TABLE native_tasks ADD COLUMN next_occurrence_override TEXT DEFAULT ''; + +CREATE INDEX IF NOT EXISTS idx_native_tasks_recurrence_series ON native_tasks(recurrence_series_id); |
