Case files / PAN-126

PAN-126Live

PMB case desk

A CRM for a healthcare advocacy practice that takes on medical schemes over prescribed minimum benefits: patients, referring practices, cases, motivation letters, invoices and a ledger. Nothing a practice sends becomes a record until a person files it.

Control flow

  1. Referral: a practice refers a case
  2. Triage: a person files it or declines it
  3. Coding: diagnosis and tariff lines
  4. Letter: motivation written, saved as PDF
  5. Notify: only who a person ticks
  6. Billing: invoice, ledger, statement

Industry: Medical · Stack: Next.js 16 · TypeScript · PostgreSQL · Prisma · AWS · Seed species: Lantern

Problem

When a medical scheme declines treatment that should be covered as a prescribed minimum benefit, the member is usually ill, and the dispute is a matter of paperwork and deadlines. An advocacy practice fights these cases one at a time. It needs one place for the patient, the referring practice, the case, the letters and the money.

How it works

A CRM holds patients, referring practices, cases, motivation letters, invoices and a full ledger. Practices refer cases through a portal, and nothing they send becomes a record until a person files it. Accepting a referral re-runs the duplicate-patient check. Declined files are deleted after 30 days.

Who hears about a case update is a person’s decision. The notify switch defaults to no, only the stakeholders a person ticks are emailed, and each update leaves a note on the case either way. Bank matching suggests and never commits. The claims audit is arithmetic: month-on-month drops in a practice’s outstanding balances become recovery fees.

Letters are written by a person in an editor and saved as PDFs.

Results

  • In daily use on real cases, with a snapshot and checks on every release.
  • The application, its database and its documents run on encrypted storage.

What broke

A security review found a sign-in step that could be skipped. It was closed, and every session token now carries a purpose, checked in one place.

A phone’s camera killed the browser mid-upload and practices lost their files. Each file now uploads as it is added and the draft resumes. The build once ran out of memory on the small server.

Limitations

One message skips review: raising a case’s fee tier emails the payer at once. There is no automated test suite; verification is by driving the app. The practice portal has no practice on it yet.

Next

Pilot the practice portal with its first practice.

Open the living case file