Skip to content

Clinic queue#149

Merged
inteee merged 5 commits intoCIVRA-INC:mainfrom
S-Mubarak:clinic_queue
Mar 8, 2026
Merged

Clinic queue#149
inteee merged 5 commits intoCIVRA-INC:mainfrom
S-Mubarak:clinic_queue

Conversation

@S-Mubarak
Copy link
Contributor

I added a real-time clinic queue board for LumenHealth EHR so staff can easily see which patients are waiting in the lobby, with the nurse, or with the doctor. To unblock frontend development, I created a mock JSON array with five encounters in different states (WAITING, TRIAGE, and CONSULTATION) so the UI could be built and tested independently before the backend integration was completed.

On the backend, I implemented GET /api/v1/queue/today, which aggregates encounters created today that are in OPEN or IN_PROGRESS states, and added Server-Sent Events (SSE) so the frontend automatically receives updates whenever an encounter state changes. On the frontend, I built a Kanban-style board with columns for Waiting Room, Triage, and Consultation that displays patient cards with their name, system ID, and wait time, and allows staff to move patients between stages via drag-and-drop or a dropdown. The UI updates within five seconds of backend state changes without requiring a hard refresh and preserves scroll position without flickering when new data arrives.

closes #116

Copy link
Contributor

@inteee inteee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please scope SSE fan-out by clinic. Right now queue update events are broadcast to every connected stream subscriber, which can leak one clinic’s queue movements to another clinic’s clients.

Copy link
Contributor

@inteee inteee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good job. Approving

@inteee inteee merged commit 7837373 into CIVRA-INC:main Mar 8, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Real-Time Clinic Queue & Routing Dashboard

2 participants