Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/FerchoSG/healthcare-web/llms.txt

Use this file to discover all available pages before exploring further.

Doctors interact with CitaBox primarily through their personal schedule view. After login, they land on the schedule view and see only the appointments assigned to them for the current day. From there, they move patients through the consultation lifecycle — from waiting, through an active consultation with the EMR open, to completed — without needing to touch any other part of the application.

Schedule view

The schedule view (components/views/DoctorDashboard.tsx) loads today’s appointments from the API and filters them to the authenticated doctor’s doctor_id. This means a doctor will never see appointments belonging to other providers at the same clinic. At the top of the view, a greeting panel displays the doctor’s name, today’s date, and the total number of appointments scheduled. Below it, three summary cards show:
  • Today’s patients — total appointments for the day.
  • In progress — appointments currently in IN_CONSULTATION status.
  • Completed — appointments that have been marked COMPLETED.
Each appointment is displayed as a card in a two-column grid. The card shows the patient’s name and identification number, the appointment time, the reason or service name, and a status badge. Cards for the active consultation are highlighted with a ring border.

Starting and ending a consultation

Each appointment card has one primary action button. Its label and behavior change depending on the appointment’s current status:
  • When the appointment is not active, the button reads Start consultation. Clicking it calls updateAppointmentStatus with IN_CONSULTATION and highlights the card.
  • When the appointment is active, two buttons appear:
    • Open record — opens the patient’s EMR with consultationActive: true and the current appointmentId, enabling the doctor to document the visit.
    • End consultation — calls updateAppointmentStatus with COMPLETED and removes the active highlight.
Appointment cards for Completed or Cancelled appointments show a disabled start button so the doctor cannot accidentally reopen a closed session.

Electronic medical records (EMR)

Clicking Open record during an active consultation opens the EMRView modal. Because it is opened with consultationActive: true, the EMR starts in consultation mode, allowing the doctor to create or update the patient’s clinical notes, diagnoses, prescriptions, and other records for the current visit. The modal stays open until the doctor explicitly closes it; closing the modal does not end the consultation. After documenting, the doctor returns to the schedule view and clicks End consultation to mark the appointment as completed.

Time blocks

Doctors can create time blocks to mark periods when they are unavailable — for example, during a vacation, a break, or an administrative task. Time blocks appear in the shared calendar view and prevent the receptionist or booking portal from scheduling new appointments in those slots.
Time blocks are enforced at the booking level. A patient using the online booking portal cannot select a time that falls within a blocked period, and receptionists will see the slot as unavailable in the calendar before creating a new appointment manually.

Available views

Doctors have access to two sections via the sidebar:
  • Schedule — the personal daily agenda described above. This is the default view on login.
  • Patients — the full patient registry. Doctors can search for any patient and open their EMR directly from the list, independent of a scheduled appointment.
Doctors do not have access to the Calendar, Settings, or front-desk views.

Full consultation workflow

1

Review today's schedule

Log in to CitaBox and land on the schedule view. Check the total appointment count and the list of patient cards to plan the day.
2

Mark the first appointment in consultation

When a patient is called from the waiting room, find their card and click Start consultation. The card gains a ring highlight and the status updates to IN_CONSULTATION.
3

Open the EMR

Click Open record on the active card to open the patient’s electronic medical record in consultation mode. The modal opens with the current appointment linked so that any notes or actions recorded are tied to this visit.
4

Document the visit

Add clinical notes, diagnoses, prescriptions, or other records inside the EMR. All changes are saved within the modal.
5

Close the EMR and mark complete

Close the EMR modal when documentation is finished. Return to the schedule view and click End consultation on the appointment card. The status updates to COMPLETED and the card’s action button becomes disabled.

Build docs developers (and LLMs) love