Case Sharing using Organizations

The Organization Structure lets you easily configure parent locations to view their child location's data (ex. A supervisor viewing their supervisee's data).   In the example diagram below, users assigned to Fermathe Hospital can view the data for their health workers, and users assigned Grace Children's Hospital can view their health worker's data, but Fermathe Hospital can't view Grace Children's data, and each health worker cannot view each other's data.

This works by assigning cases to the child locations (ex. Andrea Fletcher).  Users assigned to parent locations (that have View Child Data turned on) are then allowed to view data for any locations below them.  A case sharing group is automatically created representing each location that can own cases - CommCare will then automatically assign mobile workers to the case sharing groups based on the organization hierarchy and data sharing settings.  

Configuring Case Sharing for an Application

For mobile workers assigned to locations at an organization level that can only "Own Cases", but not "View Child Data", its relatively simple to configure the application.  Turn on the Case Sharing option on the application settings page and newly created cases will automatically be assigned to the location.  

For mobile workers assigned to locations at an organization level that can "View Child Data", they can sometimes be in more than one case sharing group.  You'll be required to choose which location the case gets assigned to.  To configure this, follow the instructions on the https://dimagi.atlassian.net/wiki/x/2CTKfw

This works by assigning cases to the child locations (ex. Andrea Fletcher).  Users assigned to parent locations (that have View Child Data turned on) are then allowed to view data for any locations below them.  A case sharing group is automatically created representing each location that can own cases - mobile workers at that location and any parent locations that can view child location data are added to that case sharing group.