opensrp / opensrp-client-anc

Other
5 stars 24 forks source link

How to create users on the OpenSRP Web #960

Open Naima-Bashir opened 1 year ago

Naima-Bashir commented 1 year ago

Affected App or Server Version

Latest apk

What kind of support do you need?

  1. Create a user
  2. Ensure the user has a Keycloak Group assigned to them. This means that the user can either be a provider or a superuser.
  3. Create a team
  4. Assign that user to the team
  5. Go to location units
  6. Add a service point
  7. Ensure the newly created service point has a hierarchy and a parent drop down e.g for villagea user ; this is how it looks: Indonesia- NTB-Lombok Barat- Puskesmas A- Village A
  8. The newly created service point can be Indonesia- NTB- Lombok Barat-Pusmeskas C
  9. Ensure the unit group says health facility
  10. Click save on the service point
  11. Click on team assignment next
  12. Locate your newly created service point e.g under NTB-Lombok Barat
  13. Add your team to your newly created location

What is the acceptance criteria for your support request?

Create new users Clear cache and data on the app on your phone login to the app

Relevant Information

No response

mergygayatri commented 1 year ago

Hi @Naima-Bashir. I and my research assistant have checked the assignments on the development OpenSRP Web. We created new usernames: 1 Puskesmas (puskesmas buah) and 2 villages (village mangga & village sirsak).

  1. We experienced sync failure only in Puskesmas.
  2. desa can see patients in another desa; Desa mangga can see desa sirsak. This is not as expected. Each desa should not be able to see patients in another desa, e.g. Desa magga can only see patients in desa mangga.

We experienced the same issues during your leave. Could you please also confirm with @AngelaKabari? We cannot continue to check the production OpenSRP Web because we need to solve this hierarchy issue in advance.

Naima-Bashir commented 1 year ago

Hi @mergygayatri If you look at the screenshot below, you will notice Desa Sirsak is assigned to 2 locations:

  1. Puskesmas Buah
  2. Desa Sirsak

This means that Desa Sirsak has a higher hierarchy and can therefore see details for Desa Mangga (It's assigned to a health facility which a higher location.) Please ensure that the village locations are only assigned to their level so that they can only see their village and not other villages.

image

mergygayatri commented 1 year ago

Hi @Naima-Bashir. Thank you for checking. We checked it again and created new credentials.

  1. Puskesmas vehicle
  2. Village plane
  3. Village bike

Yes, village plane only can see patients in village plane. So does the village bike. However, we cannot check the Puskesmas vehicle because the sync keeps failing. I created a patient in Puskesmas vehicle but it was lost because of sync failure. I would like to make sure that Puskesmas see all the patients (patients in Puskesmas + all patients in the catchment villages). You can see the video all of the steps I did here.

Naima-Bashir commented 1 year ago

Hi @mergygayatri

The sync is failing because server is throwing following error while syncing with Puskesmas Vehicle {"message":"FORBIDDEN","status":"403 FORBIDDEN","data":null,"success":false} We need to confirm when does this error occur. Maybe the user might might not have been granted the correct privileges.Did the user Puskesmas Vehicle have super user access or?

mergygayatri commented 1 year ago

Hi @Naima-Bashir, thank you. Just to make sure, how to check the user Puskesmas vehicle has super user access?

Naima-Bashir commented 1 year ago

Hi @mergygayatri here is a screenshot showing the Keycloak users groups. The user Puskesmas should have a Provider role in order to ensure the sync works as expected. Screenshot from 2023-08-11 12-03-18