Case study · Elsinore Valley MWD
Regulus
Compliance reporting platform
A full-stack app that reads water-quality compliance data straight from the database, shows it on one dashboard, and generates the recurring state reports from the same numbers — replacing manual data entry.
- Where
- Elsinore Valley MWD
- Role
- Full-stack developer — design, build, test
- When
- 2026
- Users
- Compliance analysts
regulus · compliance dashboard
Mock · synthetic dataThe problem
Water utilities file recurring regulatory reports with the state. Analysts were hand-copying numbers out of a SQL database into state forms every quarter, and reading monthly results out of lab PDF reports by hand.
It was slow, repetitive work, and a compliance filing is the worst place for a transcription slip.
What I built
One dashboard for the whole record
Every sampling location charted over time against the regulatory limit, plus a location × quarter matrix shaded by value, with filters for year, quarter, date range and location.
State reports from the same numbers
A print-exact preview of the state form, then Excel and PDF exports that write exactly what the preview shows. Every generated file is logged with the period it covers.
Lab PDFs read automatically
A Python + PyMuPDF pipeline extracts results from the monthly lab report and fills the state form, which is drawn in the browser to match the state’s Excel template and can be reviewed and edited before filing.
Sampling schedule and limits
An editable sampling-frequency matrix that turns each required sample into a task on a calendar and board, checks results against limits, and records every change in an audit trail.
Decisions that mattered
When the output is a compliance filing, correctness rules are product features.
The preview is the file
One report object feeds the on-screen preview, the Excel writer and the PDF writer, so an export can never disagree with what the analyst reviewed.
Filters narrow what prints, never what’s computed
Rolling averages are calculated over the full record before any filter runs, so hiding a column can’t silently shorten an average. The rule is pinned by a test.
Gaps don’t bridge
Where the record skips a quarter, the running average stays blank instead of reaching back past the gap.
Software suggests, people sign
Determinations an analyst signs for are computed and highlighted on the form, never ticked automatically, with the working written beside them.
Read-only, least privilege
The app only ever reads the source database, as the signed-in Windows user, so no database credentials are stored anywhere.
Stack
- Frontend
- React 19TypeScriptViteTailwind CSSTanStack QueryRecharts
- Backend
- PythonFastAPISQLAlchemy 2openpyxlReportLabPyMuPDF
- Data
- SQL Server (read-only)SQLite
- Quality
- pytest — 200+ testsClaude Code (AI-assisted, test-verified)
Result
- Recurring state reports generated from live database records in Excel and PDF, replacing manual data entry.
- 200+ automated unit and API tests covering compliance calculations, form generation and authentication — so AI-assisted changes were verified before release.
- During a reporting data-source migration, reconciled two databases record by record: found 330 of 1,154 results missing from the older source and confirmed no current compliance averages changed.
- The browser-drawn state form was checked against Excel itself: all 1,527 cells land exactly where Excel puts them.