Multiple Doctors Displayed in Prescription After Reassigning Doctor
What does this MR do and why?
This MR introduces a Change Consultation feature and improves the prescription workflow and navigation system for better patient management in the medical camp application.
Why this change?
Allows reassignment of patients between doctors when consultation needs to be changed
Improves prescription workflow efficiency
Enhances medicine input handling based on medicine type
Removes duplicate search logic by using a shared utility function
Improves queue workflow management using API integration
Enhances navigation support for doctor roles and queue views
References
Related feature: Change Consultation for Doctor Reassignment
Prescription workflow improvements
Navigation updates for queue management
Branch: feature/change-consultation
| Before | After |
|---|---|
| Patients could not be reassigned once assigned to a doctor | Added Change Consultation option to reassign patients |
| Same input used for all medicine types | Tablet/Tab → dosage selection, other types → quantity input |
| Duplicate medicine search logic in component | Refactored to shared getSearchScore utility |
| Queue workflow not updated automatically | Integrated updateQueueStatus API for state management |
How to set up and validate locally
Clone the repository:
git clone <repo_url> cd ehrs-frontend-vite
Install dependencies:
npm install
Run the development server:
npm run dev
Open browser:
Verify:
Assign a patient to a doctor and enable Change Consultation
Reassign the patient to another doctor successfully
Open Update Prescription and verify medicine input behavior
Tablet/Tab medicines show dosage selection
Other medicine types allow quantity input only
Navigation shows queue tabs for doctor and volunteer roles
MR acceptance checklist
-
Added Change Consultation support in doctor assignment -
Updated AssignDoctorPage with Change Consultation option -
Improved UpdatePrescriptionPage with URL-based patient lookup -
Refactored medicine search using shared getSearchScore utility -
Integrated updateQueueStatus API for workflow updates -
Improved medicine input handling based on medicine type -
Added navigation support for doctor role and queue tabs -
Application builds and runs successfully
Summary
Introduced Change Consultation support for doctor reassignment and improved the prescription workflow, medicine handling, and queue navigation to enhance patient management in the medical camp system.

