Dashboard
Route: /
File: memberportal/src/pages/DashboardPage.tsx
The Dashboard is the first page a patient sees after signing in. It shows a quick summary of their most important health data in one place.
What it shows​
The dashboard is divided into four summary cards:
| Card | FHIR Resource | What is shown |
|---|---|---|
| Recent Visits | Encounter | Up to 4 recent visits with date, reason, and EHR source |
| Medications | MedicationRequest | Up to 4 active medications with dosage and EHR source |
| Recent Labs | Observation | Up to 4 recent lab results with flagged/normal status |
| Active Conditions | Condition | Up to 4 active conditions with onset date |
Each card has a "See all" link that takes the patient to the full page for that section.
EHR sync status​
At the top of the dashboard, a subtitle line tells the patient:
- Which EHR providers they are connected to (e.g., Records from Epic & Healow)
- When data was last synced (e.g., last synced Apr 22, 2026)
- If no EHR is connected: "No EHR connected — go to Settings to connect your health records"
Refresh button​
The Refresh button triggers a manual sync of all connected EHR providers:
- Calls
POST /fhir/referesh/all-ehrswith the patient's access token. - Polls
GET /fhir/referesh/statusevery 3 seconds until sync is complete. - Shows a success, warning, or error notification depending on the result:
- Green — all providers synced successfully
- Orange — EHR session expired, patient needs to reconnect in Settings
- Yellow — partial sync (some synced, some expired)
- Red — sync request failed
Ask ChartChat button​
Opens the AI Chat Assistant page (/chat) directly.
EHR connection errors​
If the patient is redirected back from an EHR OAuth flow with an error (e.g., they denied access), the URL contains ?ehr_error=.... The dashboard detects this and shows a red notification with the error message, then cleans the URL.
FHIR resources used​
| Resource | Filter |
|---|---|
Observation | category=laboratory, sorted by newest, limit 10 |
MedicationRequest | sorted by newest, limit 10, filtered to status=active |
Condition | limit 10, filtered to clinicalStatus=active |
Encounter | sorted by newest, limit 10 |
PatientEHRConnection | status=active — used to get last sync date |