mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-08 20:42:43 +00:00
Server-side prep for the next iOS TestFlight build. Five surfaces land together so the iOS engineer can pick them up in one cut-over: a locked externalId shape for daily-aggregated cumulative HealthKit rows, the SyncMode foundation columns + handshake + bulk-backfill endpoints, a first-class MoodEntry.note column that replaces the legacy tag-based workaround, a cross-source workout dedup helper, and two new MeasurementType enums plus the shared category overlay that drives the iOS permission picker and the future Insights nav.
17 lines
759 B
SQL
17 lines
759 B
SQL
-- v1.4.30 — MoodEntry.note column (R-E H-5)
|
|
--
|
|
-- Replaces the `tags: ["note:<text>"]` workaround the iOS app
|
|
-- shipped through v0.4.1.1. The prior shape contaminated the tags
|
|
-- axis with prose that the Coach evidence shelf misread as
|
|
-- taxonomic labels. The new column is a first-class free-text
|
|
-- field; the bulk-backfill migration script (run separately by the
|
|
-- operator) pulls existing `note:...` tag entries into this column.
|
|
--
|
|
-- Additive-only — the column is nullable, no existing row needs
|
|
-- updating for the schema migration itself to apply cleanly. The
|
|
-- `IF NOT EXISTS` guard keeps this idempotent against partial
|
|
-- historical runs (same posture as 0058 and 0061).
|
|
|
|
ALTER TABLE "mood_entries"
|
|
ADD COLUMN IF NOT EXISTS "note" TEXT;
|