ohcnetwork / care_fe

Care is a Digital Public Good enabling TeleICU & Decentralised Administration of Healthcare Capacity across States.
https://care.ohc.network
MIT License
249 stars 431 forks source link

Handle Users skill fetching in patient consultation page #8027

Closed nihal467 closed 2 days ago

nihal467 commented 4 months ago

Describe the bug

When a doctor is not linked to a facility anymore, and we try to open any old consultation treated by the doctor, the patient consultation page will throw no user matches the given query error message in the frontend since the page try to fetch the doctors skill details.

To Reproduce Steps to reproduce the behavior:

  1. Go to patient consultation page of a discharged patient
  2. unlink the related doctor from the facility
  3. refresh the page
  4. See error

Note: The doctor id should have some skills linked to the user

Expected behavior

Screenshots

image

Solution: Instead of making an api call to get user details, serilaize the user skill details on the consultation__treating_physician object

github-actions[bot] commented 4 months ago

Hi, @coronasafe/care-frontend-maintainers, This issue has been automatically marked as stale because it has not had any recent activity.

gigincg commented 2 months ago

@sainak This seems like a good first issue, can you add a few lines for implementation detail, and mark as good first issue

Indrajeety993648 commented 1 month ago

@rithviknishad , I would like to work on this issue if no one working on it , Please assign it to me

Sulochan-khadka commented 1 month ago

I am unable to reproduce the error. Am i doing something wrong? @rithviknishad @nihal467 https://github.com/user-attachments/assets/9bee7eba-269b-4a7e-b2b7-c399beb9a5a2

nihal467 commented 1 month ago

@Sulochan-khadka i have modified the issue, you need to make sure that, the doctor id you are using have some skills linked to the users

steps to add skills to the user:

  1. go to the user tab
  2. search for the user id
  3. click on linked skills buttons
  4. add any random skills

post that try the steps you done , you should be able to replicate the bug

JavidSumra commented 3 weeks ago

Is there any one working on this issue?

SwanandBhuskute commented 3 days ago

Is this issue still valid? if yes, would like to solve it @nihal467

SwanandBhuskute commented 3 days ago

@nihal467 I am unable to see the error

I went to DIscharged , then , Gayan's Hospital, then Gururaj, then his consultations, then I see doctor Sriharsh Gampa then in user management, I added few skills to him and unlink Gampa from gayan hospital, come back to consultaion page , but still the Sriharsh Gampa doctor is visible along with his skills Image Image Image

same for 1 2 more discharged patients (discharged - gayan - ramesh - devdeep doctor)

can you give more clarity?

nihal467 commented 2 days ago

@SwanandBhuskute the issue seem to be resolved, feel free to assign new open issues