Review from Part 3
- Can you refer to properties of a parent case from a child case?
- Can you update properties of a parent case from a child case?
- Can you update/modify properties of a child case from a parent case?
- What are some different use cases for opening a child case?
- Can you open a child case from a child case?
Questions from Part 3
Q: How do you open a subcase so that you see a new case list for the "child" case module?
A: Make sure that you are using the "open a subcase" function of the parent form (i.e. birth outcome) instead of just opening a case directly in the new module. You will also need to set up the case list for the new module.
Q: What does this mean: Validation Error: Dependency cycles amongst the xpath expressions in relevant/calculate
A: There should be some more detail in the latter part of the message to help you figure out where the error occured. But generally this means that a calculate condition for a hidden value is referring to itself. This would cause a confusing loop so the error message advises you to fix it.
Part 4 Topics
Topic 1: Application Design
- Best practices for application design and construction
- Use of the Application Design Worksheet
Exercise 1: Visit the application design page and download the Application Worksheet. Walk through it and consider the steps for developing a possible CommCare project. Things to consider:
- How to balance data needs with usability
- Is multimedia sometimes useful?
- How should you consider data?
- Export Form Contents - this is a useful way to view your form contents and link label text with Question IDs
Exercise 2: Follow the instructions above to export the form contents of the Registration Form.
Topic 2: Structuring Your Project
There are a lot of creative tricks you can use to add "smart structure" to your application. here are some new ones. See links where relevant.
- Form Filtering- just like you put display conditions on questions, you can put a display condition on an individual form. For example, you could have a form that is only for children older than 2 years of age. You can put a filter on that form so that it only shows up in the form list if you have choosen a case that is a child older than 2 years of age (as defined by a case property like "age").
- Module-level filtering of cases- you can use a tool in the Case List Configuration called the XPath filter. This is a powerful tool to reduce a case list to only a subset of cases. For example, you might be following 100 children in a community, but there is a separate modules for treatment of malnourished children. You can put a filter on the Case List so that you can only see cases of malnourished children. Another good use case is if you have multiple applications sharing the same case list and only want the case list to show up on one application at a tie.
- Parent/Child Case Selection- if you have child cases you may want to have a tiered form of selection. For example, in a household use case, you may want to be able to first choose a house from a list, and then choose from the relevant set of child cases.
- General Workflow Suggestions- there are some key workflow issues to consider when building your application- like how to edit case data, close cases, and organize groups of forms
- Referral Tracking in CommCare- "Referrals" as a separate function are no longer supported in CommCare; however, there are several ways to use the above techniques to support referral tracking.
- Case Sharing (see below)
Topic 3: Case Sharing
Resource 1: Review the Help Site page on Case Sharing and consider the following:
- Different possible configurations for case sharing
- How to set up an application and user groups for case sharing
- Implications of case sharing for worker activity reports
- Possible use cases for multiple applications sharing the same case type
- How to share cases among applications
Note: A very useful technique is to have multiple applications share the same cases. For example, you might have application meant for CHWs to use on the phone, and another application for clinical reporting used on tablets in a clinic. If these applications are both in the same project space and have the same case type, you can use the case sharing settings above to allow either the CHW or clinical staff to see and modify the same case list.
Tomorrow, Friday, will be focused on fixtures. What else do you want to cover?