diff --git a/docs/PRODUCT.md b/docs/PRODUCT.md index 766ef69..cb93375 100755 --- a/docs/PRODUCT.md +++ b/docs/PRODUCT.md @@ -67,8 +67,8 @@ Confirmed and in place: browser. - Offline-capable installable PWA. Currently deploys as one static artifact to both GitHub Pages (under a subpath) and a self-hosted Docker image. -- Recurring costs — a bill that repeats monthly, every N days, or every N - weeks on a weekday, split across posts like any purchase. Each due date is a +- Recurring costs — a bill that repeats every N months, every N days, or + every N weeks on a weekday, split across posts like any purchase. Each due date is a projected occurrence the owner confirms into a real purchase; the month view shows what is still expected alongside a second, projected balance per post, so a known bill is visible before it is paid without touching the reconciled diff --git a/scripts/demo-data.ts b/scripts/demo-data.ts index 46bc1bb..1792d4d 100755 --- a/scripts/demo-data.ts +++ b/scripts/demo-data.ts @@ -104,7 +104,12 @@ const buy = (date: string, description: string, amount: number, currency: "DKK" for (let m = 1; m <= 9; m++) { const mm = String(m).padStart(2, "0"); - buy(`2026-${mm}-01`, "Rent", 8200, "DKK", rent.id); + // The "Rent" recurring cost above starts 2026-06 and is left unconfirmed, + // so it already projects an expected charge for June onward. An ordinary + // Rent purchase in those same months would double-charge the post in the + // screenshots — one from `charges`, one from `expected` — so this ordinary + // purchase only covers the months before the recurring cost exists. + if (m < 6) buy(`2026-${mm}-01`, "Rent", 8200, "DKK", rent.id); buy(`2026-${mm}-04`, "Groceries", 1180 + m * 37, "DKK", food.id); buy(`2026-${mm}-18`, "Groceries", 1420 - m * 12, "DKK", food.id); buy(`2026-${mm}-06`, "Commuter pass", 1100, "DKK", transport.id);