-
Notifications
You must be signed in to change notification settings - Fork 23
Conversation
What happens to Patients that are not assigned to a Client after the upgrade? Should they be moved inside a fake Client named as "our-lab"? |
External Client Contacts seems to not be able to select a Primary Sample during the Sample creation. Is this done on purpose? |
With the previous upgrade step 1.2.3, all Patients were moved to their corresponding Clients. Only those patients assigned to different clients (directly or indirectly via sample or case), weren't moved. These are the Patients that were left in /patients root folder, so neither clients nor internal clients will be able to use them anymore in new Samples. Nevertheless, the record and permissions are kept, so users will be able to see them from either samples or batches those patients are assigned to. Not sure what to do with them (since they are directly or indirectly assigned to different clients already and we assume that clients created until date were of type "external"). I think we cannot resolve the issue automatically, but I think that at least, we should display an alert icon in patients listing (visible to labman + labclerk only) so lab personnel become aware of those "orphan" patients. Same same for clinical cases and doctors. At this point, an option would be to allow them to "manually" assign the Client, even if the Patient has samples that belong to another.... not sure |
Ummm, not done on purpose afak. Maybe is an issue in core? Will check |
Description of the issue/feature this PR addresses
This Pull Request adds Internal Clients functionality. Internal Clients differ from "standard" (or external) clients so, the formers share Patients, Batches (Cases) and Doctors. Therefore, senaite.health becomes suitable to fit with the needs of both private clinics and public reference laboratories:
The schema above applies for Batches and Doctors as well. A new item "Internal Clients" has been added in the left-hand navigation bar. So any client created inside this folder will be considered as Internal and therefore, all its Patients, Doctors and Cases will be visible (and shareable, e.g. on Sample creation) by other Internal Clients.
Information from Clients created inside "Clients" folder, won't be shared and will remain private, so their Patients, Cases and Doctors will become private.
For clearliness, some icons have been added in listings, as well as viewlets to notify the user about the sharing policy. These icons and viewlets are not displayed to client contacts from external clients to prevent them to be confused (at the end, their data will only be private and there is no chance to make it shareable).
Additional notes
Tips for functional testing
/patients
,/doctors
,/batches
). If so, the object is moved inside the proper client on creation.Current behavior before PR
The only way to share Patients, Doctors and Batches was to create them without a Client assigned. In such case, all Clients were able to see and use them, regardless of their "type".
Desired behavior after PR is merged
Two types of clients: "External Client" and "Internal Client". Patients, Cases and Doctors from internal clients are shared among them, while keeping their Ownership (Referrer). Patient, Cases and Doctors from External Clients cannot be shared at all and remain private.
--
I confirm I have tested this PR thoroughly and coded it according to PEP8
and Plone's Python styleguide standards.