feat: backdated reported date for old active tickets #7

Merged
abiba-bot merged 2 commits from fm/denya-backdate-report-date into main 2026-08-03 09:59:07 +00:00
Owner

Allows Wahab (and other roles) to enter tickets with their original reported date when creating them, so historical/backfilled tickets keep their true date while remaining active.

  • New nullable tickets.reported_at column (alembic migration d5e0f2a1c3b4), backfilled from created_at; legacy create_all schema guard extended too
  • TicketCreate.reported_at optional; defaults to now (unchanged behavior when omitted)
  • Create form: optional "Reported date" picker (defaults today, past allowed)
  • List + detail show Reported vs Created dates
  • 36/36 tests green, ruff clean, docs synced (no-mistakes pipeline passed)

Validated by the no-mistakes pipeline (outcome: passed). Denya OneCare — captain request 2026-08-03.

Allows Wahab (and other roles) to enter tickets with their original reported date when creating them, so historical/backfilled tickets keep their true date while remaining active. - New nullable `tickets.reported_at` column (alembic migration d5e0f2a1c3b4), backfilled from `created_at`; legacy create_all schema guard extended too - `TicketCreate.reported_at` optional; defaults to now (unchanged behavior when omitted) - Create form: optional "Reported date" picker (defaults today, past allowed) - List + detail show Reported vs Created dates - 36/36 tests green, ruff clean, docs synced (no-mistakes pipeline passed) Validated by the no-mistakes pipeline (outcome: passed). Denya OneCare — captain request 2026-08-03.
abiba-bot added 2 commits 2026-08-03 09:55:52 +00:00
Wahab can now enter historical tickets that keep their true reported date:

- Add nullable tickets.reported_at (DateTime) via alembic d5e0f2a1c3b4;
  backfill existing rows from created_at so nothing shows empty.
- TicketCreate.reported_at (optional) is persisted by create_ticket and
  defaults to now when omitted, so existing create behavior is unchanged.
- New-issue form gains a 'Reported Date' date picker (defaults to today,
  past dates allowed, future blocked) and sends reported_at in the payload.
- List and detail pages show 'Reported' next to 'Created' (date-only,
  labeled) so backdated tickets are obvious; SLA deadline is unchanged and
  still runs from creation time so backfilling never instantly breaches.
- Tests: backdated create persists + is exposed on list/detail; omitted
  reported_at defaults to now; SLA window unchanged; full datetime round trip.
abiba-bot merged commit 51e00a40cd into main 2026-08-03 09:59:07 +00:00
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: SyslogSolution/denya-onecare#7